* Re: SX DMA IDE (Was: Re: cheapest SX System i ever have seen)
@ 1998-03-28 10:55 Marcel Prisi
0 siblings, 0 replies; 2+ messages in thread
From: Marcel Prisi @ 1998-03-28 10:55 UTC (permalink / raw)
To: axp-list
>
>Mar 26 22:48:45 ymer kernel: hdc: IBM-DHEA-36480, 6197MB w/476kB Cache,
>CHS=12592/16/63, DMA
>
>ajo@ymer /home/ajo #time dd if=/dev/hdc of=/dev/null bs=65536 count=4096
>4096+0 records in
>4096+0 records out
>0.013u 3.117s 0:39.88 7.8% 0+0k 0+0io 73pf+0w
>ajo@ymer /home/ajo #expr 65536 "*" 4096 / 40
>6710886
>
On my PC164 (CMD 646, hda: QUANTUM FIREBALL SE4.3A, 4110MB w/80kb Cache,
CHS=8908/15/63) I got : (time dd if=/dev/hda2 of=/dev/null bs=65536
count=4096)
0.-35user 153.19system 2:46.32elapsed 91%CPU (no laughs, please ...), which
gives 65536 * 4096 / (2 * 60 + 46) : 1617081 Whouaouh ! (isn't it pathetic,
this is about the same as my 24X CDROM on my P5/233, AHA2940AU, just with
~80% more cpu use ...)
Someone said it looked like a i386 ??? Not so far !
Could someone try and hack a better driver ? (oh yes, please !)
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: cheapest SX System i ever have seen
@ 1998-03-28 0:07 Matti Aarnio
1998-03-28 1:51 ` SX DMA IDE (Was: Re: cheapest SX System i ever have seen) Andreas Johansson
0 siblings, 1 reply; 2+ messages in thread
From: Matti Aarnio @ 1998-03-28 0:07 UTC (permalink / raw)
To: axp-list
...
> from what i understand, the IDE controller in the PC164, etc. (CMD646) is
> actually a decent device. the problem is that because the prior version
> (the CMD640) was buggy and slow, nobody ever bothered to develop the
> driver for the 646 very far. it's another case of "if only somebody would
> write the [better] driver for it" ...
>
> i would be willing to give it a go, if only i knew the first thing about
> IDE or the CMD ...
Indeed. Having browsed chip specifications I would say that
the 2.1.X kernel's revised generic IDE stuff is sufficient to
drive CMD646.
The thing that CMD640 "driver" did was to activate certain
bug work-arounds for the chip, NOT to do actual driving.
> can anybody confirm my hunches about this controller? if so, can anybody
> point me toward online documentation for these things so that might toy
> around with it and see what i can do? (ah, the ignorance of youth ...)
Use the generic (E)IDE driver.
> -ross
/Matti Aarnio <matti.aarnio@tele.fi>
CDROM on EIDE, disks on UltraWide SCSI.
^ permalink raw reply [flat|nested] 2+ messages in thread
* SX DMA IDE (Was: Re: cheapest SX System i ever have seen)
1998-03-28 0:07 cheapest SX System i ever have seen Matti Aarnio
@ 1998-03-28 1:51 ` Andreas Johansson
0 siblings, 0 replies; 2+ messages in thread
From: Andreas Johansson @ 1998-03-28 1:51 UTC (permalink / raw)
To: axp-list
On Sat, 28 Mar 1998, Matti Aarnio wrote:
> ...
> > from what i understand, the IDE controller in the PC164, etc. (CMD646) is
> > actually a decent device. the problem is that because the prior version
> > (the CMD640) was buggy and slow, nobody ever bothered to develop the
> > driver for the 646 very far. it's another case of "if only somebody would
> > write the [better] driver for it" ...
> >
> > i would be willing to give it a go, if only i knew the first thing about
> > IDE or the CMD ...
>
> Indeed. Having browsed chip specifications I would say that
> the 2.1.X kernel's revised generic IDE stuff is sufficient to
> drive CMD646.
>
> The thing that CMD640 "driver" did was to activate certain
> bug work-arounds for the chip, NOT to do actual driving.
>
> > can anybody confirm my hunches about this controller? if so, can anybody
> > point me toward online documentation for these things so that might toy
> > around with it and see what i can do? (ah, the ignorance of youth ...)
>
> Use the generic (E)IDE driver.
Ok, I was going to wait with this until I finished, but I have run into
some problems, so I thought I'd tell you all what to expect of the 164SX's
EIDE controller even though my driver for it isn't finished yet.
First of all, the 164SX doesn't use the CMD64x chipset at all. That means
that my work probably will be of no use for the PC164 which people seem to
be talking about under this subject :/
Instead, the 164SX uses the Cypress CY82C693U chip. I have not checked
whether the 164LX uses the same chipset, but I think it does. For some
reason this chipset is detected as "Contaq" with the same numbers:
ajo@ymer ~ >cat /proc/pci
PCI devices found:
[...]
Bus 0, device 8, function 2:
IDE interface: Contaq 82C693 (rev 0).
Medium devsel. Fast back-to-back capable. Master Capable. No
bursts.
I/O at 0x170.
I/O at 0x374.
Non-prefetchable 32 bit memory at 0x28a0000.
[...]
Now, one day I got tired of my IDE driver taking ~100% cpu at the blazing
transfer rate of 1.2MB/s, so I decided to do something about it. Now, I
seemed to remeber that the Cypress device was quite similar to the Intel
devices, so I checked my Cypress documentation against the triton.c DMA
ide driver. And yes, the dma interface works the same way, but one needs
to set up some pci registers an other way with the Cypress device, mainly
for mapping the dma registers in io space.
I solved this very quickly, and now I have quite decent transfer speed and
cpu percentage to my IBM Ultrastar 6.4GB drive (these figures are while
doing multiple mode DMA transfers mode 2):
Mar 26 22:48:45 ymer kernel: hdc: IBM-DHEA-36480, 6197MB w/476kB Cache,
CHS=12592/16/63, DMA
ajo@ymer /home/ajo #time dd if=/dev/hdc of=/dev/null bs=65536 count=4096
4096+0 records in
4096+0 records out
0.013u 3.117s 0:39.88 7.8% 0+0k 0+0io 73pf+0w
ajo@ymer /home/ajo #expr 65536 "*" 4096 / 40
6710886
This test was done several times and I only have 128MB ram, so none of
the data was read from the cache.
My drive can actually do Ultra-ATA, but I haven't tried it with a
motherboard that supports this mode, so I don't know if I have hit the
limit of the drive. This might very well be the case, though.
I could easily make a working driver now, but I ran into another problem.
While doing large transfers from the IDE-drive I noticed a problem with my
DMA-using sound card. It actually can't play sound at the desired rate!
It seems the Cypress device never ever detaches from the pci bus while
doing dma transfers (and these can be up to 64k large). This happens even
if the transfer is divided in several smaller transfers via a transfer
descriptor table. I have never heard of this problem with the triton
chipset.
Then I tried setting the Cypress chip for using single mode transfer
(detach from the pci bus after each 32 bit transfer). This solved the
sound card problem, but in this mode the transfer rate stinks.
So my plan now is to make larger changes to the driver which will indeed
split up the transfers for real so that my soundcard may get enough pci
cycles for sound play. I'll post a patch for the kernel once I'm finished
with my dma driver for the Contaq chip, so stay tuned folks!
Any comments are naturally welcome.
/Andreas
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~1998-03-28 10:52 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
1998-03-28 10:55 SX DMA IDE (Was: Re: cheapest SX System i ever have seen) Marcel Prisi
-- strict thread matches above, loose matches on Subject: below --
1998-03-28 0:07 cheapest SX System i ever have seen Matti Aarnio
1998-03-28 1:51 ` SX DMA IDE (Was: Re: cheapest SX System i ever have seen) Andreas Johansson
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox