From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([140.186.70.92]:56675) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1QTqpE-00074D-3F for qemu-devel@nongnu.org; Tue, 07 Jun 2011 03:35:45 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1QTqpB-0005Ho-PU for qemu-devel@nongnu.org; Tue, 07 Jun 2011 03:35:43 -0400 Received: from mail-px0-f174.google.com ([209.85.212.174]:51020) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1QTqpB-0005Hh-E5 for qemu-devel@nongnu.org; Tue, 07 Jun 2011 03:35:41 -0400 Received: by pxi15 with SMTP id 15so1498331pxi.33 for ; Tue, 07 Jun 2011 00:35:40 -0700 (PDT) Sender: Paolo Bonzini Message-ID: <4DEDD4C6.6070102@redhat.com> Date: Tue, 07 Jun 2011 09:35:34 +0200 From: Paolo Bonzini MIME-Version: 1.0 References: <1307430291.28149.126.camel@das-HP-EliteBook-8530w> In-Reply-To: <1307430291.28149.126.camel@das-HP-EliteBook-8530w> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit Subject: Re: [Qemu-devel] qemu - SCSI disk "Device Model", "Serial Number", and "Firmware Version"? List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: dave@seddon.ca Cc: qemu-devel@nongnu.org On 06/07/2011 09:04 AM, Dave Seddon wrote: > Here's an example of the nasty/QEMU output of smartmontools: > ------------------------------------------------------- > # smartctl -d sat --all /dev/sg0 > smartctl version 5.38 [i686-spcdn-linux-gnu] Copyright (C) 2002-8 Bruce Allen > Home page is http://smartmontools.sourceforge.net/ > > === START OF INFORMATION SECTION === > Device Model: [No Information Found] > Serial Number: [No Information Found] > Firmware Version: � " > Device is: Not in smartctl database [for details use: -P showall] > ATA Version is: 1 > ATA Standard is: Exact ATA specification draft version not indicated > Local Time is: Tue Jun 7 16:57:08 2011 UTC > SMART is only available in ATA Version 3 Revision 3 or greater. > We will try to proceed in spite of this. > SMART support is: Ambiguous - ATA IDENTIFY DEVICE words 82-83 don't show if SMART supported. > Checking for SMART support by trying SMART ENABLE command. > SMART ENABLE appeared to work! Continuing. > SMART support is: Ambiguous - ATA IDENTIFY DEVICE words 85-87 don't show if SMART is enabled. > A mandatory SMART command failed: exiting. To continue, add one or more '-T permissive' options > ------------------------------------------------------- Here we should perhaps try to improve the ATA emulation. > Looking in the source, I can see that the "QEMU HARDDISK" for example is > statically defined. Would this be difficult to make an option for the > '-drive '? > ------------------------------------------------------- > [root@tester hw]# grep -R 'QEMU' scsi-disk.c > QEMUIOVector qiov; > QEMUBH *bh; > memcpy(&outbuf[16], "QEMU CD-ROM ", 16); > memcpy(&outbuf[16], "QEMU HARDDISK ", 16); > memcpy(&outbuf[8], "QEMU ", 8); > s->version = qemu_strdup(QEMU_VERSION); > ------------------------------------------------------- It should not be hard. It probably would be better to do it for if=ide too, though.