Subject: Re: Fwd: Re: Queries about bus_space (MIPS: TX49)
To: Jochen Kunz <jkunz@unixag-kl.fh-kl.de>
From: Anand Lalgondar <solarflares@fastmail.fm>
List: tech-kern
Date: 02/03/2004 19:38:22
> > But is it neccessary
> > to create all the tags before autoconfiguration process? 
> What do you mean with "all the tags"? You have only one. (Or maybe two
> for distinct I/O and memory spaces. But this depends on your hardware
> and implementation.) All tags (bus space and bus dma) must be valid at
> the start of autoconfig. The tags are passed along down the device tree
> in the attach args. Device drivers copy them to there internal data
> structures at attach time.
> 
Well I have the __BS(init) function call in one of the parent driver.
This is with resepect to the case of PCI I/O and memory space tag
creation.

something like the below in the 'mainbus' driver:

	/* Initialise the interrupt part of our PCI chipset tag. */
	rbtx4927_pci_init(&sc->sc_pci_chipset, sc);

	/* Initialise the PCI spaces. */
	rbtx4927_bus_io_init(&sc->sc_pci_iot, sc);
	rbtx4927_bus_mem_init(&sc->sc_pci_memt, sc);

Now if I have to support a PCMCIA protocol which supports three address
space(attribute, memory and I/O each of 64MB) then I have create three
new tags to access the individual addresses. ??

 - Anand

-- 
http://www.fastmail.fm - Email service worth paying for. Try it for free