Subject: Re: A newer pms.c
To: Shoji Yuen <shoji@sbleo.cs.sunysb.edu>
From: Duncan McEwan <duncan@Comp.VUW.AC.NZ>
List: current-users
Date: 06/16/1994 13:28:41
> I made some modifications to pms.c in the distribution, that is ftp'ed from
> ftp.iastate.edu on June 1, 1994. It is working well so far on my Gateway
> P5_60 with a PS/2 mouse port ...
>
> I put the file:
> nuis.nuie.nagoya-u.ac.jp[133.6.109.1]:~ftp/NetBSD/misc/pms_new.c
>
> If you are interested in it, please try it.
I just tried, and it works fine on one machine I have access to that has a ps/2
mouse.
But on another machine, booting a kernel with this driver in it wedges the
keyboard in the same way that my modified ps/2 mouse driver initially did (it
was based on earlier code by Shoji that I modified to work with netbsd's new
config and interupt handling schemes -- I sent a copy of it to Charles, but it
never made it into the source tree).
The enclosed patch to the new driver fixes this problem for me...
And to anyone in the NetBSD core... is there any chance that Shoji's driver
could actually make it into the source tree in time for the next distribution?
It really does work *lots* better than the one that's there now...!
Duncan
*** pms.c.orig Thu Jun 16 13:19:43 1994
--- pms.c Thu Jun 16 13:24:28 1994
***************
*** 112,119 ****
{
u_char c;
while (c = inb(ioport+STATUS) & 0x03)
! if ((c & PMS_OBUF_FULL) == PMS_OBUF_FULL)
(void) inb(ioport+DATA);
}
static inline void pms_dev_cmd(int ioport, u_char value)
--- 112,123 ----
{
u_char c;
while (c = inb(ioport+STATUS) & 0x03)
! if ((c & PMS_OBUF_FULL) == PMS_OBUF_FULL) {
! /* XXX - delay is needed to prevent some keyboards from
! wedging when the system boots */
! delay(6);
(void) inb(ioport+DATA);
+ }
}
static inline void pms_dev_cmd(int ioport, u_char value)
------------------------------------------------------------------------------