Discussion:
atabus@wdc can't attach
KIYOHARA Takashi
2009-02-26 09:15:20 UTC
Permalink
Hi! all,


My hpcsh machine(PERSONA HPW-50PA) can't attach ***@wdc at current
(20090221). Maybe since this change.

http://cvsweb.netbsd.org/bsdweb.cgi/src/sys/dev/pcmcia/wdc_pcmcia.c.diff?r1=1.112&r2=1.113&f=h


We will have to delay attaching until kthread runs.

Thanks,
--
kiyohara
John Klos
2009-02-27 05:02:41 UTC
Permalink
Hi,
Post by KIYOHARA Takashi
(20090221). Maybe since this change.
I just got an hpcsh machine in the mail today (eBay, $35), and I noticed
that I had no atabus, too. Thank you for this! With that little change, a
NetBSD 5 kernel sees atabus and the CF card.

Now to get everything else working...

Thanks,
John Klos
Valeriy E. Ushakov
2009-03-06 22:39:15 UTC
Permalink
[Cc'ing Matthias who made the wdc_pcmcia_enable change in question]
Post by KIYOHARA Takashi
Hi! all,
(20090221). Maybe since this change.
http://cvsweb.netbsd.org/bsdweb.cgi/src/sys/dev/pcmcia/wdc_pcmcia.c.diff?r1=1.112&r2=1.113&f=h
We will have to delay attaching until kthread runs.
Index: hd64461pcmcia.c
===================================================================
RCS file: /cvsroot/src/sys/arch/hpcsh/dev/hd64461/hd64461pcmcia.c,v
retrieving revision 1.43
diff -u -r1.43 hd64461pcmcia.c
--- hd64461pcmcia.c 28 Apr 2008 20:23:22 -0000 1.43
+++ hd64461pcmcia.c 23 Feb 2009 17:49:39 -0000
@@ -269,14 +269,6 @@
&sc->sc_event_thread,
"%s", device_xname(self));
KASSERT(error == 0);
-
-#if !defined(HD64461PCMCIA_REORDER_ATTACH)
- hd64461pcmcia_attach_channel(sc, CHANNEL_0);
- hd64461pcmcia_attach_channel(sc, CHANNEL_1);
-#else
- hd64461pcmcia_attach_channel(sc, CHANNEL_1);
- hd64461pcmcia_attach_channel(sc, CHANNEL_0);
-#endif
}
STATIC void
@@ -286,6 +278,14 @@
struct hd64461pcmcia_event *pe;
int s;
+#if !defined(HD64461PCMCIA_REORDER_ATTACH)
+ hd64461pcmcia_attach_channel(sc, CHANNEL_0);
+ hd64461pcmcia_attach_channel(sc, CHANNEL_1);
+#else
+ hd64461pcmcia_attach_channel(sc, CHANNEL_1);
+ hd64461pcmcia_attach_channel(sc, CHANNEL_0);
+#endif
+
while (!sc->sc_shutdown) {
tsleep(sc, PWAIT, "CSC wait", 0);
s = splhigh();
I think this change is not necessary and ***@pcmcia should be fixed
instead.

If I understand the problem correctly, revision 1.113 of wdc_pcmcia.c
broke *all* ***@pcmcia attachments at boot time as wdc_pcmcia_attach
calls wdc_pcmcia_enable and wdc_pcmcia_enable now refuses to work when
we are cold. It would be wrong to fix this problem in all pcmcia
controller drivers - instead wdc_pcmcia_attach should defer some of
its work with config_interrupts properly.

SY, Uwe
--
***@stderr.spb.ru | Zu Grunde kommen
http://snark.ptc.spbu.ru/~uwe/ | Ist zu Grunde gehen
Loading...