From 73e0f79f04a4be4094e8da8b5b5c2485d10c242e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?S=C3=B8ren=20Schmidt?= Date: Fri, 15 Nov 1996 08:45:24 +0000 Subject: [PATCH] Only poll the keyboard if the data left in the buffer is from the kbd, not if its from the psm device. --- sys/dev/syscons/syscons.c | 10 +++++----- sys/i386/isa/syscons.c | 10 +++++----- sys/isa/syscons.c | 10 +++++----- 3 files changed, 15 insertions(+), 15 deletions(-) diff --git a/sys/dev/syscons/syscons.c b/sys/dev/syscons/syscons.c index 5b806e61e74..578f6f5c4d7 100644 --- a/sys/dev/syscons/syscons.c +++ b/sys/dev/syscons/syscons.c @@ -25,7 +25,7 @@ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. * - * $Id: syscons.c,v 1.182.2.3 1996/11/12 09:08:53 phk Exp $ + * $Id: syscons.c,v 1.187 1996/11/14 22:19:14 sos Exp $ */ #include "sc.h" @@ -1459,12 +1459,12 @@ scrn_timer() /* * With release 2.1 of the Xaccel server, the keyboard is left - * hanging pretty often. Apparently the interrupt from the + * hanging pretty often. Apparently an interrupt from the * keyboard is lost, and I don't know why (yet). - * This Ugly hack calls scintr if input is ready and - * conveniently hides the problem. XXX + * This ugly hack calls scintr if input is ready for the keyboard + * and conveniently hides the problem. XXX */ - if (inb(sc_port + KBD_STATUS_PORT) & KBDS_KBD_BUFFER_FULL) + if ((inb(sc_port+KBD_STATUS_PORT)&KBDS_BUFFER_FULL) == KBDS_KBD_BUFFER_FULL) scintr(0); /* should we just return ? */ diff --git a/sys/i386/isa/syscons.c b/sys/i386/isa/syscons.c index 5b806e61e74..578f6f5c4d7 100644 --- a/sys/i386/isa/syscons.c +++ b/sys/i386/isa/syscons.c @@ -25,7 +25,7 @@ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. * - * $Id: syscons.c,v 1.182.2.3 1996/11/12 09:08:53 phk Exp $ + * $Id: syscons.c,v 1.187 1996/11/14 22:19:14 sos Exp $ */ #include "sc.h" @@ -1459,12 +1459,12 @@ scrn_timer() /* * With release 2.1 of the Xaccel server, the keyboard is left - * hanging pretty often. Apparently the interrupt from the + * hanging pretty often. Apparently an interrupt from the * keyboard is lost, and I don't know why (yet). - * This Ugly hack calls scintr if input is ready and - * conveniently hides the problem. XXX + * This ugly hack calls scintr if input is ready for the keyboard + * and conveniently hides the problem. XXX */ - if (inb(sc_port + KBD_STATUS_PORT) & KBDS_KBD_BUFFER_FULL) + if ((inb(sc_port+KBD_STATUS_PORT)&KBDS_BUFFER_FULL) == KBDS_KBD_BUFFER_FULL) scintr(0); /* should we just return ? */ diff --git a/sys/isa/syscons.c b/sys/isa/syscons.c index 5b806e61e74..578f6f5c4d7 100644 --- a/sys/isa/syscons.c +++ b/sys/isa/syscons.c @@ -25,7 +25,7 @@ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. * - * $Id: syscons.c,v 1.182.2.3 1996/11/12 09:08:53 phk Exp $ + * $Id: syscons.c,v 1.187 1996/11/14 22:19:14 sos Exp $ */ #include "sc.h" @@ -1459,12 +1459,12 @@ scrn_timer() /* * With release 2.1 of the Xaccel server, the keyboard is left - * hanging pretty often. Apparently the interrupt from the + * hanging pretty often. Apparently an interrupt from the * keyboard is lost, and I don't know why (yet). - * This Ugly hack calls scintr if input is ready and - * conveniently hides the problem. XXX + * This ugly hack calls scintr if input is ready for the keyboard + * and conveniently hides the problem. XXX */ - if (inb(sc_port + KBD_STATUS_PORT) & KBDS_KBD_BUFFER_FULL) + if ((inb(sc_port+KBD_STATUS_PORT)&KBDS_BUFFER_FULL) == KBDS_KBD_BUFFER_FULL) scintr(0); /* should we just return ? */