kern/125859: [ata] sata access failure [regression]

KOIE Hidetaka ( 鯉江英隆 ) hide at
Wed Dec 3 05:20:03 PST 2008

The following reply was made to PR kern/125859; it has been noted by GNATS.

From: KOIE Hidetaka (=?iso-2022-jp?B?GyRCOHE5PjFRTjQbKEI=?=) <hide at>
To: bug-followup at
Cc: hide at koie.rg
Subject: Re: kern/125859: [ata] sata access failure [regression]
Date: Wed, 03 Dec 2008 21:56:49 +0900 (JST)

 I found how to fix at last.
 This fix is to disable pre-allocation.
 Please anybody fix the problem correctly.
 Index: ata-dma.c
 RCS file: /museum/freebsd/repo/usr/src/sys/dev/ata/ata-dma.c,v
 retrieving revision 1.158
 diff -u -p -r1.158 ata-dma.c
 --- ata-dma.c	21 Oct 2008 18:51:55 -0000	1.158
 +++ ata-dma.c	2 Dec 2008 12:19:54 -0000
 @@ -183,7 +186,11 @@ ata_dmaalloc(device_t dev)
                                 NULL, NULL, ch->dma.max_iosize,
                                 ATA_DMA_ENTRIES, ch->dma.segsize,
 +#if 1 /*XXX KOIE*/
 +                               0, NULL, NULL, &slot->data_tag)) {
                                 BUS_DMA_ALLOCNOW, NULL, NULL, 
  &slot->data_tag)) {
  	    device_printf(ch->dev, "FAILURE - create data_tag\n");
  	    goto error;
 Before applying this patch,
 boot single user and then
 zfs volinit and then
 zfs mount -a and then
 ldd if=/dev/zero of=/tmp/chunk bs=2m count=2000 and then
 happen bus_dmamap_load() failure invoked by ata_dmaload().
 The callgraph is
             return non-zero because bz->free_bpages == 0.
 After the event, any ata devices on the system do not work.
 (The kernel can not dump to adX.
 To dump, scsi device or usb mass storage is needed.)
 KOIE Hidetaka <hide at>

More information about the freebsd-bugs mailing list