2002-11-15 13:00:07

by Osamu Tomita

[permalink] [raw]
Subject: PC-9800 patch for 2.5.47-ac4: not merged yet (14/15) serial

diff -urN linux/drivers/serial/8250_pnp.c linux98/drivers/serial/8250_pnp.c
--- linux/drivers/serial/8250_pnp.c Sat Oct 19 13:01:08 2002
+++ linux98/drivers/serial/8250_pnp.c Sat Oct 19 16:20:53 2002
@@ -193,6 +193,8 @@
{ "MVX00A1", 0 },
/* PC Rider K56 Phone System PnP */
{ "MVX00F2", 0 },
+ /* NEC 98NOTE SPEAKER PHONE FAX MODEM(33600bps) */
+ { "nEC8241", 0 },
/* Pace 56 Voice Internal Plug & Play Modem */
{ "PMC2430", 0 },
/* Generic */
@@ -376,7 +378,12 @@
((port->min == 0x2f8) ||
(port->min == 0x3f8) ||
(port->min == 0x2e8) ||
+#ifndef CONFIG_PC9800
(port->min == 0x3e8)))
+#else
+ (port->min == 0x3e8) ||
+ (port->min == 0x8b0)))
+#endif
return 0;
}

diff -urN linux/include/asm-i386/serial.h linux98/include/asm-i386/serial.h
--- linux/include/asm-i386/serial.h Wed Oct 16 12:27:56 2002
+++ linux98/include/asm-i386/serial.h Fri Oct 18 10:12:09 2002
@@ -50,12 +50,19 @@

#define C_P(card,port) (((card)<<6|(port)<<3) + 1)

+#ifndef CONFIG_PC9800
#define STD_SERIAL_PORT_DEFNS \
/* UART CLK PORT IRQ FLAGS */ \
{ 0, BASE_BAUD, 0x3F8, 4, STD_COM_FLAGS }, /* ttyS0 */ \
{ 0, BASE_BAUD, 0x2F8, 3, STD_COM_FLAGS }, /* ttyS1 */ \
{ 0, BASE_BAUD, 0x3E8, 4, STD_COM_FLAGS }, /* ttyS2 */ \
{ 0, BASE_BAUD, 0x2E8, 3, STD_COM4_FLAGS }, /* ttyS3 */
+#else
+#define STD_SERIAL_PORT_DEFNS \
+ /* UART CLK PORT IRQ FLAGS */ \
+ { 0, BASE_BAUD, 0x30, 4, STD_COM_FLAGS }, /* ttyS0 */ \
+ { 0, BASE_BAUD, 0x238, 5, STD_COM_FLAGS }, /* ttyS1 */
+#endif /* CONFIG_PC9800 */


#ifdef CONFIG_SERIAL_MANY_PORTS


Attachments:
serial.patch (1.59 kB)

2002-11-15 13:11:03

by Andrey Panin

[permalink] [raw]
Subject: Re: PC-9800 patch for 2.5.47-ac4: not merged yet (14/15) serial

On Птн, Ноя 15, 2002 at 10:06:46 +0900, Osamu Tomita wrote:
> This is for serial port and onboard modem support.

> @@ -376,7 +378,12 @@
> ((port->min == 0x2f8) ||
> (port->min == 0x3f8) ||
> (port->min == 0x2e8) ||
> +#ifndef CONFIG_PC9800
> (port->min == 0x3e8)))
> +#else
> + (port->min == 0x3e8) ||
> + (port->min == 0x8b0)))
> +#endif
> return 0;
> }

Why 0x8b0 should be added here ?
Is it one of default iobase value for C-bus PNP modems ?

--
Andrey Panin | Embedded systems software developer
[email protected] | PGP key: wwwkeys.eu.pgp.net


Attachments:
(No filename) (629.00 B)
(No filename) (232.00 B)
Download all attachments

2002-11-15 14:57:54

by Andrey Panin

[permalink] [raw]
Subject: Re: PC-9800 patch for 2.5.47-ac4: not merged yet (14/15) serial

On Птн, Ноя 15, 2002 at 10:35:18 +0900, Osamu Tomita wrote:
> Andrey Panin wrote:
> >
> > On ????????, ??????????15, 2002 at 10:06:46 +0900, Osamu Tomita wrote:
> > > This is for serial port and onboard modem support.
> >
> > > @@ -376,7 +378,12 @@
> > > ((port->min == 0x2f8) ||
> > > (port->min == 0x3f8) ||
> > > (port->min == 0x2e8) ||
> > > +#ifndef CONFIG_PC9800
> > > (port->min == 0x3e8)))
> > > +#else
> > > + (port->min == 0x3e8) ||
> > > + (port->min == 0x8b0)))
> > > +#endif
> > > return 0;
> > > }
> >
> > Why 0x8b0 should be added here ?
> > Is it one of default iobase value for C-bus PNP modems ?
> Yes. C-bus PNP modems use this default value. And old modem
> card is hard wired to this iobase.

Ok. But IMHO this way is better (check order doesn't matter here):

((port->min == 0x2f8) ||
(port->min == 0x3f8) ||
(port->min == 0x2e8) ||
(port->min == 0x3e8) ||
#ifdef CONFIG_PC9800
(port->min == 0x8b0) ||
#endif

(port->min == 0x3e8)))
return 0;
}

--
Andrey Panin | Embedded systems software developer
[email protected] | PGP key: wwwkeys.eu.pgp.net


Attachments:
(No filename) (1.37 kB)
(No filename) (232.00 B)
Download all attachments