Add blank lines between the structure definitions and the to_gbphy_dev() and to_gbphy_driver() macros to improve readability. This fixes the following checkpatch warning:
CHECK: Please use a blank line after function/struct/union/enum declarations
Signed-off-by: Okhuomon Ajayi okhuomonajayi54@gmail.com --- drivers/staging/greybus/gbphy.h | 2 ++ 1 file changed, 2 insertions(+)
diff --git a/drivers/staging/greybus/gbphy.h b/drivers/staging/greybus/gbphy.h index d4a225b76338..1de510499480 100644 --- a/drivers/staging/greybus/gbphy.h +++ b/drivers/staging/greybus/gbphy.h @@ -15,6 +15,7 @@ struct gbphy_device { struct list_head list; struct device dev; }; + #define to_gbphy_dev(d) container_of(d, struct gbphy_device, dev)
static inline void *gb_gbphy_get_data(struct gbphy_device *gdev) @@ -43,6 +44,7 @@ struct gbphy_driver {
struct device_driver driver; }; + #define to_gbphy_driver(d) container_of(d, struct gbphy_driver, driver)
int gb_gbphy_register_driver(struct gbphy_driver *driver,
On Thu, 15 Oct 2026, Okhuomon Ajayi wrote:
Add blank lines between the structure definitions and the to_gbphy_dev() and to_gbphy_driver() macros to improve readability. This fixes the following checkpatch warning:
Thanks for the patch. But I suspect that the lack of a newline was intentional, to show that the #define is closely associated with the previous structure declaration.
julia
CHECK: Please use a blank line after function/struct/union/enum declarations
Signed-off-by: Okhuomon Ajayi okhuomonajayi54@gmail.com
drivers/staging/greybus/gbphy.h | 2 ++ 1 file changed, 2 insertions(+)
diff --git a/drivers/staging/greybus/gbphy.h b/drivers/staging/greybus/gbphy.h index d4a225b76338..1de510499480 100644 --- a/drivers/staging/greybus/gbphy.h +++ b/drivers/staging/greybus/gbphy.h @@ -15,6 +15,7 @@ struct gbphy_device { struct list_head list; struct device dev; };
#define to_gbphy_dev(d) container_of(d, struct gbphy_device, dev)
static inline void *gb_gbphy_get_data(struct gbphy_device *gdev) @@ -43,6 +44,7 @@ struct gbphy_driver {
struct device_driver driver; };
#define to_gbphy_driver(d) container_of(d, struct gbphy_driver, driver)
int gb_gbphy_register_driver(struct gbphy_driver *driver,
2.43.0
On Thu, Oct 15, 2026 at 10:17:35PM -0400, Julia Lawall wrote:
On Thu, 15 Oct 2026, Okhuomon Ajayi wrote:
Add blank lines between the structure definitions and the to_gbphy_dev() and to_gbphy_driver() macros to improve readability. This fixes the following checkpatch warning:
Thanks for the patch. But I suspect that the lack of a newline was intentional, to show that the #define is closely associated with the previous structure declaration.
That is correct.
thanks,
greg k-h