Thread (20 messages) 20 messages, 3 authors, 2020-02-27

Re: [PATCH V4 5/8] memory: tegra: Add EMC scaling support code for Tegra210

From: Dmitry Osipenko <digetx@gmail.com>
Date: 2019-05-30 16:14:13
Also in: linux-clk, linux-devicetree, linux-tegra

29.05.2019 11:21, Joseph Lo пишет:
This patch adds the required APIs and variables for the EMC scaling
sequence code on Tegra210.

Based on the work of Peter De Schrijver [off-list ref].

Signed-off-by: Joseph Lo <redacted>
---
v4:
- fix the API with generic naming
- use 'u16' in 'struct emc_table_register_offset'
---
 
+extern const struct emc_table_register_offset reg_off;
+extern unsigned long dram_over_temp_state;
Please avoid global variables where they are not really needed.

Add reg_off pointer to tegra_emc.

Remove dram_over_temp_state variable entirely and replace it with
TEGRA_DRAM_OVER_TEMP_NONE in the code since nothing changes the variable.

Again, prepend all global symbols with tegra210_.

Alternatively you could simply include tegra210-emc-cc-r21021.c into
tegra210-emc.c, I don't see anything wrong with that variant.

	#include "tegra210-emc-cc-r21021.c"

Or you could squash it all into a single source file if variants other
than "r21021" are not planned to be supported. This will help to reduce
messiness of the code and will allow compiler to better optimize it all.

-- 
Dmitry

_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help