1 From 6f1c62440eb6846cb8045d7a5480ec7bbe47c96f Mon Sep 17 00:00:00 2001
2 From: =?UTF-8?q?Rafa=C5=82=20Mi=C5=82ecki?= <rafal@milecki.pl>
3 Date: Mon, 15 Aug 2016 10:30:41 +0200
4 Subject: [PATCH] BCM53573 minor hacks
6 Content-Type: text/plain; charset=UTF-8
7 Content-Transfer-Encoding: 8bit
9 Signed-off-by: Rafał Miłecki <rafal@milecki.pl>
12 --- a/arch/arm/boot/dts/bcm53573.dtsi
13 +++ b/arch/arm/boot/dts/bcm53573.dtsi
19 + compatible = "simple-mfd", "syscon";
20 + reg = <0x18012000 0x00001000>;
23 + compatible = "brcm,bcm53573-ilp";
26 + clock-output-names = "ilp";
31 + compatible = "arm,armv7-timer";
32 + interrupts = <GIC_PPI 13 0>,
42 --- a/drivers/bcma/main.c
43 +++ b/drivers/bcma/main.c
44 @@ -349,14 +349,6 @@ static int bcma_register_devices(struct
48 -#ifdef CONFIG_BCMA_SFLASH
49 - if (bus->drv_cc.sflash.present) {
50 - err = platform_device_register(&bcma_sflash_dev);
52 - bcma_err(bus, "Error registering serial flash\n");
56 #ifdef CONFIG_BCMA_NFLASH
57 if (bus->drv_cc.nflash.present) {
58 err = platform_device_register(&bcma_nflash_dev);
59 @@ -437,6 +429,14 @@ int bcma_bus_register(struct bcma_bus *b
60 bcma_register_core(bus, core);
63 +#ifdef CONFIG_BCMA_SFLASH
64 + if (bus->drv_cc.sflash.present) {
65 + err = platform_device_register(&bcma_sflash_dev);
67 + bcma_err(bus, "Error registering serial flash\n");
71 /* Try to get SPROM */
72 err = bcma_sprom_get(bus);
74 --- a/drivers/clocksource/arm_arch_timer.c
75 +++ b/drivers/clocksource/arm_arch_timer.c
77 #include <linux/smp.h>
78 #include <linux/cpu.h>
79 #include <linux/cpu_pm.h>
80 +#include <linux/clk.h>
81 #include <linux/clockchips.h>
82 #include <linux/clocksource.h>
83 #include <linux/interrupt.h>
84 @@ -376,6 +377,16 @@ arch_timer_detect_rate(void __iomem *cnt
85 arch_timer_rate = arch_timer_get_cntfrq();
88 + /* Get clk rate through clk driver if present */
89 + if (!arch_timer_rate) {
90 + struct clk *clk = of_clk_get(np, 0);
93 + if (!clk_prepare_enable(clk))
94 + arch_timer_rate = clk_get_rate(clk);
98 /* Check the timer frequency. */
99 if (arch_timer_rate == 0)
100 pr_warn("Architected timer frequency not available\n");