lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Date:	Fri, 27 Jul 2007 11:58:49 -0600
From:	Bjorn Helgaas <bjorn.helgaas@...com>
To:	Andrew Morton <akpm@...ux-foundation.org>
Cc:	Russell King <rmk@....linux.org.uk>, Adam Belay <ambx1@....rr.com>,
	Jeff Garzik <jeff@...zik.org>, Len Brown <lenb@...nel.org>,
	Matthew Garrett <mjg59@...f.ucam.org>,
	Sébastien Dugué <sebastien.dugue@...l.net>,
	Alan Cox <alan@...rguk.ukuu.org.uk>,
	linux-kernel <linux-kernel@...r.kernel.org>
Subject: [patch] x86, serial: always probe for legacy COM ports

Andrew, if you drop
    revert-x86-serial-convert-legacy-com-ports-to-platform-devices.patch
and apply this, we should have the previous behavior.  I think the
conversion to platform devices is still worthwhile.  Obviously, I intend
this as 2.6.23 material.


Always probe for serial ports at legacy addresses, even if we have PNPBIOS
or ACPI that should tell us about those ports.

We have no reports yet of defective firmware that completely omits ports.
However, Sébastien Dugué <sebastien.dugue@...l.net> reported that the
NEC Express5800/120Lh with Phoenix BIOS 6.0.5N52, released 7/12/2005,
reports COM2 first, then COM1 in the ACPI namespace.

8250_pnp currently registers devices in namespace order.  On this machine,
that makes ttyS0=COM2 and ttyS1=COM1, the reverse of what we want.

Signed-off-by: Bjorn Helgaas <bjorn.helgaas@...com>

Index: w/arch/i386/kernel/legacy_serial.c
===================================================================
--- w.orig/arch/i386/kernel/legacy_serial.c	2007-07-27 10:57:41.000000000 -0600
+++ w/arch/i386/kernel/legacy_serial.c	2007-07-27 10:58:03.000000000 -0600
@@ -11,7 +11,6 @@
  */
 #include <linux/module.h>
 #include <linux/init.h>
-#include <linux/pnp.h>
 #include <linux/serial_8250.h>
 
 /* Standard COM flags (except for COM4, because of the 8514 problem) */
@@ -48,15 +47,8 @@
 	},
 };
 
-static int force_legacy_probe;
-module_param_named(force, force_legacy_probe, bool, 0);
-MODULE_PARM_DESC(force, "Force legacy serial port probe");
-
 static int __init serial8250_x86_com_init(void)
 {
-	if (pnp_platform_devices && !force_legacy_probe)
-		return -ENODEV;
-
 	return platform_device_register(&x86_com_device);
 }
 
Index: w/Documentation/kernel-parameters.txt
===================================================================
--- w.orig/Documentation/kernel-parameters.txt	2007-07-27 10:58:12.000000000 -0600
+++ w/Documentation/kernel-parameters.txt	2007-07-27 10:58:19.000000000 -0600
@@ -859,11 +859,6 @@
 	lasi=		[HW,SCSI] PARISC LASI driver for the 53c700 chip
 			Format: addr:<io>,irq:<irq>
 
-	legacy_serial.force [HW,IA-32,X86-64]
-			Probe for COM ports at legacy addresses even
-			if PNPBIOS or ACPI should describe them.  This
-			is for working around firmware defects.
-
 	llsc*=		[IA64] See function print_params() in
 			arch/ia64/sn/kernel/llsc4.c.
 
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ