From owner-freebsd-mobile Tue May 4 12: 1: 9 1999 Delivered-To: freebsd-mobile@freebsd.org Received: from mail.netacc.net (mail.netacc.net [206.28.142.35]) by hub.freebsd.org (Postfix) with SMTP id 6444E152CB for ; Tue, 4 May 1999 12:01:03 -0700 (PDT) (envelope-from kenney@netacc.net) Received: (qmail 508 invoked from network); 4 May 1999 15:01:02 -0400 Received: from dns2.netacc.net (kenney@206.28.142.3) by mail.netacc.net with SMTP; 4 May 1999 15:01:02 -0400 Received: from localhost (kenney@localhost) by dns2.netacc.net (8.8.8/8.8.8) with ESMTP id OAA08739; Tue, 4 May 1999 14:59:07 GMT (envelope-from kenney@netacc.net) X-Authentication-Warning: dns2.netacc.net: kenney owned process doing -bs Date: Tue, 4 May 1999 14:59:07 +0000 (GMT) From: Jeffrey Kenney Reply-To: kenney@netacc.net To: Mitsuru IWASAKI Cc: freebsd-mobile@freebsd.org Subject: Re: PAO3 is the cause of my modem problems (it works with PAO-971211+2.2.5R and Slackware Linux v3.6) In-Reply-To: <199905040833.RAA11421@tasogare.imasy.or.jp> Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: owner-freebsd-mobile@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.org Thanks so much,that fixed the problem on the first try. On Tue, 4 May 1999, Mitsuru IWASAKI wrote: > Hello. My name is Iwasaki. > I noticed this problem on PAO3 few days before, and trying to fix it now. > It seems that the bugs in sioinit() and sioprobe() of > sys/i386/isa/sio.c (PAO3). > > sioinit(): In /etc/pccard.conf of PAO3, flags 0x40000 is specified by > digital communication cards entry. For normal modems this > flags is not given. However sioinit() always overrides > this flags to COM_C_NOPROBE (0x40000). (If COM_C_NOPROBE > bit is enabled, initialization procedue will be skipped > in sioprobe().) > > sioprobe(): Code for device with COM_C_NOPROBE flags is duplicated. > I suspect that first one must be deleted because the > initialization procedue starts after this block. > > The following patch works well for me. So far so good. > But I'm not sure this is correct solution because I don't have > any digital communication cards which specified 0x40000 flags in > /etc/pccard.conf, and don't understand clearly why COM_C_NOPROBE > bit can be set in sioinit(). > > Can anyone test this patch or review it? > > --- /usr/PAO3/src/sys/i386/isa/sio.c- Mon May 3 15:20:37 1999 > +++ /usr/PAO3/src/sys/i386/isa/sio.c Mon May 3 22:41:38 1999 > @@ -489,8 +489,16 @@ > if (com_addr(unit)) > return(EBUSY); > > +#if 0 > + /* > + * XXX This line overrides device flags specified > + * in /etc/pccard.conf on COM_C_NOPROBE (0x40000). > + * iwasaki@jp.FreeBSD.org > + */ > + > /* It's already probed as serial by Upper */ > devi->isahd.id_flags |= COM_C_NOPROBE; > +#endif > > /* > * Probe the device. If a value is returned, the > @@ -652,37 +660,6 @@ > > bzero(failures, sizeof failures); > iobase = dev->id_iobase; > - > - /* > - * It's a definitly Serial PCMCIA(16550A), but still be required > - * for IIR_TXRDY implementation ( Palido 321s, DC-1S... ) > - */ > - if ( COM_NOPROBE(dev) ) { > - /* Reading IIR register twice */ > - for ( fn = 0; fn < 2; fn ++ ) { > - DELAY(10000); > - failures[6] = inb(iobase + com_iir); > - } > - /* Check IIR_TXRDY clear ? */ > - result = IO_COMSIZE; > - if ( failures[6] & IIR_TXRDY ) { > - /* Nop, Double check with clearing IER */ > - outb(iobase + com_ier, 0); > - if ( inb(iobase + com_iir) & IIR_NOPEND ) { > - /* Ok. we're familia this gang */ > - dev->id_flags |= COM_C_IIR_TXRDYBUG; /* Set IIR_TXRDYBUG */ > - } else { > - /* Unknow, Just omit this chip.. XXX*/ > - result = 0; > - } > - } else { > - /* OK. this is well-known guys */ > - dev->id_flags &= ~COM_C_IIR_TXRDYBUG; /*Clear IIR_TXRDYBUG*/ > - } > - outb(iobase + com_cfcr, CFCR_8BITS); > - enable_intr(); > - return( result ); > - } > > /* > * We don't want to get actual interrupts, just masked ones. > > > > > To Unsubscribe: send mail to majordomo@FreeBSD.org > with "unsubscribe freebsd-mobile" in the body of the message > To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-mobile" in the body of the message