Re: [PATCH v2] s390/sclp_vt220: Fix console name to match device

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 





On 27.04.21 21:40, Valentin Vidic wrote:
Console name reported in /proc/consoles:

   ttyS1                -W- (EC p  )    4:65

does not match the char device name:

   crw--w----    1 root     root        4,  65 May 17 12:18 /dev/ttysclp0

so debian-installer inside a QEMU s390x instance gets confused and fails
to start with the following error:

   steal-ctty: No such file or directory

Signed-off-by: Valentin Vidic <vvidic@xxxxxxxxxxxxxxxxxxxxxx>

Ok, I will apply this internally for a while to give it some test coverage.
I also think that I found a potential statement for the documentation issue.

The tty will simply continue to work (as tty and console are not connected),
but for the console on LPAR you usually do things like
"console=ttyS0 console=ttyS1" to get console output on both (sclp line mode and
sclp full screen AKA ascii console).

When we now change the documentation to
"console=ttyS0 console=ttyS1 console=ttysclp0" the kernel will ignore the missing
console.


---
  v2: also update preferred console for VT220 case

  arch/s390/kernel/setup.c       | 2 +-
  drivers/s390/char/sclp_vt220.c | 4 ++--
  2 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/arch/s390/kernel/setup.c b/arch/s390/kernel/setup.c
index 72134f9f6ff5..3ec6ca9c26c0 100644
--- a/arch/s390/kernel/setup.c
+++ b/arch/s390/kernel/setup.c
@@ -165,7 +165,7 @@ static void __init set_preferred_console(void)
  	else if (CONSOLE_IS_3270)
  		add_preferred_console("tty3270", 0, NULL);
  	else if (CONSOLE_IS_VT220)
-		add_preferred_console("ttyS", 1, NULL);
+		add_preferred_console("ttysclp", 0, NULL);
  	else if (CONSOLE_IS_HVC)
  		add_preferred_console("hvc", 0, NULL);
  }
diff --git a/drivers/s390/char/sclp_vt220.c b/drivers/s390/char/sclp_vt220.c
index 047f812d1a1c..71ed1bf15598 100644
--- a/drivers/s390/char/sclp_vt220.c
+++ b/drivers/s390/char/sclp_vt220.c
@@ -35,8 +35,8 @@
  #define SCLP_VT220_MINOR		65
  #define SCLP_VT220_DRIVER_NAME		"sclp_vt220"
  #define SCLP_VT220_DEVICE_NAME		"ttysclp"
-#define SCLP_VT220_CONSOLE_NAME		"ttyS"
-#define SCLP_VT220_CONSOLE_INDEX	1	/* console=ttyS1 */
+#define SCLP_VT220_CONSOLE_NAME		"ttysclp"
+#define SCLP_VT220_CONSOLE_INDEX	0	/* console=ttysclp0 */
/* Representation of a single write request */
  struct sclp_vt220_request {




[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Kernel Development]     [Kernel Newbies]     [IDE]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite Info]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux ATA RAID]     [Samba]     [Linux Media]     [Device Mapper]

  Powered by Linux