Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 11 Sep 1997 17:24:55 +0200 (MET DST)
From:      Luigi Rizzo <luigi@labinfo.iet.unipi.it>
To:        mike@smith.net.au (Mike Smith)
Cc:        mike@smith.net.au, gurney_j@resnet.uoregon.edu, perhaps@yes.no, freebsd-hackers@freebsd.org
Subject:   Re: PnP support
Message-ID:  <199709111524.RAA00618@labinfo.iet.unipi.it>
In-Reply-To: <199709110727.RAA07246@word.smith.net.au> from "Mike Smith" at Sep 11, 97 05:27:28 pm

next in thread | previous in thread | raw e-mail | index | archive | help
Let me edit this slightly...

> The most succinct extract I have on the "new" model reads :
>  
>  ---8<---snip---8<---
> 
>  - gather all the information :
>         PCI probe

i.e. trust what the PCI bios says ?

>         PnP probe
>         get ISA config (compiled in, datafile, etc.)

this means probe the isa devices and trust what the config info
say.  At this point we have already effectively allocated 'extents'
for legacy ISA devices.

>         get PCI/PnP identifier tables (compiled in, bootloader, etc.)

this looks like a second-level probe for these devices: those not
recognised by PCI/PnP drivers will be used as ISA ones ? Wouldn't
it make more sense to merge this step with the PCI and PnP probe,
so that devices recognized as PCI/PnP can be left with some degree
of freedom in reallocating resources, whereas others get fixed
resources ?

Also, while we are on the subject: some legacy ISA device also have
software-configurable resources such as DMA or IRQ channels. methods
are device-specific (pre-PnP).

In other words, in this first 'probe' phase we end up with some
resources which are bound to a given value, and other which might
be assigned from a set of alternatives.

ALLOCATE:
Before going on with the attach, we have to take a decision among
the available options and then just go on with the attach routines,
marking those devices which could not be allocated the requested
resources ?



> 
>  - attach PCI devices
>         I/O ports and IRQs are assigned by the PCI rules.
>  - attach PnP devices
>         IRQs are taken from the free pool left after PCI assignment and
>         those marked for 'legacy' use.  I/O ports are probed as per the
>         PnP spec.
>  - walk ISA config data, probe possible devices
>         We know which IRQ and I/O resources are still available,
>         we can hunt for devices that match the gaps.

here if some attach fails we can free the resources which have been
allocated for them, and possibly go back to ALLOCATE: if any device was
left out ?

> I think it's important to leave the 'legacy' devices until _last_, as
> this prevents a PnP device being accidentally recognised as a 'legacy'
> device.

Right.

Comments ?

	Cheers
	Luigi
-----------------------------+--------------------------------------
Luigi Rizzo                  |  Dip. di Ingegneria dell'Informazione
email: luigi@iet.unipi.it    |  Universita' di Pisa
tel: +39-50-568533           |  via Diotisalvi 2, 56126 PISA (Italy)
fax: +39-50-568522           |  http://www.iet.unipi.it/~luigi/
_____________________________|______________________________________



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