From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:47142) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Ya2eB-0000rH-Va for qemu-devel@nongnu.org; Mon, 23 Mar 2015 09:44:04 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Ya2e2-0004gL-Sw for qemu-devel@nongnu.org; Mon, 23 Mar 2015 09:44:03 -0400 Received: from mx1.redhat.com ([209.132.183.28]:54008) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Ya2e2-0004g9-Mf for qemu-devel@nongnu.org; Mon, 23 Mar 2015 09:43:54 -0400 From: Markus Armbruster References: <1426953265-19940-1-git-send-email-pbonzini@redhat.com> <87twxct6yq.fsf@blackfin.pond.sub.org> <55100193.5000701@redhat.com> <551012D4.2070407@redhat.com> Date: Mon, 23 Mar 2015 14:43:48 +0100 In-Reply-To: <551012D4.2070407@redhat.com> (Paolo Bonzini's message of "Mon, 23 Mar 2015 14:19:16 +0100") Message-ID: <87sicvltgr.fsf@blackfin.pond.sub.org> MIME-Version: 1.0 Content-Type: text/plain Subject: Re: [Qemu-devel] [PATCH for-2.3] sdhci: add "drive" property List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Paolo Bonzini Cc: Peter Maydell , Peter Crosthwaite , QEMU Developers , "Edgar E. Iglesias" Paolo Bonzini writes: > On 23/03/2015 13:09, Peter Maydell wrote: >> > The only alternative for 2.3 is reverting the patch for sdhci-pci. I >> > certainly don't want "-drive if=sd -device sdhci-pci" to become ABI! >> >> What's wrong with that, incidentally? It's what I would have >> expected for connecting an SD card to sdhci-pci, given >> how the other SD controller devices work. (The only >> difference with sdhci-pci is it happens to be a >> pluggable device rather than hardwired into a board model.) > > Usually, "-drive if=" options (apart from if=none) are only handled at > board creation time, and is not affected by -device. PCI devices use > "-device sdhci-pci,drive=xyz" to tie themselves to a -drive option. Yes. In other words: realize() methods aren't supposed to go on fishing expeditions for backends. They should rely on their backend properties. The disgusting way we implement if=scsi should serve as deterrent, not as example to emulate.