[PATCH v6 1/3] ttynull: Always initialize console index to -1

adamsimonelli@gmail.com posted 3 patches 11 months, 1 week ago
There is a newer version of this series
[PATCH v6 1/3] ttynull: Always initialize console index to -1
Posted by adamsimonelli@gmail.com 11 months, 1 week ago
From: Adam Simonelli <adamsimonelli@gmail.com>

Signed-off-by: Adam Simonelli <adamsimonelli@gmail.com>
---
 drivers/tty/ttynull.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/tty/ttynull.c b/drivers/tty/ttynull.c
index 6b2f7208b564..d8b51edde628 100644
--- a/drivers/tty/ttynull.c
+++ b/drivers/tty/ttynull.c
@@ -57,6 +57,7 @@ static struct tty_driver *ttynull_device(struct console *c, int *index)
 static struct console ttynull_console = {
 	.name = "ttynull",
 	.device = ttynull_device,
+	.index = -1,
 };
 
 static int __init ttynull_init(void)
-- 
2.45.2
Re: [PATCH v6 1/3] ttynull: Always initialize console index to -1
Posted by Andy Shevchenko 11 months, 1 week ago
On Tue, Mar 4, 2025 at 5:55 AM <adamsimonelli@gmail.com> wrote:
>
> From: Adam Simonelli <adamsimonelli@gmail.com>

In general we do not accept empty commit messages (yes, it was done in
the past and in some exceptional cases, but should be taken as a very
bad practice).

Should it also have Suggested-by: ?

> Signed-off-by: Adam Simonelli <adamsimonelli@gmail.com>

-- 
With Best Regards,
Andy Shevchenko
Re: [PATCH v6 1/3] ttynull: Always initialize console index to -1
Posted by John Ogness 11 months, 1 week ago
On 2025-03-04, Andy Shevchenko <andy.shevchenko@gmail.com> wrote:
> In general we do not accept empty commit messages (yes, it was done in
> the past and in some exceptional cases, but should be taken as a very
> bad practice).

It would also be nice if the commit message explained _why_ the change
is done and how it affects the driver behavior as opposed to previously.

John Ogness