Commit 53a37077 authored by Stephen Hemminger's avatar Stephen Hemminger Committed by David S. Miller

[PKT_SCHED]: Packet scheduler exports.

The packet scheduling code has some ugly define's which were to deal with
configuration possibilities and the old style module exports.  With the current
2.6 method, this is unnecessary.
Signed-off-by: default avatarStephen Hemminger <shemminger@osdl.org>
Signed-off-by: default avatarDavid S. Miller <davem@redhat.com>
parent 9e1b865c
...@@ -210,12 +210,8 @@ typedef long psched_tdiff_t; ...@@ -210,12 +210,8 @@ typedef long psched_tdiff_t;
#define PSCHED_US2JIFFIE(usecs) (((usecs)+(1000000/HZ-1))/(1000000/HZ)) #define PSCHED_US2JIFFIE(usecs) (((usecs)+(1000000/HZ-1))/(1000000/HZ))
#define PSCHED_JIFFIE2US(delay) ((delay)*(1000000/HZ)) #define PSCHED_JIFFIE2US(delay) ((delay)*(1000000/HZ))
#define PSCHED_EXPORTLIST EXPORT_SYMBOL(psched_tod_diff);
#else /* PSCHED_CLOCK_SOURCE != PSCHED_GETTIMEOFDAY */ #else /* PSCHED_CLOCK_SOURCE != PSCHED_GETTIMEOFDAY */
#define PSCHED_EXPORTLIST PSCHED_EXPORTLIST_1 PSCHED_EXPORTLIST_2
typedef u64 psched_time_t; typedef u64 psched_time_t;
typedef long psched_tdiff_t; typedef long psched_tdiff_t;
...@@ -235,8 +231,6 @@ extern psched_time_t psched_time_base; ...@@ -235,8 +231,6 @@ extern psched_time_t psched_time_base;
#define PSCHED_JSCALE 10 #define PSCHED_JSCALE 10
#endif #endif
#define PSCHED_EXPORTLIST_2
#if BITS_PER_LONG <= 32 #if BITS_PER_LONG <= 32
#define PSCHED_WATCHER unsigned long #define PSCHED_WATCHER unsigned long
...@@ -245,15 +239,10 @@ extern PSCHED_WATCHER psched_time_mark; ...@@ -245,15 +239,10 @@ extern PSCHED_WATCHER psched_time_mark;
#define PSCHED_GET_TIME(stamp) ((stamp) = psched_time_base + (((unsigned long)(jiffies-psched_time_mark))<<PSCHED_JSCALE)) #define PSCHED_GET_TIME(stamp) ((stamp) = psched_time_base + (((unsigned long)(jiffies-psched_time_mark))<<PSCHED_JSCALE))
#define PSCHED_EXPORTLIST_1 EXPORT_SYMBOL(psched_time_base); \
EXPORT_SYMBOL(psched_time_mark);
#else #else
#define PSCHED_GET_TIME(stamp) ((stamp) = (jiffies<<PSCHED_JSCALE)) #define PSCHED_GET_TIME(stamp) ((stamp) = (jiffies<<PSCHED_JSCALE))
#define PSCHED_EXPORTLIST_1
#endif #endif
#define PSCHED_US2JIFFIE(delay) (((delay)+(1<<PSCHED_JSCALE)-1)>>PSCHED_JSCALE) #define PSCHED_US2JIFFIE(delay) (((delay)+(1<<PSCHED_JSCALE)-1)>>PSCHED_JSCALE)
...@@ -264,9 +253,6 @@ extern PSCHED_WATCHER psched_time_mark; ...@@ -264,9 +253,6 @@ extern PSCHED_WATCHER psched_time_mark;
extern psched_tdiff_t psched_clock_per_hz; extern psched_tdiff_t psched_clock_per_hz;
extern int psched_clock_scale; extern int psched_clock_scale;
#define PSCHED_EXPORTLIST_2 EXPORT_SYMBOL(psched_clock_per_hz); \
EXPORT_SYMBOL(psched_clock_scale);
#define PSCHED_US2JIFFIE(delay) (((delay)+psched_clock_per_hz-1)/psched_clock_per_hz) #define PSCHED_US2JIFFIE(delay) (((delay)+psched_clock_per_hz-1)/psched_clock_per_hz)
#define PSCHED_JIFFIE2US(delay) ((delay)*psched_clock_per_hz) #define PSCHED_JIFFIE2US(delay) ((delay)*psched_clock_per_hz)
...@@ -278,8 +264,6 @@ extern int psched_clock_scale; ...@@ -278,8 +264,6 @@ extern int psched_clock_scale;
(stamp) = __cur>>psched_clock_scale; \ (stamp) = __cur>>psched_clock_scale; \
}) })
#define PSCHED_EXPORTLIST_1
#elif defined (__alpha__) #elif defined (__alpha__)
#define PSCHED_WATCHER u32 #define PSCHED_WATCHER u32
...@@ -294,9 +278,6 @@ extern PSCHED_WATCHER psched_time_mark; ...@@ -294,9 +278,6 @@ extern PSCHED_WATCHER psched_time_mark;
(stamp) = (psched_time_base + __res)>>psched_clock_scale; \ (stamp) = (psched_time_base + __res)>>psched_clock_scale; \
}) })
#define PSCHED_EXPORTLIST_1 EXPORT_SYMBOL(psched_time_base); \
EXPORT_SYMBOL(psched_time_mark);
#else #else
#error PSCHED_CLOCK_SOURCE=PSCHED_CPU is not supported on this arch. #error PSCHED_CLOCK_SOURCE=PSCHED_CPU is not supported on this arch.
......
...@@ -1098,6 +1098,7 @@ int psched_tod_diff(int delta_sec, int bound) ...@@ -1098,6 +1098,7 @@ int psched_tod_diff(int delta_sec, int bound)
delta = bound; delta = bound;
return delta; return delta;
} }
EXPORT_SYMBOL(psched_tod_diff);
#endif #endif
psched_time_t psched_time_base; psched_time_t psched_time_base;
...@@ -1105,10 +1106,14 @@ psched_time_t psched_time_base; ...@@ -1105,10 +1106,14 @@ psched_time_t psched_time_base;
#if PSCHED_CLOCK_SOURCE == PSCHED_CPU #if PSCHED_CLOCK_SOURCE == PSCHED_CPU
psched_tdiff_t psched_clock_per_hz; psched_tdiff_t psched_clock_per_hz;
int psched_clock_scale; int psched_clock_scale;
EXPORT_SYMBOL(psched_clock_per_hz);
EXPORT_SYMBOL(psched_clock_scale);
#endif #endif
#ifdef PSCHED_WATCHER #ifdef PSCHED_WATCHER
PSCHED_WATCHER psched_time_mark; PSCHED_WATCHER psched_time_mark;
EXPORT_SYMBOL(psched_time_mark);
EXPORT_SYMBOL(psched_time_base);
static void psched_tick(unsigned long); static void psched_tick(unsigned long);
...@@ -1214,4 +1219,3 @@ EXPORT_SYMBOL(qdisc_get_rtab); ...@@ -1214,4 +1219,3 @@ EXPORT_SYMBOL(qdisc_get_rtab);
EXPORT_SYMBOL(qdisc_put_rtab); EXPORT_SYMBOL(qdisc_put_rtab);
EXPORT_SYMBOL(register_qdisc); EXPORT_SYMBOL(register_qdisc);
EXPORT_SYMBOL(unregister_qdisc); EXPORT_SYMBOL(unregister_qdisc);
PSCHED_EXPORTLIST;
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment