diff options
author | Grant Likely <grant.likely@secretlab.ca> | 2012-11-14 23:37:12 +0100 |
---|---|---|
committer | Grant Likely <grant.likely@secretlab.ca> | 2012-11-17 13:05:57 +0100 |
commit | c22618a11d1ba2966bd2cfd5e4918ed4f2dad13e (patch) | |
tree | e317e1413afd8f80ea4ddc036703ff447c1c0901 /arch/sparc/kernel | |
parent | arm-dt: Enable DT proc updates. (diff) | |
download | linux-c22618a11d1ba2966bd2cfd5e4918ed4f2dad13e.tar.xz linux-c22618a11d1ba2966bd2cfd5e4918ed4f2dad13e.zip |
drivers/of: Constify device_node->name and ->path_component_name
Neither of these should ever be changed once set. Make them const and
fix up the users that try to modify it in-place. In one case
kmalloc+memcpy is replaced with kstrdup() to avoid modifying the string.
Build tested with defconfigs on ARM, PowerPC, Sparc, MIPS, x86 among
others.
Signed-off-by: Grant Likely <grant.likely@secretlab.ca>
Acked-by: David S. Miller <davem@davemloft.net>
Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Cc: Julian Calaby <julian.calaby@gmail.com>
Diffstat (limited to 'arch/sparc/kernel')
-rw-r--r-- | arch/sparc/kernel/pci_impl.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/arch/sparc/kernel/pci_impl.h b/arch/sparc/kernel/pci_impl.h index 918a2031c8bb..5f688531f48c 100644 --- a/arch/sparc/kernel/pci_impl.h +++ b/arch/sparc/kernel/pci_impl.h @@ -88,7 +88,7 @@ struct pci_pbm_info { int chip_revision; /* Name used for top-level resources. */ - char *name; + const char *name; /* OBP specific information. */ struct platform_device *op; |