dm: Use parenthesis for the device_get_ops macro argument
PATCH 1/1 dm: Use parenthesis for the device_get_ops macro argument
Use parenthesis for the device_get_ops macro argument. This prevents errors when using an expression for the parameter.
Signed-off-by Sughosh Ganu <[email protected]>
--- include/dm/device.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
include/dm/device.h +1 -1
@@ -212,7 +212,7 @@ struct udevice_rt {#define DM_MAX_SEQ_STR 3/* Returns the operations for a device */ -#define device_get_ops (dev) (dev->driver->ops) +#define device_get_ops (dev) ((dev)->driver->ops)#if CONFIG_IS_ENABLED (OF_PLATDATA_RT )u32 dev_get_flags (const struct udevice *dev);
Signature · 1 line
2.17.1
Quoted 8 lines · Sughosh Ganu
Use parenthesis for the
device_get_opsmacro argument. This prevents errors when using an expression for the parameter.Signed-off-by Sughosh Ganu <[email protected]>--- include/dm/device.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
Reviewed-by Simon Glass <[email protected]>
Simon Glass
Reviewed-byQuoted 8 lines · Sughosh Ganu
Use parenthesis for the
device_get_opsmacro argument. This prevents errors when using an expression for the parameter.Signed-off-by Sughosh Ganu <[email protected]>--- include/dm/device.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
Reviewed-by Simon Glass <[email protected]>
Applied to u-boot-dm, thanks!