Subject: Re: problems with pcmcia hard drive
To: Charles M. Hannum <abuse@spamalicious.com>
From: Steven M. Bellovin <smb@research.att.com>
List: netbsd-users
Date: 04/29/2001 21:25:06
In message <20010429134236.I25151@mail.netbsd.org>, "Charles M. Hannum" writes:
>
>On Thu, Apr 19, 2001 at 02:28:36PM -0400, Steve Bellovin wrote:
>>
>> On a new Thinkpad T21 laptop running 1.5, I tried inserting a PCMCIA 
>> Maxtor hard drive.  When I do, the machine hangs.  It prints
>> "Stray interrupt on IRQ 7" (or words to that effect), followed by "wd2 
>> at pcmcia1 function 0".  It never comes back after that.  Hitting 
>> cntl+alt+esc makes it say "cardslot1 at cpu_Debugger+0x4 leave".
>
>Can you try it using pcic (i.e. plain PCMCIA), rather than pccbb (i.e.
>CardBus)?  I believe this is instantiation of an IRQ stalling behavior
>I reported AGES ago, which is tickled by pccbb because it uses
>level-trigger mode.
>
>
I tried it, but I probably did something wrong, since the PCMCIA slots 
no longer worked at all.  Here are diff's of the two config files:

b133$ diff BERKSHIRE BERKSHIRE2
269,270c269,270
< cbb*          at pci? dev ? function ?
< cardslot*     at cbb? 
---
> #cbb*         at pci? dev ? function ?
> #cardslot*    at cbb? 
273,274c273,274
< cardbus*      at cardslot?
< pcmcia*       at cardslot?
---
> #cardbus*     at cardslot?
> #pcmcia*      at cardslot?
332c332
< com*  at cardbus? dev ? function ?    # Modems and serial cards
---
> #com* at cardbus? dev ? function ?    # Modems and serial cards
379c379
< ahc*  at cardbus? dev ? function ?    # Adaptec ADP-1480
---
> #ahc* at cardbus? dev ? function ?    # Adaptec ADP-1480
382c382
< scsibus* at ahc?
---
> #scsibus* at ahc?
474,477c474,477
< ex*   at cardbus? dev ? function ?    # 3Com 3C575TX
< fxp*  at cardbus? dev ? function ?    # Intel i8255x
< rtk*  at cardbus? dev ? function ?    # Realtek 8129/8139
< tlp*  at cardbus? dev ? function ?    # DECchip 21143
---
> #ex*  at cardbus? dev ? function ?    # 3Com 3C575TX
> #fxp* at cardbus? dev ? function ?    # Intel i8255x
> #rtk* at cardbus? dev ? function ?    # Realtek 8129/8139
> #tlp* at cardbus? dev ? function ?    # DECchip 21143

The BERKSHIRE2 kernel (without CardBus) did find the PCMCIA controllers:

pcic0 at isa0 port 0x3e0-0x3e1 iomem 0xd0000-0xdffff
pcic0: controller 0 (Intel 82365SL Revision 1) has sockets A and B
pcic0: controller 1 (Intel 82365SL Revision 1) has no sockets
pcmcia0 at pcic0 controller 0 socket 0
pcmcia1 at pcic0 controller 0 socket 1

but it didn't recognize any of the PCMCIA cards I inserted, including 
the 802.11 network card I use every day.  Debugging output shows that 
pcmcia_cis was entered, to no avail -- nothing was detected.

On other other hand...  I slightly misspoke in the first note I posted 
-- the failure is with 1.5.1 BETA.  But the 1.5 Wasabi CD installation 
kernel and a trial 1.5R kernel compiled on another machine do behave 
properly with that disk.

I also learned that I could make the machine come back to life by 
popping out the cafrd.

		--Steve Bellovin, http://www.research.att.com/~smb