mfd: constify properties in mfd_cell
PATCH v2 1/2 mfd: constify properties in mfd_cell
Constify 'struct property_entry *properties' in mfd_cell It is always passed
around as a pointer const struct.
---
V2: drop platform_device part
include/linux/mfd/core.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
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
Signature · 1 line
2.21.1
PATCH 2/2 platform: constify properties in platform_device
Constify 'struct property_entry *properties' in platform_device. It is always passed around as a pointer const struct.
--- include/linux/platform_device.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
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 4 lines · Tomas Winkler
Constify 'struct
property_entry*properties' inmfd_cellIt is always passed
around as a pointer const struct.
I guess this should be second patch in the split and it's actually dependent to the first one (won't we get a compiler warning when we drop const qualifier during assignment?).
Quoted 5 lines
Reviewed-by Andy Shevchenko <[email protected]>Signed-off-by Tomas Winkler <[email protected]>---
V2: drop
platform_devicepart
Btw, when you prepare series, you may use -vX command line parameter, where X is a version number. The scripts will put v2 in each Subject line uniformly.
Signature · 2 lines
With Best Regards, Andy Shevchenko
Quoted 16 lines
Quoted 3 lines · Tomas Winkler
Constify 'struct
property_entry*properties' inmfd_cellIt is always passed around as a pointer const struct.I guess this should be second patch in the split and it's actually dependent to the first one (won't we get a compiler warning when we drop const qualifier during assignment?).
Quoted 4 lines
Reviewed-by Andy Shevchenko <[email protected]>Signed-off-by Tomas Winkler <[email protected]>---
Quoted 5 lines
Quoted 1 line
V2: drop
platform_devicepartBtw, when you prepare series, you may use -vX command line parameter, where X is a version number. The scripts will put v2 in each Subject line uniformly.
Right, just the second patch was a new one, so not sure I should mark it v2. Thanks
Tomas
Quoted 9 lines · Tomas
Quoted 8 lines
Quoted 1 line · Tomas Winkler
V2: drop
platform_devicepartBtw, when you prepare series, you may use -vX command line parameter, where X is a version number. The scripts will put v2 in each Subject line uniformly.
Right, just the second patch was a new one, so not sure I should mark it v2.
Yes, it evolved from the v1 of one patch. So, just mark both of them like
v2: per subsystem split from v1
or alike.
Signature · 2 lines
With Best Regards, Andy Shevchenko
Quoted 10 lines
Quoted 6 lines · Tomas
Quoted 6 lines
Quoted 1 line · Tomas Winkler
V2: drop
platform_devicepart
Quoted 8 lines
Quoted 4 lines
Quoted 3 lines
Btw, when you prepare series, you may use -vX command line parameter, where X is a version number. The scripts will put v2 in each Subject line uniformly.
Right, just the second patch was a new one, so not sure I should mark it v2.
Yes, it evolved from the v1 of one patch. So, just mark both of them like
v2: per subsystem split from v1
or alike.
Okay, we can look at that also this way.
Tomas