mfd: constify properties in mfd_cell
PATCH 1/1 mfd: constify properties in mfd_cell
Constify 'struct property_entry *properties' inmfd_cell and platform_device. It is always passed
around as a pointer const struct.
--- include/linux/mfd/core.h | 2 +- include/linux/platform_device.h | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-)
include/linux/mfd/core.h +1 -1
@@ -70,7 +70,7 @@ struct mfd_cell {size_t pdata_size;/* device properties passed to the sub devices drivers */ -struct property_entry *properties; +const struct property_entry *properties;/* * Device Tree compatible string
include/linux/platform_device.h +1 -1
@@ -89,7 +89,7 @@ struct platform_device_info {size_t size_data;u64 dma_mask; -struct property_entry *properties; +const struct property_entry *properties; };extern struct platform_device *platform_device_register_full (const struct platform_device_info *pdevinfo);
Signature · 1 line
2.21.1
Quoted 5 lines · Tomas Winkler
Constify 'struct
property_entry*properties' inmfd_cellandplatform_device. It is always passed
around as a pointer const struct.
After
commit 277036f05be242540b7bfe75f226107d04f51b06
Author: Jan Kiszka <[email protected]> Date: Fri Jun 2 07:43:27 2017 +0200
platform: Accept const properties
this one makes sense.
Does intel-lpss* compile with this change?
Quoted 35 lines
Signed-off-by Tomas Winkler <[email protected]>--- include/linux/mfd/core.h | 2 +- include/linux/platform_device.h | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-)include/linux/mfd/core.h +1
-1@@ -70,7 +70,7 @@ struct mfd_cell {size_t pdata_size;/* device properties passed to the sub devices drivers */ -struct property_entry *properties; +const struct property_entry *properties;/* * Device Tree compatible string include/linux/platform_device.h +1
-2@@ -89,7 +89,7 @@ struct platform_device_info {size_t size_data;u64 dma_mask; -struct property_entry *properties; +const struct property_entry *properties; };extern struct platform_device *platform_device_register_full (const struct platform_device_info *pdevinfo); --2.21.1
Signature · 2 lines
With Best Regards, Andy Shevchenko
Quoted 15 lines
Quoted 4 lines · Tomas Winkler
Constify 'struct
property_entry*properties' inmfd_cellandplatform_device. It is always passed around as a pointer const struct.After
commit
277036f05be242540b7bfe75f226107d04f51b06Author: Jan Kiszka <[email protected]> Date: Fri Jun 2 07:43:27 2017 +0200
Quoted 7 lines
platform: Accept const properties
this one makes sense.
Reviewed-by Andy Shevchenko <[email protected]>Does intel-lpss* compile with this change?
Yes, It does.
Quoted 39 lines · Tomas Winkler
Constify 'struct
property_entry*properties' inmfd_cellandplatform_device. It is always passed
around as a pointer const struct.Signed-off-by Tomas Winkler <[email protected]>--- include/linux/mfd/core.h | 2 +- include/linux/platform_device.h | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-)include/linux/mfd/core.h +1
-1@@ -70,7 +70,7 @@ struct mfd_cell {size_t pdata_size;/* device properties passed to the sub devices drivers */ -struct property_entry *properties; +const struct property_entry *properties;/* * Device Tree compatible string include/linux/platform_device.h +1
-1@@ -89,7 +89,7 @@ struct platform_device_info {size_t size_data;u64 dma_mask; -struct property_entry *properties; +const struct property_entry *properties; };extern struct platform_device *platform_device_register_full (const struct platform_device_info *pdevinfo);Signature · 1 line
2.21.1
This really is two different patches, can you split and resend?
thanks,
gre gk-h