Date: Wed, 3 Sep 1997 23:38:13 +0200 (CEST) From: Mikael Karpberg <karpen@ocean.campus.luth.se> To: luigi@labinfo.iet.unipi.it (Luigi Rizzo) Cc: hackers@FreeBSD.ORG Subject: Re: PnP support in userconfig Message-ID: <199709032138.XAA18864@ocean.campus.luth.se> In-Reply-To: <199709030949.LAA07543@labinfo.iet.unipi.it> from Luigi Rizzo at "Sep 3, 97 11:49:52 am"
next in thread | previous in thread | raw e-mail | index | archive | help
According to Luigi Rizzo:
[...]
> Before making the code available, I need suggestions on the following
> issues.
>
> A PnP card can be specified using a unique integer (CSN) starting from
> 1 and assigned by the operating system at boot time, or with a 32-bit
> number which is the "vendor_id" for the board. Each card has a number
> of "logical devices" internally, numbered starting from 0 (the number
> is called LDN).
>
> Each card can accept up to 8 port addresses, 4 memory addresses, 2 irq
> and 2 drq lines.
>
> My code to support PnP in userconfig accepts commands with the
> following syntax:
>
> pnp 1 0 enable port0 0x534 irq0 7 irq1 5 drq0 3 drq1 4 ....
>
> where the first two parameters identify the CSN and LDN of the card.
> I can replace the first parameter with the vendor_id so that the line
> would become something like:
>
> pnp 0x0100561e 0 enable port0 ...
>
> with the advantage of making the same command work independently of
> the CSN assigned to the card, but with the disadvantage of a longer
> command and of making impossible to have two cards of the same type on
> the same machine (unless one adds another 32-bit integer, the serial
> number). I'd really go for the first option unless there are strong
> objections.
Well... How about making it possible to use both, just in case someone has
a problem with knowing the CSN of the card, and only has one card of that
kind. Something like:
pnp 1 0 enable port0 0x534 irq0 7 irq1 5 drq0 3 drq1 4
OR
pnp v0x0100561e 0 enable port0 0x534 irq0 7 irq1 5 drq0 3 drq1 4
Where both are supported? Should be a simple case like:
if (*x == 'v') { vid } else { CSN }
The synatx above, or the one where you specify as many as you want after
the keyword shouldn't matter for this change, so that's irrelevant to this
question.
/Mikael
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?199709032138.XAA18864>
