* [PATCH] ARM: tegra: emc: correction of ram-code parsing from dt
@ 2013-05-12 20:26 Dmitry Osipenko
[not found] ` <1368390409-14156-1-git-send-email-digetx-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
0 siblings, 1 reply; 3+ messages in thread
From: Dmitry Osipenko @ 2013-05-12 20:26 UTC (permalink / raw)
To: swarren-3lzwWm7+Weoh9ZMKESR00Q
Cc: linux-tegra-u79uwXL29TY76Z2rM5mHXA, Dmitry Osipenko
Change tegra_emc_ramcode_devnode() to get ram-code from child node instead of
parent.
Signed-off-by: Dmitry Osipenko <digetx-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
---
For me it looks like it should be better to place ram-code inside of table
nodes, so num_tables will be incremented if table has valid ram-code and table
with invalid ram-code will be skipped on getting table params loop. This avoids
placing of #address-cells and #size-cells in nodes with ram-code.
If it looks ok, I may send new patch.
arch/arm/mach-tegra/tegra2_emc.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/arch/arm/mach-tegra/tegra2_emc.c b/arch/arm/mach-tegra/tegra2_emc.c
index 9e8bdfa..25f0189 100644
--- a/arch/arm/mach-tegra/tegra2_emc.c
+++ b/arch/arm/mach-tegra/tegra2_emc.c
@@ -183,7 +183,7 @@ static struct device_node *tegra_emc_ramcode_devnode(struct device_node *np)
u32 reg;
for_each_child_of_node(np, iter) {
- if (of_property_read_u32(np, "nvidia,ram-code", ®))
+ if (of_property_read_u32(iter, "nvidia,ram-code", ®))
continue;
if (reg == tegra_bct_strapping)
return of_node_get(iter);
--
1.8.2.1
^ permalink raw reply related [flat|nested] 3+ messages in thread[parent not found: <1368390409-14156-1-git-send-email-digetx-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>]
* Re: [PATCH] ARM: tegra: emc: correction of ram-code parsing from dt [not found] ` <1368390409-14156-1-git-send-email-digetx-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> @ 2013-05-17 23:53 ` Stephen Warren [not found] ` <5196C2EF.2060408-3lzwWm7+Weoh9ZMKESR00Q@public.gmane.org> 0 siblings, 1 reply; 3+ messages in thread From: Stephen Warren @ 2013-05-17 23:53 UTC (permalink / raw) To: Dmitry Osipenko; +Cc: linux-tegra-u79uwXL29TY76Z2rM5mHXA On 05/12/2013 02:26 PM, Dmitry Osipenko wrote: > Change tegra_emc_ramcode_devnode() to get ram-code from child node instead of > parent. I've applied this to Tegra's for-3.11/soc branch. > For me it looks like it should be better to place ram-code inside of table > nodes, so num_tables will be incremented if table has valid ram-code and table > with invalid ram-code will be skipped on getting table params loop. This avoids > placing of #address-cells and #size-cells in nodes with ram-code. > If it looks ok, I may send new patch. That would be a change to the DT binding. DT bindings are supposed to be a stable ABI, so we wouldn't want to change the binding unless there was a strong reason. I don't think there is one here. ^ permalink raw reply [flat|nested] 3+ messages in thread
[parent not found: <5196C2EF.2060408-3lzwWm7+Weoh9ZMKESR00Q@public.gmane.org>]
* Re: [PATCH] ARM: tegra: emc: correction of ram-code parsing from dt [not found] ` <5196C2EF.2060408-3lzwWm7+Weoh9ZMKESR00Q@public.gmane.org> @ 2013-05-20 10:06 ` Dmitry Osipenko 0 siblings, 0 replies; 3+ messages in thread From: Dmitry Osipenko @ 2013-05-20 10:06 UTC (permalink / raw) To: Stephen Warren; +Cc: linux-tegra-u79uwXL29TY76Z2rM5mHXA 18.05.2013 03:53, Stephen Warren пишет: > On 05/12/2013 02:26 PM, Dmitry Osipenko wrote: >> Change tegra_emc_ramcode_devnode() to get ram-code from child node instead of >> parent. > > I've applied this to Tegra's for-3.11/soc branch. > Thanks. >> For me it looks like it should be better to place ram-code inside of table >> nodes, so num_tables will be incremented if table has valid ram-code and table >> with invalid ram-code will be skipped on getting table params loop. This avoids >> placing of #address-cells and #size-cells in nodes with ram-code. >> If it looks ok, I may send new patch. > > That would be a change to the DT binding. DT bindings are supposed to be > a stable ABI, so we wouldn't want to change the binding unless there was > a strong reason. I don't think there is one here. > Ok. ^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2013-05-20 10:06 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-05-12 20:26 [PATCH] ARM: tegra: emc: correction of ram-code parsing from dt Dmitry Osipenko
[not found] ` <1368390409-14156-1-git-send-email-digetx-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
2013-05-17 23:53 ` Stephen Warren
[not found] ` <5196C2EF.2060408-3lzwWm7+Weoh9ZMKESR00Q@public.gmane.org>
2013-05-20 10:06 ` Dmitry Osipenko
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox