Subject: Re: Cardbus SIL3112 Sata Driver Development: Request for Help
To: Phil Quinton <pquinton@softhome.net>
From: Manuel Bouyer <bouyer@antioche.eu.org>
List: tech-kern
Date: 09/19/2005 18:36:52
On Mon, Sep 19, 2005 at 02:54:33PM +0100, Phil Quinton wrote:
> In article <20050919132806.GA1045@hanele>, freza@liberouter.org says...
> > Looks like you'll have to initialize pciide_softc manually. A good way
> > to handle this would probably be to write cardbuside_common_attach()
> > or somesuch -- all other IDE @ cardbus devices could benefit. You can
> > still use pciide_lookup_product() with cardbus, the ID on cardbus should
> > be the same as on PCI (ca_id from cardbus_attach_args).
> 
> Thanks for the reply,
> 
> Couple more questions, <grin>
> 
> pciide_common_attach() looks like this:
> 
> void
> pciide_common_attach(sc, pa, pp)
> 	struct pciide_softc *sc;
> 	struct pci_attach_args *pa;
> 	const struct pciide_product_desc *pp;
> {
> 
> am I right in saying, that I need to create a cardbuside_common_attach() 
> that builds a pciide_softc structure from a cardbus_attach_args, and not 
> the pci_attach_args (since the cardbus interface driver will be passed 
> the cardbus_attach_args)?

Yes, that's it.

-- 
Manuel Bouyer <bouyer@antioche.eu.org>
     NetBSD: 26 ans d'experience feront toujours la difference
--