[PATCH] staging: greybus: gpio: add comment describing irq_lock mutex

UgwuRhema posted 1 patch 3 days, 6 hours ago
drivers/staging/greybus/gpio.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
[PATCH] staging: greybus: gpio: add comment describing irq_lock mutex
Posted by UgwuRhema 3 days, 6 hours ago
Add a description comment for irq_lock to clarify what the mutex
protects and satisfy checkpatch checks.

Signed-off-by: UgwuRhema <hikarialiyev@gmail.com>
---
 drivers/staging/greybus/gpio.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/staging/greybus/gpio.c b/drivers/staging/greybus/gpio.c
index 12185f7a9..7f19b3275 100644
--- a/drivers/staging/greybus/gpio.c
+++ b/drivers/staging/greybus/gpio.c
@@ -39,7 +39,7 @@ struct gb_gpio_controller {
 
 	struct gpio_chip	chip;
 	struct irq_chip		irqc;
-	struct mutex		irq_lock;
+	struct mutex		irq_lock; /* protects IRQ configuration and hardware state */
 };
 
 static struct gpio_chip *irq_data_to_gpio_chip(struct irq_data *d)
-- 
2.55.0
Re: [PATCH] staging: greybus: gpio: add comment describing irq_lock mutex
Posted by Dan Carpenter 3 days, 5 hours ago
On Mon, Sep 21, 2026 at 12:28:43PM +0000, UgwuRhema wrote:
> Add a description comment for irq_lock to clarify what the mutex
> protects and satisfy checkpatch checks.
> 
> Signed-off-by: UgwuRhema <hikarialiyev@gmail.com>
> ---
>  drivers/staging/greybus/gpio.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/staging/greybus/gpio.c b/drivers/staging/greybus/gpio.c
> index 12185f7a9..7f19b3275 100644
> --- a/drivers/staging/greybus/gpio.c
> +++ b/drivers/staging/greybus/gpio.c
> @@ -39,7 +39,7 @@ struct gb_gpio_controller {
>  
>  	struct gpio_chip	chip;
>  	struct irq_chip		irqc;
> -	struct mutex		irq_lock;
> +	struct mutex		irq_lock; /* protects IRQ configuration and hardware state */

No, I wouldn't say this is accurate at all.

regards,
dan carpenter

>  };
>