Testing CAM wrapper for ata(4) controller drivers

Tom Uffner tom at uffner.com
Mon Dec 14 03:16:55 UTC 2009


Alexander Motin wrote:
> Hi.
> 
> I would like to present for testing patch, turning ata(4) controllers
> drivers into native SIMs of new CAM ATA infrastructure. This patch adds
> new ATA_CAM kernel option, which allows switching between legacy and new
>  CAM-based operation modes. To enable new mode you should add
> options	ATA_CAM
> line to the kernel configuration file in addition to the ones required
> by CAM infrastructure and rebuild/reinstall the kernel.
> 
> In legacy mode, the only difference will be - the way in which SATA
> speeds reported. Instead of mixing SATA revisions with PATA modes, they
> were separated, as they should be, allowing, for example, DMA-incapable
> or buggy SATA devices (usually PATA devices with built-in PATA/SATA
> converter) to work in PIO mode.
> 
> While doing it, I had to completely rewrite ata(4) mode setting code, so
> legacy operation also need to be tested. I have successfully tested it
> on Intel, NVidia, VIA, Marvell, JMicron PATA controllers with all
> PIO/DMA modes. Different controllers feedbacks are especially welcome.

this change breaks my Promise SATA card

atapci0: <Promise PDC20771 SATA300 controller> port 
0xdc00-0xdc7f,0xd800-0xd8ff mem 0xfeaff000-0xfeafffff,0xfeac0000-0xfeadffff 
irq 23 at device 11.0 on pci2

kernels from after the commit on 12/6 are unable to mount my drives.
i get (from memory, since i can't even get to single user mode)
WARNING - READ_DMA UDMA ICRC error
followed by lots of SETFEATURE foo errors then a READ_DMA timeout
followed by a bus reset and the cycle repeats...

before this commit it worked fine.

this is in the legacy mode. i am building a kernel with "options ATA_CAM"
now

tom


More information about the freebsd-current mailing list