* [PATCH 3/4] ARM: nomadik: move l2x0 setup to device tree
@ 2015-08-02 21:56 Linus Walleij
2015-08-02 22:06 ` Russell King - ARM Linux
0 siblings, 1 reply; 3+ messages in thread
From: Linus Walleij @ 2015-08-02 21:56 UTC (permalink / raw)
To: linux-arm-kernel
The cache setup magic value in the Nomadik machine is plain wrong,
the correct settings can be done using device tree in accordance
with the settings from ST's own port.
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
---
arch/arm/boot/dts/ste-nomadik-stn8815.dtsi | 7 +++++++
arch/arm/mach-nomadik/cpu-8815.c | 5 ++---
2 files changed, 9 insertions(+), 3 deletions(-)
diff --git a/arch/arm/boot/dts/ste-nomadik-stn8815.dtsi b/arch/arm/boot/dts/ste-nomadik-stn8815.dtsi
index 0edab6d23211..defabe053114 100644
--- a/arch/arm/boot/dts/ste-nomadik-stn8815.dtsi
+++ b/arch/arm/boot/dts/ste-nomadik-stn8815.dtsi
@@ -21,6 +21,13 @@
interrupts = <30>;
cache-unified;
cache-level = <2>;
+ cache-size = <131072>;
+ cache-sets = <512>;
+ cache-line-size = <32>;
+ /* At full speed latency must be >=2 */
+ arm,tag-latency = <2>;
+ arm,data-latency = <2 2>;
+ arm,dirty-latency = <2>;
};
mtu0: mtu at 101e2000 {
diff --git a/arch/arm/mach-nomadik/cpu-8815.c b/arch/arm/mach-nomadik/cpu-8815.c
index 82831dc6122f..009754055f09 100644
--- a/arch/arm/mach-nomadik/cpu-8815.c
+++ b/arch/arm/mach-nomadik/cpu-8815.c
@@ -114,9 +114,8 @@ static const char * cpu8815_board_compat[] = {
};
DT_MACHINE_START(NOMADIK_DT, "Nomadik STn8815")
- /* At full speed latency must be >=2, so 0x249 in low bits */
- .l2c_aux_val = 0x00700249,
- .l2c_aux_mask = 0xfe0fefff,
+ .l2c_aux_val = 0x0,
+ .l2c_aux_mask = ~0x0UL,
.map_io = cpu8815_map_io,
.restart = cpu8815_restart,
.dt_compat = cpu8815_board_compat,
--
2.4.3
^ permalink raw reply related [flat|nested] 3+ messages in thread* [PATCH 3/4] ARM: nomadik: move l2x0 setup to device tree
2015-08-02 21:56 [PATCH 3/4] ARM: nomadik: move l2x0 setup to device tree Linus Walleij
@ 2015-08-02 22:06 ` Russell King - ARM Linux
2015-08-02 22:43 ` Linus Walleij
0 siblings, 1 reply; 3+ messages in thread
From: Russell King - ARM Linux @ 2015-08-02 22:06 UTC (permalink / raw)
To: linux-arm-kernel
On Sun, Aug 02, 2015 at 11:56:33PM +0200, Linus Walleij wrote:
> - /* At full speed latency must be >=2, so 0x249 in low bits */
> - .l2c_aux_val = 0x00700249,
> - .l2c_aux_mask = 0xfe0fefff,
> + .l2c_aux_val = 0x0,
> + .l2c_aux_mask = ~0x0UL,
It always amazes me by the things people come up with... what prompted
the addition of "UL" on that constant? Why do you think it needs it?
A simple:
.l2c_aux_val = 0,
.l2c_aux_mask = ~0,
will suffice.
--
FTTC broadband for 0.8mile line: currently at 10.5Mbps down 400kbps up
according to speedtest.net.
^ permalink raw reply [flat|nested] 3+ messages in thread
* [PATCH 3/4] ARM: nomadik: move l2x0 setup to device tree
2015-08-02 22:06 ` Russell King - ARM Linux
@ 2015-08-02 22:43 ` Linus Walleij
0 siblings, 0 replies; 3+ messages in thread
From: Linus Walleij @ 2015-08-02 22:43 UTC (permalink / raw)
To: linux-arm-kernel
On Mon, Aug 3, 2015 at 12:06 AM, Russell King - ARM Linux
<linux@arm.linux.org.uk> wrote:
> On Sun, Aug 02, 2015 at 11:56:33PM +0200, Linus Walleij wrote:
>> - /* At full speed latency must be >=2, so 0x249 in low bits */
>> - .l2c_aux_val = 0x00700249,
>> - .l2c_aux_mask = 0xfe0fefff,
>> + .l2c_aux_val = 0x0,
>> + .l2c_aux_mask = ~0x0UL,
>
> It always amazes me by the things people come up with... what prompted
> the addition of "UL" on that constant? Why do you think it needs it?
Good old mindless cut'n'paste.
Will fix, thanks!
Yours,
Linus Walleij
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2015-08-02 22:43 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-08-02 21:56 [PATCH 3/4] ARM: nomadik: move l2x0 setup to device tree Linus Walleij
2015-08-02 22:06 ` Russell King - ARM Linux
2015-08-02 22:43 ` Linus Walleij
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox