ARM: shmobile: rcar-gen2: Update for of_get_flat_dt_prop() update
authorGeert Uytterhoeven <geert+renesas@glider.be>
Thu, 12 Jun 2014 08:42:22 +0000 (10:42 +0200)
committerSimon Horman <horms@verge.net.au>
Fri, 5 Dec 2014 00:24:44 +0000 (09:24 +0900)
commitaf6635a3ced06089e1a67f285d981f20dbf561ae
treed70cea3d5b7181a559c3ddeb86ef793bfc9b131a
parentc484362f80d5f0199de4c711f4f6d94dd9c38aae
ARM: shmobile: rcar-gen2: Update for of_get_flat_dt_prop() update

Commit 9d0c4dfedd96ee54fc075b16d02f82499c8cc3a6 ("of/fdt: update
of_get_flat_dt_prop in prep for libfdt") changed the function prototypes
of of_get_flat_dt_prop():
  - The return type was made const,
  - The last parameter was changed from "unsigned long *" to "int *".
and dt_mem_next_cell():
  - The second parameter was made const.

This causes the following compiler warnings:

arch/arm/mach-shmobile/setup-rcar-gen2.c: In function 'rcar_gen2_scan_mem':
arch/arm/mach-shmobile/setup-rcar-gen2.c:125:15: warning: initialization discards 'const' qualifier from pointer target type [enabled by default]
arch/arm/mach-shmobile/setup-rcar-gen2.c:142:2: warning: passing argument 3 of 'of_get_flat_dt_prop' from incompatible pointer type [enabled by default]
include/linux/of_fdt.h:53:20: note: expected 'int *' but argument is of type 'long unsigned int *'
arch/arm/mach-shmobile/setup-rcar-gen2.c:142:6: warning: assignment discards 'const' qualifier from pointer target type [enabled by default]
arch/arm/mach-shmobile/setup-rcar-gen2.c:144:3: warning: passing argument 3 of 'of_get_flat_dt_prop' from incompatible pointer type [enabled by default]
include/linux/of_fdt.h:53:20: note: expected 'int *' but argument is of type 'long unsigned int *'
arch/arm/mach-shmobile/setup-rcar-gen2.c:144:7: warning: assignment discards 'const' qualifier from pointer target type [enabled by default]
arch/arm/mach-shmobile/setup-rcar-gen2.c:152:3: warning: passing argument 2 of 'dt_mem_next_cell' from incompatible pointer type [enabled by default]
include/linux/of_fdt.h:69:12: note: expected 'const __be32 **' but argument is of type '__be32 **'
arch/arm/mach-shmobile/setup-rcar-gen2.c:153:3: warning: passing argument 2 of 'dt_mem_next_cell' from incompatible pointer type [enabled by default]
include/linux/of_fdt.h:69:12: note: expected 'const __be32 **' but argument is of type '__be32 **'

Update the variable types in rcar_gen2_scan_mem() to fix this.

Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be>
Acked-by: Magnus Damm <damm+renesas@opensource.se>
[horms+renesas@verge.net.au: rebased]
Signed-off-by: Simon Horman <horms+renesas@verge.net.au>
(cherry picked from commit 83850b04ae7744f51681533fb7afb645e66ce8fe)
Signed-off-by: Simon Horman <horms+renesas@verge.net.au>
arch/arm/mach-shmobile/setup-rcar-gen2.c