Subject: Re: where to init CL-PD6722 PCMCIA ctlr reg to enable ATA disk activity LED?
To: Tad Hunt <firstname.lastname@example.org>
From: Manuel Bouyer <email@example.com>
Date: 04/04/2002 23:06:17
On Thu, Apr 04, 2002 at 12:02:05PM -0800, Tad Hunt wrote:
> We're running a CL-PD6722 (i82365 compat) PCMCIA controller in our
> hardware. We have a disk activity LED that the controller can
> drive. Our bootloader PCMCIA ATA controller currently configures
> the PD6722 to drive this led, and it works correctly.
> My question is where is the appropriate place in the NetBSD PCMCIA
> framework to add the PD6722 register config for enabling the PD6722
> to drive the LED? I thought about changing wdc_pcmcia.c, but that
> didn't seem like a the right place for this.
> Should I replace the "pcic_chip_socket_enable" (and disable) function
> pointer in the "sc->pct", with a pointer to my own function which
> calls pcic_chip_socket_enable, and then figures out if it is an
> ata disk?
> Would I even know it was an ATA disk after pcic_chip_socket_enable()
Not always, but I suspect it would be enouth: pcic_chip_socket_enable() is
first called before probe, so at this point you don't know if it's a HD
It will be called later at mount time, and here we know what is attached
Manuel Bouyer <firstname.lastname@example.org>