Received: from eggs.gnu.org ([2001:4830:134:3::10]:43780) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Ya9CV-0005pp-T8 for qemu-devel@nongnu.org; Mon, 23 Mar 2015 16:43:56 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Ya9CS-00069O-Iz for qemu-devel@nongnu.org; Mon, 23 Mar 2015 16:43:55 -0400 Received: from mx1.redhat.com ([209.132.183.28]:44011) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Ya9CS-000698-Ac for qemu-devel@nongnu.org; Mon, 23 Mar 2015 16:43:52 -0400 From: Markus Armbruster References: <1427137790-27265-1-git-send-email-armbru@redhat.com> <1427137790-27265-3-git-send-email-armbru@redhat.com> Date: Mon, 23 Mar 2015 21:43:46 +0100 In-Reply-To: (Peter Maydell's message of "Mon, 23 Mar 2015 19:13:54 +0000") Message-ID: <87h9tbfnr1.fsf@blackfin.pond.sub.org> MIME-Version: 1.0 Content-Type: text/plain Subject: Re: [Qemu-devel] [PATCH for-2.3 2/3] sdhci: Make device "sdhci-pci" unavailable with -device List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Peter Maydell Cc: Paolo Bonzini , Peter Crosthwaite , "Edgar E. Iglesias" , Michael Walle , QEMU Developers Peter Maydell writes: > On 23 March 2015 at 19:09, Markus Armbruster wrote: >> Due to misuse of drive_get_next(), -device sdhci can connect to a >> -drive if=sd,... If you can't see what's wrong here, check out the >> FIXME in sdhci_initfn() and the commit that added it. >> >> We can't fix this in time for the release, but since the device is new >> in 2.3, we can disable it before this mistake becomes ABI: set >> cannot_instantiate_with_device_add_yet. >> >> Signed-off-by: Markus Armbruster >> --- >> hw/sd/sdhci.c | 2 ++ >> 1 file changed, 2 insertions(+) >> >> diff --git a/hw/sd/sdhci.c b/hw/sd/sdhci.c >> index f056c52..ab13505 100644 >> --- a/hw/sd/sdhci.c >> +++ b/hw/sd/sdhci.c >> @@ -1254,6 +1254,8 @@ static void sdhci_pci_class_init(ObjectClass *klass, void *data) >> set_bit(DEVICE_CATEGORY_STORAGE, dc->categories); >> dc->vmsd = &sdhci_vmstate; >> dc->props = sdhci_properties; >> + /* Reason: realize() method uses drive_get_next() */ >> + dc->cannot_instantiate_with_device_add_yet = true; >> } > > This is basically saying "this device won't work in this > release", right? Yes, because with this patch, you can use it only from code, and code isn't using it right now.