From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:55417) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Yikwr-0005Qa-1I for qemu-devel@nongnu.org; Thu, 16 Apr 2015 10:39:21 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Yikwn-0001oN-QJ for qemu-devel@nongnu.org; Thu, 16 Apr 2015 10:39:20 -0400 Received: from mx1.redhat.com ([209.132.183.28]:58163) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Yikwn-0001o1-LP for qemu-devel@nongnu.org; Thu, 16 Apr 2015 10:39:17 -0400 Message-ID: <552FC98A.7080000@redhat.com> Date: Thu, 16 Apr 2015 16:39:06 +0200 From: Paolo Bonzini MIME-Version: 1.0 References: <552FBC7E.8050806@redhat.com> In-Reply-To: Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit Subject: Re: [Qemu-devel] How to modify QEMU source to read the bus for SATA directly? List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Peter Teoh Cc: qemu-devel@nongnu.org On 16/04/2015 16:26, Peter Teoh wrote: > > You can use PCI passthrough and let the guest use the whole SATA bus, if > you have another way to access other disks on the same bus (e.g. boot > from a USB stick or access the filesystems on NFS). > > Or you can use SCSI passthrough and pass the /dev/sdX device to the > guest, e.g. > > -device virtio-scsi-pci > -drive if=none,file=/dev/sdb,id=sdb,cache=none,format=raw > -device scsi-block,drive=sdb > > The guest then will talk to the host's ATA->SCSI translation layer, and > will be able to send raw ATA commands via the ATA PASSTHROUGH command. > > Thank you very much, that answer saved me many hours of search/trial and > errors. And seems to work for now...need more testing. FWIW, which one did you use and what kind of command did you need? Paolo