From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.33) id 1CRTOJ-0004iq-JQ for qemu-devel@nongnu.org; Tue, 09 Nov 2004 05:38:23 -0500 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.33) id 1CRTOG-0004hF-FG for qemu-devel@nongnu.org; Tue, 09 Nov 2004 05:38:20 -0500 Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.33) id 1CRTOG-0004hB-C2 for qemu-devel@nongnu.org; Tue, 09 Nov 2004 05:38:20 -0500 Received: from [194.90.9.29] (helo=mxout5.netvision.net.il) by monty-python.gnu.org with esmtp (Exim 4.34) id 1CRTFF-0002DZ-EH for qemu-devel@nongnu.org; Tue, 09 Nov 2004 05:29:01 -0500 Received: from abu-fatma.softier.local ([212.143.109.38]) by mxout5.netvision.net.il (iPlanet Messaging Server 5.2 HotFix 1.21 (built Sep 8 2003)) with ESMTP id <0I6W00GNFQGBYD@mxout5.netvision.net.il> for qemu-devel@nongnu.org; Tue, 09 Nov 2004 12:28:59 +0200 (IST) Date: Tue, 09 Nov 2004 12:28:59 +0200 From: Hetz Ben Hamo Subject: Re: [Qemu-devel] enabling bus-master IDE driver In-reply-to: Message-id: <200411091228.59032.hetz@softier.com> MIME-version: 1.0 Content-type: text/plain; charset=windows-1255 Content-transfer-encoding: 7BIT Content-disposition: inline References: <20041107111655.GG29120@suse.de> Reply-To: qemu-devel@nongnu.org List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Paul Jakma , Fabrice Bellard Cc: qemu-devel@nongnu.org Where's your patch? Also, I'm CC'ing Fabrice.. Thanks, Hetz On Tuesday 09 November 2004 09:38, Paul Jakma wrote: > Hi Jens, > > The below patch, together with Juergen's PCI IDE busmaster patch, > results in Solaris enabling DMA on the QEMU harddisk. > > It still prints: > > ata_set_feature: (0x66,0x0) failed > > for both the harddisk and CDROM though. Also, it doesnt enable DMA on > the CDROM (though, I strongly suspect that could be deliberate on the > part of the Solaris kernel). > > Thanks! > > --paulj > > On Sun, 7 Nov 2004, Jens Axboe wrote: > > Here you go. > > > > Index: hw/ide.c > > =================================================================== > > RCS file: /cvsroot/qemu/qemu/hw/ide.c,v > > retrieving revision 1.28 > > diff -u -r1.28 ide.c > > --- hw/ide.c 9 Oct 2004 20:27:55 -0000 1.28 > > +++ hw/ide.c 7 Nov 2004 11:19:52 -0000 > > @@ -416,10 +416,10 @@ > > put_le16(p + 47, 0x8000 | MAX_MULT_SECTORS); > > #endif > > put_le16(p + 48, 1); /* dword I/O */ > > - put_le16(p + 49, 1 << 9); /* LBA supported, no DMA */ > > + put_le16(p + 49, 1 << 9 | 1 << 8); /* DMA and LBA supported */ > > put_le16(p + 51, 0x200); /* PIO transfer cycle */ > > put_le16(p + 52, 0x200); /* DMA transfer cycle */ > > - put_le16(p + 53, 1); /* words 54-58 are valid */ > > + put_le16(p + 53, 1 | 1 << 2); /* words 54-58,88 are valid */ > > put_le16(p + 54, s->cylinders); > > put_le16(p + 55, s->heads); > > put_le16(p + 56, s->sectors); > > @@ -437,6 +437,8 @@ > > put_le16(p + 85, (1 << 14)); > > put_le16(p + 86, 0); > > put_le16(p + 87, (1 << 14)); > > + put_le16(p + 88, 0x1f | (1 << 13)); > > + put_le16(p + 93, 1 | (1 << 14) | 0x2000 | 0x4000); > > } > > > > static void ide_atapi_identify(IDEState *s) > > @@ -1560,7 +1562,7 @@ > > case 0x82: /* write cache disable */ > > case 0xaa: /* read look-ahead enable */ > > case 0x55: /* read look-ahead disable */ > > - s->status = READY_STAT; > > + s->status = READY_STAT | SEEK_STAT; > > ide_set_irq(s); > > break; > > default: