linux-serial.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] serial: uartlite: Use dynamic allocation for major number
@ 2023-11-09 12:36 Manikanta Guntupalli
  2023-11-09 13:20 ` Greg KH
  0 siblings, 1 reply; 4+ messages in thread
From: Manikanta Guntupalli @ 2023-11-09 12:36 UTC (permalink / raw)
  To: git, michal.simek, jacmet, gregkh, jirislaby, linux-serial,
	linux-kernel
  Cc: radhey.shyam.pandey, srinivas.goud, shubhrajyoti.datta,
	manion05gk, Manikanta Guntupalli

Device number 204 has a range of minors on major number.
uart_register_driver is failing due to lack of minor numbers
when more number of uart ports used. So, use dynamic allocation
for major number to avoid minor number limitation on 204 major
number.

https://docs.kernel.org/arch/arm/sa1100/serial_uart.html

Signed-off-by: Manikanta Guntupalli <manikanta.guntupalli@amd.com>
---
 drivers/tty/serial/uartlite.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/tty/serial/uartlite.c b/drivers/tty/serial/uartlite.c
index 404c14acafa5..c80ed0373b44 100644
--- a/drivers/tty/serial/uartlite.c
+++ b/drivers/tty/serial/uartlite.c
@@ -24,8 +24,8 @@
 #include <linux/pm_runtime.h>
 
 #define ULITE_NAME		"ttyUL"
-#define ULITE_MAJOR		204
-#define ULITE_MINOR		187
+#define ULITE_MAJOR		0	/* use dynamic node allocation */
+#define ULITE_MINOR		0
 #define ULITE_NR_UARTS		CONFIG_SERIAL_UARTLITE_NR_UARTS
 
 /* ---------------------------------------------------------------------
-- 
2.25.1


^ permalink raw reply related	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2023-11-10 17:56 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-11-09 12:36 [PATCH] serial: uartlite: Use dynamic allocation for major number Manikanta Guntupalli
2023-11-09 13:20 ` Greg KH
2023-11-10  9:28   ` Guntupalli, Manikanta
2023-11-10 10:55     ` Greg KH

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).