Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 27 May 1996 22:06:04 +0100 (BST)
From:      Gary Palmer <gpalmer@FreeBSD.ORG>
To:        FreeBSD-gnats-submit@FreeBSD.ORG
Subject:   kern/1265: warnings in pcv
Message-ID:  <199605272106.WAA02868@palmer.demon.co.uk>
Resent-Message-ID: <199605272110.OAA12614@freefall.freebsd.org>

next in thread | raw e-mail | index | archive | help

>Number:         1265
>Category:       kern
>Synopsis:       warnings in pcv
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    freebsd-bugs
>State:          open
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Mon May 27 14:10:01 PDT 1996
>Last-Modified:
>Originator:     Gary Palmer
>Organization:
None
>Release:        FreeBSD 2.1-STABLE i386
>Environment:

FreeBSD's current PCVT version

>Description:

If you compile pcvt with -Wunused, you get plenty of warings like:

../../i386/isa/pcvt/pcvt_drv.c:908: warning: unused variable `x'
../../i386/isa/pcvt/pcvt_drv.c:908: warning: unused variable `x'
../../i386/isa/pcvt/pcvt_drv.c:908: warning: unused variable `x'
../../i386/isa/pcvt/pcvt_drv.c:908: warning: unused variable `x'
../../i386/isa/pcvt/pcvt_drv.c:908: warning: unused variable `x'
../../i386/isa/pcvt/pcvt_drv.c:908: warning: unused variable `x'

This is because pcvt uses an inb() from the keyboard controller in an
attempt to get a delay which is slightly less processor dependant
than DELAY().

Bruce commented:

pcvt should just use DELAY().  DELAY() isn't perfect, but neither is pcvt's
inb() method.

>How-To-Repeat:

Add -Wunused to the kernel Makefile.

>Fix:
	
Move from the inb() to DELAY().

>Audit-Trail:
>Unformatted:



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?199605272106.WAA02868>