[ltp] Re: Hotswap driver (supports DMA, etc etc)

Jim Duchek linux-thinkpad@linux-thinkpad.org
Tue, 21 Feb 2006 17:37:24 -0600


------=_Part_1453_16855036.1140565044707
Content-Type: text/plain; charset=ISO-8859-1
Content-Transfer-Encoding: quoted-printable
Content-Disposition: inline

Um... There is one thing you need to do... Use the new version that I
_didn't_ dick up the insertion code while I was cleaning it up :)

http://chuchofjim.org/sources/lt_hotswap-0.1.6.tar.gz

I think there may be a DMA reinitialization error that popped up that wasn'=
t
popping up last night... let me see how this does first though.

Jim


On 21/02/06, Peter Fr=FChberger <peter.fruehberger@gmail.com> wrote:
>
> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: RIPEMD160
>
> Jim Duchek schrieb:
> > That looks good, actually.  If you're just using a DVD drive and not
> > actually 'mounting' anything, you may wish to use the auto_eject=3D1
> > parameter.  I'm not sure how the R40 works, but at least on my T22
> there's a
> > little switch that pops a lever out -- that also sends a signal that yo=
u
> > want to eject the drive (but until you pull the lever, the drive stays
> fully
> > connected).  auto_eject=3D1 will unregister the IDE interface and eject
> the
> > drive w/o any userspace help.
> >
> >
>
> Summary:
> insert kernel modul:
> modprobe lt_hotswap auto_eject=3D1
>
> kernel says:
> Laptop ultrabay hotswap driver version 0.1.5
> lt_hotswap: '\_SB.PCI0.ISA.EC0.BAT1' not found.
> lt_hotswap: '\_SB.PCI.ISA.EC.BAT1' not found.
> lt_hotswap: '\_SB.PCI0.ISA0.EC0.BAT1' not found.
> lt_hotswap: '\_SB.PCI0.ISA.EC.BAT1' not found.
> lt_hotswap: '\_SB.PCI0.AD4S.EC0.BAT1' not found.
> lt_hotswap: '\_SB.PCI0.ICH3.EC0.BAT1' not found.
> lt_hotswap: '\_SB.PCI0.LPC.EC.BAT1' found!
> lt_hotswap: No object found -- installing our handler.
> lt_hotswap: '\_SB.PCI.IDE.SECN.MAST' not found.
> lt_hotswap: '\_SB.PCI0.IDE0.IDES.IDSM' not found.
> lt_hotswap: '\_SB.PCI0.IDE0.SCND.MSTR' found!
> lt_hotswap: Old handler found! 00000001 dff86434 00000000
> lt_hotswap: '\_SB.PCI0.ISA.FDC.FDD0' not found.
>
>
> seems to be good.
> todesstern:/usr/src/patches/lt_hotswap-0.1.5# hdparm -i /dev/hdc
>
> before eject:
> (dma seems to be okay)
> /dev/hdc:
>
> Model=3DHL-DT-STCD-RW/DVD DRIVE GCC-4240N, FwRev=3D0214, SerialNo=3D
> Config=3D{ Fixed Removeable DTR<=3D5Mbs DTR>10Mbs nonMagnetic }
> RawCHS=3D0/0/0, TrkSize=3D0, SectSize=3D0, ECCbytes=3D0
> BuffType=3Dunknown, BuffSize=3D0kB, MaxMultSect=3D0
> (maybe): CurCHS=3D0/0/0, CurSects=3D0, LBA=3Dyes, LBAsects=3D0
> IORDY=3Don/off, tPIO=3D{min:120,w/IORDY:120}, tDMA=3D{min:120,rec:120}
> PIO modes:  pio0 pio1 pio2 pio3 pio4
> DMA modes:  sdma0 sdma1 sdma2 mdma0 mdma1 mdma2
> UDMA modes: udma0 udma1 *udma2
> AdvancedPM=3Dno
> Drive conforms to: Unspecified:  ATA/ATAPI-2 ATA/ATAPI-3 ATA/ATAPI-4
> ATA/ATAPI-5
>
> * signifies the current active mode
>
> pressing the little "thing" next to the drive:
> lt_hotswap: Requesting IDE eject!
> lt_hotswap: Attempting to eject
> lt_hotswap: Attempting to eject
> lt_hotswap: Attempting to eject
>
> pulling out the drive
>
>
> insert in again:
> hdparm -i /dev/hdc
> /dev/hdc: No such file or directory
>
>
> Do I have to do something else to get it back?
>
> thx for help
>
> Peter
>
>
>
>
> - --
>                     Key-ID:     0x1A995A9B
>                     keyserver: pgp.mit.edu
> =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D
> Fingerprint: 4606 DA19 EC2E 9A0B 0157  C81B DA07 CF63 1A99 5A9B
> -----BEGIN PGP SIGNATURE-----
> Version: GnuPG v1.4.2 (GNU/Linux)
> Comment: Using GnuPG with Thunderbird - http://enigmail.mozdev.org
>
> iD8DBQFD+5rU2gfPYxqZWpsRA6z5AKDwjzSn7wwqGp3KAXXs9CYKrc1NsACfUVYT
> yTv8R5biSLYdka1j32TbRaU=3D
> =3D5Gxh
> -----END PGP SIGNATURE-----
> --
> The linux-thinkpad mailing list home page is at:
> http://mailman.linux-thinkpad.org/mailman/listinfo/linux-thinkpad
>

------=_Part_1453_16855036.1140565044707
Content-Type: text/html; charset=ISO-8859-1
Content-Transfer-Encoding: quoted-printable
Content-Disposition: inline

Um... There is one thing you need to do... Use the new version that I _didn=
't_ dick up the insertion code while I was cleaning it up :)<br><br><a href=
=3D"http://chuchofjim.org/sources/lt_hotswap-0.1.6.tar.gz">http://chuchofji=
m.org/sources/lt_hotswap-0.1.6.tar.gz
</a><br><br>I think there may be a DMA reinitialization error that popped u=
p that wasn't popping up last night... let me see how this does first thoug=
h.<br><br>Jim<br><br><br><div><span class=3D"gmail_quote">On 21/02/06, <b c=
lass=3D"gmail_sendername">
Peter Fr=FChberger</b> &lt;<a href=3D"mailto:peter.fruehberger@gmail.com">p=
eter.fruehberger@gmail.com</a>&gt; wrote:</span><blockquote class=3D"gmail_=
quote" style=3D"border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt =
0pt 0.8ex; padding-left: 1ex;">
-----BEGIN PGP SIGNED MESSAGE-----<br>Hash: RIPEMD160<br><br>Jim Duchek sch=
rieb:<br>&gt; That looks good, actually.&nbsp;&nbsp;If you're just using a =
DVD drive and not<br>&gt; actually 'mounting' anything, you may wish to use=
 the auto_eject=3D1
<br>&gt; parameter.&nbsp;&nbsp;I'm not sure how the R40 works, but at least=
 on my T22 there's a<br>&gt; little switch that pops a lever out -- that al=
so sends a signal that you<br>&gt; want to eject the drive (but until you p=
ull the lever, the drive stays fully
<br>&gt; connected).&nbsp;&nbsp;auto_eject=3D1 will unregister the IDE inte=
rface and eject the<br>&gt; drive w/o any userspace help.<br>&gt;<br>&gt;<b=
r><br>Summary:<br>insert kernel modul:<br>modprobe lt_hotswap auto_eject=3D=
1<br><br>kernel says:
<br>Laptop ultrabay hotswap driver version 0.1.5<br>lt_hotswap: '\_SB.PCI0.=
ISA.EC0.BAT1' not found.<br>lt_hotswap: '\_SB.PCI.ISA.EC.BAT1' not found.<b=
r>lt_hotswap: '\_SB.PCI0.ISA0.EC0.BAT1' not found.<br>lt_hotswap: '\_SB.PCI=
0.ISA.EC.BAT1' not found.
<br>lt_hotswap: '\_SB.PCI0.AD4S.EC0.BAT1' not found.<br>lt_hotswap: '\_SB.P=
CI0.ICH3.EC0.BAT1' not found.<br>lt_hotswap: '\_SB.PCI0.LPC.EC.BAT1' found!=
<br>lt_hotswap: No object found -- installing our handler.<br>lt_hotswap: '=
\_SB.PCI.IDE.SECN.MAST' not found.
<br>lt_hotswap: '\_SB.PCI0.IDE0.IDES.IDSM' not found.<br>lt_hotswap: '\_SB.=
PCI0.IDE0.SCND.MSTR' found!<br>lt_hotswap: Old handler found! 00000001 dff8=
6434 00000000<br>lt_hotswap: '\_SB.PCI0.ISA.FDC.FDD0' not found.<br><br>
<br>seems to be good.<br>todesstern:/usr/src/patches/lt_hotswap-0.1.5# hdpa=
rm -i /dev/hdc<br><br>before eject:<br>(dma seems to be okay)<br>/dev/hdc:<=
br><br> Model=3DHL-DT-STCD-RW/DVD DRIVE GCC-4240N, FwRev=3D0214, SerialNo=
=3D<br>
 Config=3D{ Fixed Removeable DTR&lt;=3D5Mbs DTR&gt;10Mbs nonMagnetic }<br> =
RawCHS=3D0/0/0, TrkSize=3D0, SectSize=3D0, ECCbytes=3D0<br> BuffType=3Dunkn=
own, BuffSize=3D0kB, MaxMultSect=3D0<br> (maybe): CurCHS=3D0/0/0, CurSects=
=3D0, LBA=3Dyes, LBAsects=3D0
<br> IORDY=3Don/off, tPIO=3D{min:120,w/IORDY:120}, tDMA=3D{min:120,rec:120}=
<br> PIO modes:&nbsp;&nbsp;pio0 pio1 pio2 pio3 pio4<br> DMA modes:&nbsp;&nb=
sp;sdma0 sdma1 sdma2 mdma0 mdma1 mdma2<br> UDMA modes: udma0 udma1 *udma2<b=
r> AdvancedPM=3Dno<br> Drive conforms to: Unspecified:&nbsp;&nbsp;ATA/ATAPI=
-2 ATA/ATAPI-3 ATA/ATAPI-4
<br>ATA/ATAPI-5<br><br> * signifies the current active mode<br><br>pressing=
 the little &quot;thing&quot; next to the drive:<br>lt_hotswap: Requesting =
IDE eject!<br>lt_hotswap: Attempting to eject<br>lt_hotswap: Attempting to =
eject
<br>lt_hotswap: Attempting to eject<br><br>pulling out the drive<br><br><br=
>insert in again:<br> hdparm -i /dev/hdc<br>/dev/hdc: No such file or direc=
tory<br><br><br>Do I have to do something else to get it back?<br><br>thx f=
or help
<br><br>Peter<br><br><br><br><br>- --<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbs=
p;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&=
nbsp;&nbsp;Key-ID:&nbsp;&nbsp;&nbsp;&nbsp; 0x1A995A9B<br>&nbsp;&nbsp;&nbsp;=
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nb=
sp;&nbsp;&nbsp;&nbsp;&nbsp;keyserver: <a href=3D"http://pgp.mit.edu">pgp.mi=
t.edu</a><br>=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D
<br>Fingerprint: 4606 DA19 EC2E 9A0B 0157&nbsp;&nbsp;C81B DA07 CF63 1A99 5A=
9B<br>-----BEGIN PGP SIGNATURE-----<br>Version: GnuPG v1.4.2 (GNU/Linux)<br=
>Comment: Using GnuPG with Thunderbird - <a href=3D"http://enigmail.mozdev.=
org">http://enigmail.mozdev.org
</a><br><br>iD8DBQFD+5rU2gfPYxqZWpsRA6z5AKDwjzSn7wwqGp3KAXXs9CYKrc1NsACfUVY=
T<br>yTv8R5biSLYdka1j32TbRaU=3D<br>=3D5Gxh<br>-----END PGP SIGNATURE-----<b=
r>--<br>The linux-thinkpad mailing list home page is at:<br><a href=3D"http=
://mailman.linux-thinkpad.org/mailman/listinfo/linux-thinkpad">
http://mailman.linux-thinkpad.org/mailman/listinfo/linux-thinkpad</a><br></=
blockquote></div><br>

------=_Part_1453_16855036.1140565044707--