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-prev] [day] [month] [year] [list]
Date:	Sun, 4 Mar 2007 22:47:50 +0100
From:	Folkert van Heusden <folkert@...heusden.com>
To:	Alan Cox <alan@...rguk.ukuu.org.uk>
Cc:	linux-hams@...r.kernel.org, sailer@....ee.ethz.ch,
	henk.termeer@...il.com, udovdh@...all.nl,
	linux-kernel@...r.kernel.org
Subject: Re: [PATCH] baycom_ser_fdx: also allow i/o ports >= 0x1000 and
	enhanced failure logging

> > The baycom_ser_fdx driver did not allow i/o ports >= 0x1000. Now that
> > there are pci cards (with rs232 ports) which use for example 0xb800 this
> > limit should not exists.
> The IRQ test is also wrong for PCI systems the moment an APIC is present.
> NR_IRQS is the define to use.

Ok, changed:


Signed-off-by: Folkert van Heusden <folkert@...heusden.com>

--- ./drivers/net/hamradio/baycom_ser_fdx.c.org 2007-03-04 22:24:47.000000000 +0100
+++ ./drivers/net/hamradio/baycom_ser_fdx.c     2007-03-04 22:42:51.000000000 +0100
@@ -413,11 +413,15 @@

        if (!dev || !bc)
                return -ENXIO;
-       if (!dev->base_addr || dev->base_addr > 0x1000-SER12_EXTENT ||
-           dev->irq < 2 || dev->irq > 15)
+       if (!dev->base_addr || dev->base_addr > 0xffff-SER12_EXTENT ||
+           dev->irq < 2 || dev->irq > NR_IRQS) {
+               printk(KERN_INFO "baycom_ser_fdx: invalid portnumber (max %u) or irq (2 <= irq <= %d)\n", 0xffff-SER12_EXTENT, NR_IRQS);
                return -ENXIO;
-       if (bc->baud < 300 || bc->baud > 4800)
+       }
+       if (bc->baud < 300 || bc->baud > 4800) {
+               printk(KERN_INFO "baycom_ser_fdx: invalid baudrate (300...4800)\n");
                return -EINVAL;
+       }
        if (!request_region(dev->base_addr, SER12_EXTENT, "baycom_ser_fdx")) {
                printk(KERN_WARNING "BAYCOM_SER_FSX: I/O port 0x%04lx busy \n",
                       dev->base_addr);


Folkert van Heusden

-- 
MultiTail är en flexibel redskap för att fälja logfilar, utför av
commandoer, filtrera, ge färg, sammanfoga, o.s.v. följa.
http://www.vanheusden.com/multitail/
----------------------------------------------------------------------
Phone: +31-6-41278122, PGP-key: 1F28D8AE, www.vanheusden.com
-
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