aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJon Medhurst <tixy@linaro.org>2015-08-03 15:32:43 +0100
committerAmit Pundir <amit.pundir@linaro.org>2015-09-10 22:05:46 +0530
commite384789ba498104603a5e28cc5dbd58f8c85d2ee (patch)
tree9cbcf02d3df0efa0b670c553ed07700d03a759bc
parent2e186453b747086806977d72e9b4785fbb83b10f (diff)
of/fdt: fix build warnings in early_init_dt_scan_chosen()
For some reason commit "of: fix CONFIG_CMDLINE_EXTEND" changed some variable types, restore these to the old types to avoid the following warnings: drivers/of/fdt.c: In function 'early_init_dt_scan_chosen': drivers/of/fdt.c:932:45: warning: passing argument 3 of 'of_get_flat_dt_prop' from incompatible pointer type p = of_get_flat_dt_prop(node, "bootargs", &l); ^ drivers/of/fdt.c:619:20: note: expected 'int *' but argument is of type 'long unsigned int *' const void *__init of_get_flat_dt_prop(unsigned long node, const char *name, ^ drivers/of/fdt.c:932:5: warning: assignment discards 'const' qualifier from pointer target type p = of_get_flat_dt_prop(node, "bootargs", &l); ^ Signed-off-by: Jon Medhurst <tixy@linaro.org>
-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 af3b78382d4a..821f6b591ce2 100644
--- a/drivers/of/fdt.c
+++ b/drivers/of/fdt.c
@@ -911,8 +911,8 @@ static const char *config_cmdline = "";
int __init early_init_dt_scan_chosen(unsigned long node, const char *uname,
int depth, void *data)
{
- unsigned long l = 0;
- char *p = NULL;
+ int l = 0;
+ const char *p = NULL;
char *cmdline = data;
pr_debug("search \"chosen\", depth: %d, uname: %s\n", depth, uname);