summaryrefslogtreecommitdiffstats
path: root/drivers/of
diff options
context:
space:
mode:
authorFabio Estevam <fabio.estevam@freescale.com>2012-11-12 18:30:49 -0200
committerRob Herring <rob.herring@calxeda.com>2012-11-20 22:57:40 -0600
commite55b0829cbace88f4b50036432a12146d22cd106 (patch)
tree8ec8928b36aff4599a51e30bbb15ca62036ae059 /drivers/of
parentc22618a11d1ba2966bd2cfd5e4918ed4f2dad13e (diff)
downloadlinux-e55b0829cbace88f4b50036432a12146d22cd106.tar.gz
linux-e55b0829cbace88f4b50036432a12146d22cd106.tar.bz2
linux-e55b0829cbace88f4b50036432a12146d22cd106.zip
of: fdt: Constify 'pathp'
Constify 'pathp' in order to get rid of the following warning: drivers/of/fdt.c:491:10: warning: assignment discards 'const' qualifier from pointer target type [enabled by default] Signed-off-by: Fabio Estevam <fabio.estevam@freescale.com> [Rob Herring: also constify np and lp] Signed-off-by: Rob Herring <rob.herring@calxeda.com>
Diffstat (limited to 'drivers/of')
-rw-r--r--drivers/of/fdt.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/of/fdt.c b/drivers/of/fdt.c
index c8be32644c85..135b8083212a 100644
--- a/drivers/of/fdt.c
+++ b/drivers/of/fdt.c
@@ -460,7 +460,7 @@ int __init of_scan_flat_dt(int (*it)(unsigned long node,
do {
u32 tag = be32_to_cpup((__be32 *)p);
- char *pathp;
+ const char *pathp;
p += 4;
if (tag == OF_DT_END_NODE) {
@@ -488,7 +488,7 @@ int __init of_scan_flat_dt(int (*it)(unsigned long node,
pathp = (char *)p;
p = ALIGN(p + strlen(pathp) + 1, 4);
if ((*pathp) == '/') {
- char *lp, *np;
+ const char *lp, *np;
for (lp = NULL, np = pathp; *np; np++)
if ((*np) == '/')
lp = np+1;