Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 4 Nov 1998 00:03:12 -0800 (PST)
From:      igusarov@crow.mephi.net.ru
To:        freebsd-gnats-submit@FreeBSD.ORG
Subject:   i386/8571: Bug in config utility in FreeBSD 2.2.6-RELEASE
Message-ID:  <199811040803.AAA13802@hub.freebsd.org>

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

>Number:         8571
>Category:       i386
>Synopsis:       Bug in config utility in FreeBSD 2.2.6-RELEASE
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    freebsd-bugs
>State:          open
>Quarter:
>Keywords:
>Date-Required:
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Wed Nov  4 00:10:01 PST 1998
>Last-Modified:
>Originator:     Igor Goussarov
>Organization:
Moscow Engineering and Physics Institute
>Release:        2.2.6
>Environment:
FreeBSD crow.mephi.net.ru 2.2.6-RELEASE FreeBSD 2.2.6-RELEASE
#0: Sat Apr 25 18:54:30 MSD 1998
root@crow.mephi.ru:/usr/src/sys/compile/CROW  i386
>Description:
CONFIG incorrectly processes explicitly supplied IO addresses for IDE
controller (wdc). When I try to set it's IO address for wdc controller
via "port" parametr even to it's standard value 0x0170, the kernel
compilation fails with error in ioconf.c


>How-To-Repeat:
Make a copy of standard config file:
cp /usr/src/sys/i386/conf/GENERIC /usr/src/sys/i386/conf/TMP

And edit the lines in /usr/src/sys/i386/conf/TMP so that the
definition of IDE controller looks like

controller wdc1 at isa? port 0x0170 bio irq 15 flags 0x80ff80ff vector wdintr
disk       wd2  at wdc1 drive 0

It'll produce the following lines in /usr/src/sys/compile/TMP/ioconf.c

struct isa_device isa_devtab_bio[] = {
/* id     driver    iobase    irq drq      maddr   msiz      intr unit   flags scsiid alive ri_flags reconfig enabled conflicts next */
{  6, &fdcdriver,   IO_FD1,  IRQ6,  2, C 0x00000,     0,   fdintr,   0, 0x0000,    0,    0,       0,       0,      1,        0,   0 },
{  7, &wdcdriver,   IO_WD1, IRQ14, -1, C 0x00000,     0,   wdintr,   0, 0x80FF80FF,     0,    0,       0,       0,      1,        0,   0 },
{  8, &wdcdriver,   0x0170, IRQ15, -1, C 0x00000,     0,   wdintr,   1, 0x80FF80FF,     0,    0,       0,       0,      1,        0,   0 },
0};

struct isa_device isa_biotab_wdc[] = {
/* id     driver    iobase    irq drq      maddr   msiz      intr unit   flags drive alive ri_flags reconfig enabled conflicts next */
{ -1, &wdcdriver,   IO_WD1, IRQ14, -1, C 0x00000,     0,   wdintr,   0, 0x0000,    0,    0,       0,       0,      1,        0,   0 },
{ -1, &wdcdriver,   IO_WD1, IRQ14, -1, C 0x00000,     0,   wdintr,   1, 0x0000,    1,    0,       0,       0,      1,        0,   0 },
{ -1, &wdcdriver,   (null), IRQ15, -1, C 0x00000,     0,   wdintr,   2, 0x0000,    0,    0,       0,       0,      1,        0,   0 },
0};

No doubt, the kernel with (null) instead of wdc1 IO base address can't
be compiled. Note that in isa_devtab_bio structure IO address stated
correctly.
>Fix:
This situation can be avoided only if I type

controller wdc1 at isa? port "0x0170" bio irq 15 flags 0x80ff80ff vector wdintr

then that port address appears in ioconf.c as it was given in config
file and such kernel compiles just fine. So as far as all the other
devices can be configured with IO address without any quotation marks
and this controller can not - thus I guess it's a kind of bug.

>Audit-Trail:
>Unformatted:

To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-bugs" in the body of the message



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