Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 113129
b: refs/heads/master
c: d8ada0a
h: refs/heads/master
i:
  113127: 840624d
v: v3
  • Loading branch information
David S. Miller committed Sep 12, 2008
1 parent 1c7235f commit 8b7880b
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 12 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: b0f1e7962f93a78630161c7c9fc263de43c101ac
refs/heads/master: d8ada0a2cd11c991d8193a3f7d37f1806c93c4a0
22 changes: 11 additions & 11 deletions trunk/arch/sparc64/kernel/time.c
Original file line number Diff line number Diff line change
Expand Up @@ -409,7 +409,7 @@ int update_persistent_clock(struct timespec now)
unsigned long cmos_regs;
EXPORT_SYMBOL(cmos_regs);

struct resource rtc_cmos_resource;
static struct resource rtc_cmos_resource;

static struct platform_device rtc_cmos_device = {
.name = "rtc_cmos",
Expand Down Expand Up @@ -621,7 +621,7 @@ fs_initcall(clock_init);
static unsigned long sparc64_init_timers(void)
{
struct device_node *dp;
unsigned long clock;
unsigned long freq;

dp = of_find_node_by_path("/");
if (tlb_type == spitfire) {
Expand All @@ -634,17 +634,17 @@ static unsigned long sparc64_init_timers(void)
if (manuf == 0x17 && impl == 0x13) {
/* Hummingbird, aka Ultra-IIe */
tick_ops = &hbtick_operations;
clock = of_getintprop_default(dp, "stick-frequency", 0);
freq = of_getintprop_default(dp, "stick-frequency", 0);
} else {
tick_ops = &tick_operations;
clock = local_cpu_data().clock_tick;
freq = local_cpu_data().clock_tick;
}
} else {
tick_ops = &stick_operations;
clock = of_getintprop_default(dp, "stick-frequency", 0);
freq = of_getintprop_default(dp, "stick-frequency", 0);
}

return clock;
return freq;
}

struct freq_table {
Expand Down Expand Up @@ -836,16 +836,16 @@ EXPORT_SYMBOL(udelay);

void __init time_init(void)
{
unsigned long clock = sparc64_init_timers();
unsigned long freq = sparc64_init_timers();

tb_ticks_per_usec = clock / USEC_PER_SEC;
tb_ticks_per_usec = freq / USEC_PER_SEC;

timer_ticks_per_nsec_quotient =
clocksource_hz2mult(clock, SPARC64_NSEC_PER_CYC_SHIFT);
clocksource_hz2mult(freq, SPARC64_NSEC_PER_CYC_SHIFT);

clocksource_tick.name = tick_ops->name;
clocksource_tick.mult =
clocksource_hz2mult(clock,
clocksource_hz2mult(freq,
clocksource_tick.shift);
clocksource_tick.read = tick_ops->get_tick;

Expand All @@ -856,7 +856,7 @@ void __init time_init(void)

sparc64_clockevent.name = tick_ops->name;

setup_clockevent_multiplier(clock);
setup_clockevent_multiplier(freq);

sparc64_clockevent.max_delta_ns =
clockevent_delta2ns(0x7fffffffffffffffUL, &sparc64_clockevent);
Expand Down

0 comments on commit 8b7880b

Please sign in to comment.