Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 73b08d2a authored by Thomas Gleixner's avatar Thomas Gleixner Committed by Linus Torvalds
Browse files

[PATCH] clocksource: replace is_continuous by a flag field



Using a flag filed allows to encode more than one information into a variable.
Preparatory patch for the generic clocksource verification.

[mingo@elte.hu: convert vmitime.c to the new clocksource flag]
Signed-off-by: default avatarThomas Gleixner <tglx@linutronix.de>
Signed-off-by: default avatarIngo Molnar <mingo@elte.hu>
Cc: john stultz <johnstul@us.ibm.com>
Cc: Roman Zippel <zippel@linux-m68k.org>
Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
parent 95492e46
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -26,7 +26,7 @@ static struct clocksource clocksource_hpet = {
	.mask		= HPET_MASK,
	.mult		= 0, /* set below */
	.shift		= HPET_SHIFT,
	.is_continuous	= 1,
	.flags		= CLOCK_SOURCE_IS_CONTINUOUS,
};

static int __init init_hpet_clocksource(void)
+5 −2
Original line number Diff line number Diff line
@@ -314,7 +314,8 @@ static struct clocksource clocksource_tsc = {
	.mult			= 0, /* to be set */
	.shift			= 22,
	.update_callback	= tsc_update_callback,
	.is_continuous		= 1,
	.flags			= CLOCK_SOURCE_IS_CONTINUOUS |
				  CLOCK_SOURCE_MUST_VERIFY,
};

static int tsc_update_callback(void)
@@ -434,8 +435,10 @@ static int __init init_tsc_clocksource(void)
		clocksource_tsc.mult = clocksource_khz2mult(current_tsc_khz,
							clocksource_tsc.shift);
		/* lower the rating if we already know its unstable: */
		if (check_tsc_unstable())
		if (check_tsc_unstable()) {
			clocksource_tsc.rating = 0;
			clocksource_tsc.flags &= ~CLOCK_SOURCE_IS_CONTINUOUS;
		}

		init_timer(&verify_tsc_freq_timer);
		verify_tsc_freq_timer.function = verify_tsc_freq;
+1 −1
Original line number Diff line number Diff line
@@ -115,7 +115,7 @@ static struct clocksource clocksource_vmi = {
	.mask			= CLOCKSOURCE_MASK(64),
	.mult			= 0, /* to be set */
	.shift			= 22,
	.is_continuous		= 1,
	.flags			= CLOCK_SOURCE_IS_CONTINUOUS,
};


+2 −1
Original line number Diff line number Diff line
@@ -72,7 +72,8 @@ static struct clocksource clocksource_acpi_pm = {
	.mask		= (cycle_t)ACPI_PM_MASK,
	.mult		= 0, /*to be caluclated*/
	.shift		= 22,
	.is_continuous	= 1,
	.flags		= CLOCK_SOURCE_IS_CONTINUOUS,

};


+1 −1
Original line number Diff line number Diff line
@@ -31,7 +31,7 @@ static struct clocksource clocksource_cyclone = {
	.mask		= CYCLONE_TIMER_MASK,
	.mult		= 10,
	.shift		= 0,
	.is_continuous	= 1,
	.flags		= CLOCK_SOURCE_IS_CONTINUOUS,
};

static int __init init_cyclone_clocksource(void)
Loading