2
0
mirror of https://github.com/edk2-porting/linux-next.git synced 2025-01-18 18:43:59 +08:00

[PATCH] ntp: cleanup defines and comments

Remove a few unused defines and remove obsolete information from comments.

Signed-off-by: Roman Zippel <zippel@linux-m68k.org>
Cc: john stultz <johnstul@us.ibm.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
This commit is contained in:
Roman Zippel 2006-09-30 23:28:29 -07:00 committed by Linus Torvalds
parent f199239373
commit 0883d899ef
5 changed files with 3 additions and 24 deletions

View File

@ -6,11 +6,6 @@
#define CLOCK_TICK_RATE 1193180 /* Underlying HZ */ #define CLOCK_TICK_RATE 1193180 /* Underlying HZ */
#define CLOCK_TICK_FACTOR 20 /* Factor of both 1000000 and CLOCK_TICK_RATE */ #define CLOCK_TICK_FACTOR 20 /* Factor of both 1000000 and CLOCK_TICK_RATE */
#define FINETUNE \
((((((long)LATCH * HZ - CLOCK_TICK_RATE) << SHIFT_HZ) * \
(1000000/CLOCK_TICK_FACTOR) / (CLOCK_TICK_RATE/CLOCK_TICK_FACTOR)) \
<< (SHIFT_SCALE-SHIFT_HZ)) / HZ)
typedef unsigned long cycles_t; typedef unsigned long cycles_t;
static inline cycles_t get_cycles(void) static inline cycles_t get_cycles(void)

View File

@ -12,9 +12,6 @@
#define CLOCK_TICK_RATE (CONFIG_BUS_CLOCK / CONFIG_TIMER_DIVIDE) #define CLOCK_TICK_RATE (CONFIG_BUS_CLOCK / CONFIG_TIMER_DIVIDE)
#define CLOCK_TICK_FACTOR 20 /* Factor of both 1000000 and CLOCK_TICK_RATE */ #define CLOCK_TICK_FACTOR 20 /* Factor of both 1000000 and CLOCK_TICK_RATE */
#define FINETUNE ((((((long)LATCH * HZ - CLOCK_TICK_RATE) << SHIFT_HZ) * \
(1000000/CLOCK_TICK_FACTOR) / (CLOCK_TICK_RATE/CLOCK_TICK_FACTOR)) \
<< (SHIFT_SCALE-SHIFT_HZ)) / HZ)
#ifdef __KERNEL__ #ifdef __KERNEL__
/* /*

View File

@ -17,9 +17,6 @@
#define CLOCK_TICK_RATE 1193180 /* Underlying HZ */ #define CLOCK_TICK_RATE 1193180 /* Underlying HZ */
#define CLOCK_TICK_FACTOR 20 /* Factor of both 1000000 and CLOCK_TICK_RATE */ #define CLOCK_TICK_FACTOR 20 /* Factor of both 1000000 and CLOCK_TICK_RATE */
#define FINETUNE ((((((long)LATCH * HZ - CLOCK_TICK_RATE) << SHIFT_HZ) * \
(1000000/CLOCK_TICK_FACTOR) / (CLOCK_TICK_RATE/CLOCK_TICK_FACTOR)) \
<< (SHIFT_SCALE-SHIFT_HZ)) / HZ)
typedef unsigned long cycles_t; typedef unsigned long cycles_t;

View File

@ -31,9 +31,6 @@
#define CLOCK_TICK_RATE 1193180 /* (everyone is using this value) */ #define CLOCK_TICK_RATE 1193180 /* (everyone is using this value) */
#define CLOCK_TICK_FACTOR 20 /* Factor of both 10^6 and CLOCK_TICK_RATE */ #define CLOCK_TICK_FACTOR 20 /* Factor of both 10^6 and CLOCK_TICK_RATE */
#define FINETUNE ((((((long)LATCH * HZ - CLOCK_TICK_RATE) << SHIFT_HZ) * \
(1000000/CLOCK_TICK_FACTOR) / (CLOCK_TICK_RATE/CLOCK_TICK_FACTOR)) \
<< (SHIFT_SCALE-SHIFT_HZ)) / HZ)
#ifdef CONFIG_XTENSA_CALIBRATE_CCOUNT #ifdef CONFIG_XTENSA_CALIBRATE_CCOUNT
extern unsigned long ccount_per_jiffy; extern unsigned long ccount_per_jiffy;

View File

@ -74,24 +74,17 @@
#define MAXTC 10 /* maximum time constant (shift) */ #define MAXTC 10 /* maximum time constant (shift) */
/* /*
* The SHIFT_SCALE define establishes the decimal point of the time_phase * The SHIFT_UPDATE define establishes the decimal point of the
* variable which serves as an extension to the low-order bits of the * time_offset variable which represents the current offset with
* system clock variable. The SHIFT_UPDATE define establishes the decimal * respect to standard time.
* point of the time_offset variable which represents the current offset
* with respect to standard time. The FINENSEC define represents 1 nsec in
* scaled units.
* *
* SHIFT_USEC defines the scaling (shift) of the time_freq and * SHIFT_USEC defines the scaling (shift) of the time_freq and
* time_tolerance variables, which represent the current frequency * time_tolerance variables, which represent the current frequency
* offset and maximum frequency tolerance. * offset and maximum frequency tolerance.
*
* FINENSEC is 1 ns in SHIFT_UPDATE units of the time_phase variable.
*/ */
#define SHIFT_SCALE 22 /* phase scale (shift) */
#define SHIFT_UPDATE (SHIFT_HZ + 1) /* time offset scale (shift) */ #define SHIFT_UPDATE (SHIFT_HZ + 1) /* time offset scale (shift) */
#define SHIFT_USEC 16 /* frequency offset scale (shift) */ #define SHIFT_USEC 16 /* frequency offset scale (shift) */
#define SHIFT_NSEC 12 /* kernel frequency offset scale */ #define SHIFT_NSEC 12 /* kernel frequency offset scale */
#define FINENSEC (1L << (SHIFT_SCALE - 10)) /* ~1 ns in phase units */
#define MAXPHASE 512000L /* max phase error (us) */ #define MAXPHASE 512000L /* max phase error (us) */
#define MAXFREQ (512L << SHIFT_USEC) /* max frequency error (ppm) */ #define MAXFREQ (512L << SHIFT_USEC) /* max frequency error (ppm) */