NATA update

YONETANI Tomokazu qhwt+dfly at
Sat Dec 9 07:17:49 PST 2006

On Tue, Dec 05, 2006 at 11:29:44PM +0000, Thomas E. Spanjaard wrote:
> Petr Janda wrote:
> >Does this mean now that onboard RAID controllers that come with today 
> >nearly all motherboards will be finally supported? If so, thats awesome. 
> >How do I test NATA ?
> They will be, after I've finished porting ataraid.
> To test the code that's already been tested, you have to apply the diff 
> I mentioned in [1], remove all old ata devices from your kernel config, 
> add options PCI_MAP_FIXUP to it, and then either add (at least) device 
> nata, natadisk and natapicd (for disks and cdroms respectively), or add 
> 'nata' to SUBDIR in src/sys/dev/disk/Makefile, and edit your 
> /boot/loader.conf to read nata_load="YES", natapci="YES", 
> natadisk="YES", natapicd="YES". make buildkernel, make installkernel, 
> reboot. If it doesn't work, boot kernel.old, and report issues :).

I got a panic:
  panic: spin_lock: 0xc240ba6c, indefinite wait!

and the backtrace:
  exponential_backoff(c04eec44) at exponential_backoff+0xa2
  spin_lock_wr_contested(c240ba6c,80000000) at spin_lock_wr_contested+0x74
  ata_completed(c240ba20,0,c40dea8,c029f038,c028e420) at ata_completed+0xc53c
  ata_queue_requst(c240ba20,c,0,cc40d488,cc40dea8) at ata_queue_requst+0x286
  ata_contolcmd(cc40dea8) ata acd_attach+0xc1
  device_prove_and_attach(cc40dea8) at device_prove_and_attach+0x15b
  bus_generic_attach(cc40d488,cc40d488,ffffffff,ffffffff,0) at bus_generic_attach+0x14
  ata_identify(cc40d488) at ata_identify+0x1bb
  ata_boot_attach(0) at ata_boot_attach+0x2a
  run_interrupt_driven_config_hooks(0,4ebc00,4f9000,0,c012b29c) at run_interrupt_driven_config_hooks+0x18
  mi_startup(4eb000,ff800000,c02e02c0,c04ee9e0,c04ee9e0) at mi_startup+0x93
  begin() at begin+0x43

Other interesting boot messages before the panic are:

  ad2: setting PIO4 on M5229 chip
  ad2: setting UDMA100 on M5229 chip
  ad2: 57241MB <Seagate ST306615A 3.33> at ata0-slave UDMA100
  ad2: 117231408 sectors [116301C/16H/63S] 16 sectors/interrupt 1 depth queue
  ata1-slave: pio=PIO4 wdma=WDMA2 udma=UDMA33 cable=80 wire
  acd0: setting PIO4 on M5229 chip
(several seconds here)
  acd0: WARNING - DEVICE_RESET taskqueue timeout - completing request directly
  spin_lock: 0xc240ba6c, indefinite wait!
  spin_lock: 0xc240ba6c, indefinite wait!

nata* drivers are compiled in an SMP kernel, running on Athlon64X2
with ASRock 939Dual-SATA2 .  If I yank off the DVD-ROM drive from the
system, it proceeds to mount root fs, then failed:

  Mounting root from ufs:/dev/ad0s1h
  no such device 'ad'
  setrootbyname failed
  ffs_mountroot: can't find rootvp
  Root mount failed: 6

  Manual root filesystem specification:
    <fstype>:<device>  Mount <device> using filesystem <fstype>
			 eg. ufs:da0s1a
    ?                  List valid disk boot devices
    <empty line>       Abort manual input

  Possibly valid devices for 'ufs' root:
   "console" "ctty" "mem" "pts" "ptc" "log" "sc" "FD" "bpf" "sio" "mixer" "apm" "ccd" "pci" "xpt" "kbd" "acpi" "ata"

Although this mother board has a SATA port, the IDE drives are PATA one
and connected to the PATA ports.  Another machine whose root fs is on
a SCSI drive booted without a problem.


More information about the Kernel mailing list