diff options
Diffstat (limited to 'drivers')
| -rw-r--r-- | drivers/clocksource/Kconfig | 1 | ||||
| -rw-r--r-- | drivers/clocksource/clksrc-of.c | 3 | ||||
| -rw-r--r-- | drivers/clocksource/em_sti.c | 2 | ||||
| -rw-r--r-- | drivers/clocksource/exynos_mct.c | 10 |
4 files changed, 14 insertions, 2 deletions
diff --git a/drivers/clocksource/Kconfig b/drivers/clocksource/Kconfig index 41c69469ce20..971d796e071d 100644 --- a/drivers/clocksource/Kconfig +++ b/drivers/clocksource/Kconfig | |||
| @@ -26,6 +26,7 @@ config DW_APB_TIMER_OF | |||
| 26 | 26 | ||
| 27 | config ARMADA_370_XP_TIMER | 27 | config ARMADA_370_XP_TIMER |
| 28 | bool | 28 | bool |
| 29 | select CLKSRC_OF | ||
| 29 | 30 | ||
| 30 | config ORION_TIMER | 31 | config ORION_TIMER |
| 31 | select CLKSRC_OF | 32 | select CLKSRC_OF |
diff --git a/drivers/clocksource/clksrc-of.c b/drivers/clocksource/clksrc-of.c index 37f5325bec95..b9ddd9e3a2f5 100644 --- a/drivers/clocksource/clksrc-of.c +++ b/drivers/clocksource/clksrc-of.c | |||
| @@ -30,6 +30,9 @@ void __init clocksource_of_init(void) | |||
| 30 | clocksource_of_init_fn init_func; | 30 | clocksource_of_init_fn init_func; |
| 31 | 31 | ||
| 32 | for_each_matching_node_and_match(np, __clksrc_of_table, &match) { | 32 | for_each_matching_node_and_match(np, __clksrc_of_table, &match) { |
| 33 | if (!of_device_is_available(np)) | ||
| 34 | continue; | ||
| 35 | |||
| 33 | init_func = match->data; | 36 | init_func = match->data; |
| 34 | init_func(np); | 37 | init_func(np); |
| 35 | } | 38 | } |
diff --git a/drivers/clocksource/em_sti.c b/drivers/clocksource/em_sti.c index b9c81b7c3a3b..3a5909c12d42 100644 --- a/drivers/clocksource/em_sti.c +++ b/drivers/clocksource/em_sti.c | |||
| @@ -301,7 +301,7 @@ static void em_sti_register_clockevent(struct em_sti_priv *p) | |||
| 301 | ced->name = dev_name(&p->pdev->dev); | 301 | ced->name = dev_name(&p->pdev->dev); |
| 302 | ced->features = CLOCK_EVT_FEAT_ONESHOT; | 302 | ced->features = CLOCK_EVT_FEAT_ONESHOT; |
| 303 | ced->rating = 200; | 303 | ced->rating = 200; |
| 304 | ced->cpumask = cpumask_of(0); | 304 | ced->cpumask = cpu_possible_mask; |
| 305 | ced->set_next_event = em_sti_clock_event_next; | 305 | ced->set_next_event = em_sti_clock_event_next; |
| 306 | ced->set_mode = em_sti_clock_event_mode; | 306 | ced->set_mode = em_sti_clock_event_mode; |
| 307 | 307 | ||
diff --git a/drivers/clocksource/exynos_mct.c b/drivers/clocksource/exynos_mct.c index 5b34768f4d7c..62b0de6a1837 100644 --- a/drivers/clocksource/exynos_mct.c +++ b/drivers/clocksource/exynos_mct.c | |||
| @@ -428,7 +428,6 @@ static int exynos4_local_timer_setup(struct clock_event_device *evt) | |||
| 428 | evt->irq); | 428 | evt->irq); |
| 429 | return -EIO; | 429 | return -EIO; |
| 430 | } | 430 | } |
| 431 | irq_set_affinity(evt->irq, cpumask_of(cpu)); | ||
| 432 | } else { | 431 | } else { |
| 433 | enable_percpu_irq(mct_irqs[MCT_L0_IRQ], 0); | 432 | enable_percpu_irq(mct_irqs[MCT_L0_IRQ], 0); |
| 434 | } | 433 | } |
| @@ -449,6 +448,7 @@ static int exynos4_mct_cpu_notify(struct notifier_block *self, | |||
| 449 | unsigned long action, void *hcpu) | 448 | unsigned long action, void *hcpu) |
| 450 | { | 449 | { |
| 451 | struct mct_clock_event_device *mevt; | 450 | struct mct_clock_event_device *mevt; |
| 451 | unsigned int cpu; | ||
| 452 | 452 | ||
| 453 | /* | 453 | /* |
| 454 | * Grab cpu pointer in each case to avoid spurious | 454 | * Grab cpu pointer in each case to avoid spurious |
| @@ -459,6 +459,12 @@ static int exynos4_mct_cpu_notify(struct notifier_block *self, | |||
| 459 | mevt = this_cpu_ptr(&percpu_mct_tick); | 459 | mevt = this_cpu_ptr(&percpu_mct_tick); |
| 460 | exynos4_local_timer_setup(&mevt->evt); | 460 | exynos4_local_timer_setup(&mevt->evt); |
| 461 | break; | 461 | break; |
| 462 | case CPU_ONLINE: | ||
| 463 | cpu = (unsigned long)hcpu; | ||
| 464 | if (mct_int_type == MCT_INT_SPI) | ||
| 465 | irq_set_affinity(mct_irqs[MCT_L0_IRQ + cpu], | ||
| 466 | cpumask_of(cpu)); | ||
| 467 | break; | ||
| 462 | case CPU_DYING: | 468 | case CPU_DYING: |
| 463 | mevt = this_cpu_ptr(&percpu_mct_tick); | 469 | mevt = this_cpu_ptr(&percpu_mct_tick); |
| 464 | exynos4_local_timer_stop(&mevt->evt); | 470 | exynos4_local_timer_stop(&mevt->evt); |
| @@ -500,6 +506,8 @@ static void __init exynos4_timer_resources(struct device_node *np, void __iomem | |||
| 500 | &percpu_mct_tick); | 506 | &percpu_mct_tick); |
| 501 | WARN(err, "MCT: can't request IRQ %d (%d)\n", | 507 | WARN(err, "MCT: can't request IRQ %d (%d)\n", |
| 502 | mct_irqs[MCT_L0_IRQ], err); | 508 | mct_irqs[MCT_L0_IRQ], err); |
| 509 | } else { | ||
| 510 | irq_set_affinity(mct_irqs[MCT_L0_IRQ], cpumask_of(0)); | ||
| 503 | } | 511 | } |
| 504 | 512 | ||
| 505 | err = register_cpu_notifier(&exynos4_mct_cpu_nb); | 513 | err = register_cpu_notifier(&exynos4_mct_cpu_nb); |
