Add comments describing what the lock fields in struct gb_tty protect, and fix the indentation of the wait_for_completion_timeout() call.
Signed-off-by: AkaLuiz luizcarlosmdea@gmail.com --- drivers/staging/greybus/uart.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/drivers/staging/greybus/uart.c b/drivers/staging/greybus/uart.c index 7d060b4cd33d..85586e9a4341 100644 --- a/drivers/staging/greybus/uart.c +++ b/drivers/staging/greybus/uart.c @@ -50,12 +50,12 @@ struct gb_tty { unsigned int minor; unsigned char clocal; bool disconnected; - spinlock_t read_lock; - spinlock_t write_lock; + spinlock_t read_lock; /* protects iocount and oldcount for TIOCMIWAIT */ + spinlock_t write_lock; /* protects write_fifo and credits */ struct async_icount iocount; struct async_icount oldcount; wait_queue_head_t wioctl; - struct mutex mutex; + struct mutex mutex; /* protects disconnected during lookup and removal */ u8 ctrlin; /* input control lines */ u8 ctrlout; /* output control lines */ struct gb_uart_set_line_coding_request line_coding; @@ -318,7 +318,7 @@ static int gb_uart_wait_for_all_credits(struct gb_tty *gb_tty) return 0;
ret = wait_for_completion_timeout(&gb_tty->credits_complete, - msecs_to_jiffies(GB_UART_CREDIT_WAIT_TIMEOUT_MSEC)); + msecs_to_jiffies(GB_UART_CREDIT_WAIT_TIMEOUT_MSEC)); if (!ret) { dev_err(&gb_tty->gbphy_dev->dev, "time out waiting for credits\n");
On Tue, May 19, 2026 at 11:41:28PM -0300, AkaLuiz wrote:
Add comments describing what the lock fields in struct gb_tty protect, and fix the indentation of the wait_for_completion_timeout() call.
Signed-off-by: AkaLuiz luizcarlosmdea@gmail.com
drivers/staging/greybus/uart.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/drivers/staging/greybus/uart.c b/drivers/staging/greybus/uart.c index 7d060b4cd33d..85586e9a4341 100644 --- a/drivers/staging/greybus/uart.c +++ b/drivers/staging/greybus/uart.c @@ -50,12 +50,12 @@ struct gb_tty { unsigned int minor; unsigned char clocal; bool disconnected;
- spinlock_t read_lock;
- spinlock_t write_lock;
- spinlock_t read_lock; /* protects iocount and oldcount for TIOCMIWAIT */
- spinlock_t write_lock; /* protects write_fifo and credits */ struct async_icount iocount; struct async_icount oldcount; wait_queue_head_t wioctl;
- struct mutex mutex;
- struct mutex mutex; /* protects disconnected during lookup and removal */ u8 ctrlin; /* input control lines */ u8 ctrlout; /* output control lines */ struct gb_uart_set_line_coding_request line_coding;
@@ -318,7 +318,7 @@ static int gb_uart_wait_for_all_credits(struct gb_tty *gb_tty) return 0; ret = wait_for_completion_timeout(&gb_tty->credits_complete,
msecs_to_jiffies(GB_UART_CREDIT_WAIT_TIMEOUT_MSEC));
if (!ret) { dev_err(&gb_tty->gbphy_dev->dev, "time out waiting for credits\n");msecs_to_jiffies(GB_UART_CREDIT_WAIT_TIMEOUT_MSEC));-- 2.54.0
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
Add comments describing what the lock fields in struct gb_tty protect, and fix the indentation of the wait_for_completion_timeout() call.
Signed-off-by: Luiz Carlos luizcarlosmdea@gmail.com --- drivers/staging/greybus/uart.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/drivers/staging/greybus/uart.c b/drivers/staging/greybus/uart.c index 7d060b4cd33d..85586e9a4341 100644 --- a/drivers/staging/greybus/uart.c +++ b/drivers/staging/greybus/uart.c @@ -50,12 +50,12 @@ struct gb_tty { unsigned int minor; unsigned char clocal; bool disconnected; - spinlock_t read_lock; - spinlock_t write_lock; + spinlock_t read_lock; /* protects iocount and oldcount for TIOCMIWAIT */ + spinlock_t write_lock; /* protects write_fifo and credits */ struct async_icount iocount; struct async_icount oldcount; wait_queue_head_t wioctl; - struct mutex mutex; + struct mutex mutex; /* protects disconnected during lookup and removal */ u8 ctrlin; /* input control lines */ u8 ctrlout; /* output control lines */ struct gb_uart_set_line_coding_request line_coding; @@ -318,7 +318,7 @@ static int gb_uart_wait_for_all_credits(struct gb_tty *gb_tty) return 0;
ret = wait_for_completion_timeout(&gb_tty->credits_complete, - msecs_to_jiffies(GB_UART_CREDIT_WAIT_TIMEOUT_MSEC)); + msecs_to_jiffies(GB_UART_CREDIT_WAIT_TIMEOUT_MSEC)); if (!ret) { dev_err(&gb_tty->gbphy_dev->dev, "time out waiting for credits\n");
On Thu, May 21, 2026 at 07:12:45AM -0300, Luiz Carlos wrote:
Add comments describing what the lock fields in struct gb_tty protect, and fix the indentation of the wait_for_completion_timeout() call.
Signed-off-by: Luiz Carlos luizcarlosmdea@gmail.com
drivers/staging/greybus/uart.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/drivers/staging/greybus/uart.c b/drivers/staging/greybus/uart.c index 7d060b4cd33d..85586e9a4341 100644 --- a/drivers/staging/greybus/uart.c +++ b/drivers/staging/greybus/uart.c @@ -50,12 +50,12 @@ struct gb_tty { unsigned int minor; unsigned char clocal; bool disconnected;
- spinlock_t read_lock;
- spinlock_t write_lock;
- spinlock_t read_lock; /* protects iocount and oldcount for TIOCMIWAIT */
- spinlock_t write_lock; /* protects write_fifo and credits */ struct async_icount iocount; struct async_icount oldcount; wait_queue_head_t wioctl;
- struct mutex mutex;
- struct mutex mutex; /* protects disconnected during lookup and removal */ u8 ctrlin; /* input control lines */ u8 ctrlout; /* output control lines */ struct gb_uart_set_line_coding_request line_coding;
@@ -318,7 +318,7 @@ static int gb_uart_wait_for_all_credits(struct gb_tty *gb_tty) return 0; ret = wait_for_completion_timeout(&gb_tty->credits_complete,
msecs_to_jiffies(GB_UART_CREDIT_WAIT_TIMEOUT_MSEC));
if (!ret) { dev_err(&gb_tty->gbphy_dev->dev, "time out waiting for credits\n");msecs_to_jiffies(GB_UART_CREDIT_WAIT_TIMEOUT_MSEC));-- 2.54.0
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:
- Your patch did many different things all at once, making it difficult to review. All Linux kernel patches need to only do one thing at a time. If you need to do multiple things (such as clean up all coding style issues in a file/driver), do it in a sequence of patches, each one doing only one thing. This will make it easier to review the patches to ensure that they are correct, and to help alleviate any merge issues that larger patches can cause.
- This looks like a new version of a previously submitted patch, but you did not list below the --- line any changes from the previous version. Please read the section entitled "The canonical patch format" in the kernel file, Documentation/process/submitting-patches.rst for what needs to be done here to properly describe this.
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