checkpatch complains about:
CHECK: struct mutex definition without comment
Add short comments describing what each mutex protects. The channel lock protects the channel state and lights_lock protects the lights array.
No functional change, just quiets checkpatch.
Signed-off-by: Vaibhav contectforbusiness@proton.me --- drivers/staging/greybus/light.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/staging/greybus/light.c b/drivers/staging/greybus/light.c index cab02b5da..a036fa2a0 100644 --- a/drivers/staging/greybus/light.c +++ b/drivers/staging/greybus/light.c @@ -37,7 +37,7 @@ struct gb_channel { bool releasing; bool strobe_state; bool active; - struct mutex lock; + struct mutex lock; /* protects channel */ };
struct gb_light { @@ -59,7 +59,7 @@ struct gb_lights { struct gb_connection *connection; u8 lights_count; struct gb_light *lights; - struct mutex lights_lock; + struct mutex lights_lock; /* protects lights */ };
static void gb_lights_channel_free(struct gb_channel *channel);
On Fri, Sep 04, 2026 at 05:56:25AM +0000, contectforbusiness@proton.me wrote:
checkpatch complains about:
CHECK: struct mutex definition without comment
Add short comments describing what each mutex protects. The channel lock protects the channel state and lights_lock protects the lights array.
No functional change, just quiets checkpatch.
Signed-off-by: Vaibhav contectforbusiness@proton.me
drivers/staging/greybus/light.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
Hi,
This is the friendly patch-bot of Greg Kroah-Hartman. You have sent him a patch that has triggered this response. He used to manually respond to these common problems, but in order to save his sanity (he kept writing the same thing over and over, yet to different people), I was created. Hopefully you will not take offence and will fix the problem in your patch and resubmit it so that it can be accepted into the Linux kernel tree.
You are receiving this message because of the following common error(s) as indicated below:
- It looks like you did not use your "real" name for the patch on either the Signed-off-by: line, or the From: line (both of which have to match). Please read the kernel file, Documentation/process/submitting-patches.rst for how to do this correctly.
If you wish to discuss this problem further, or you have questions about how to resolve this issue, please feel free to respond to this email and Greg will reply once he has dug out from the pending patches received from other developers.
thanks,
greg k-h's patch email bot
checkpatch complains about:
CHECK: struct mutex definition without comment
Add short comments describing what each mutex protects. The channel lock protects the channel state and lights_lock protects the lights array.
No functional change, just quiets checkpatch.
Signed-off-by: Vaibhav Agarwal contectforbusiness@proton.me --- drivers/staging/greybus/light.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/staging/greybus/light.c b/drivers/staging/greybus/light.c index cab02b5da..a036fa2a0 100644 --- a/drivers/staging/greybus/light.c +++ b/drivers/staging/greybus/light.c @@ -37,7 +37,7 @@ struct gb_channel { bool releasing; bool strobe_state; bool active; - struct mutex lock; + struct mutex lock; /* protects channel */ };
struct gb_light { @@ -59,7 +59,7 @@ struct gb_lights { struct gb_connection *connection; u8 lights_count; struct gb_light *lights; - struct mutex lights_lock; + struct mutex lights_lock; /* protects lights */ };
static void gb_lights_channel_free(struct gb_channel *channel);
On Fri, Sep 04, 2026 at 05:56:25AM +0000, contectforbusiness@proton.me wrote:
checkpatch complains about:
CHECK: struct mutex definition without comment
Add short comments describing what each mutex protects.
Is this an AI patch? Why write a short description? That's the opposite of what I want. I want a complete analysis.
The channel lock protects the channel state and lights_lock protects the lights array.
No functional change, just quiets checkpatch.
Signed-off-by: Vaibhav contectforbusiness@proton.me
drivers/staging/greybus/light.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/staging/greybus/light.c b/drivers/staging/greybus/light.c index cab02b5da..a036fa2a0 100644 --- a/drivers/staging/greybus/light.c +++ b/drivers/staging/greybus/light.c @@ -37,7 +37,7 @@ struct gb_channel { bool releasing; bool strobe_state; bool active;
- struct mutex lock;
- struct mutex lock; /* protects channel */
This comment is useless and wrong.
I hate this checkpatch warning...
regards, dan carpenter