From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:44152) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1duvJH-0003Dq-8L for qemu-devel@nongnu.org; Thu, 21 Sep 2017 02:50:08 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1duvJC-00080j-92 for qemu-devel@nongnu.org; Thu, 21 Sep 2017 02:50:07 -0400 Received: from mx1.redhat.com ([209.132.183.28]:33472) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1duvJC-0007zY-35 for qemu-devel@nongnu.org; Thu, 21 Sep 2017 02:50:02 -0400 Message-ID: <1505976596.7353.0.camel@redhat.com> From: Gerd Hoffmann Date: Thu, 21 Sep 2017 08:49:56 +0200 In-Reply-To: <20170920145025.19403-1-david@redhat.com> References: <20170920145025.19403-1-david@redhat.com> Content-Type: text/plain; charset="UTF-8" Mime-Version: 1.0 Content-Transfer-Encoding: quoted-printable Subject: Re: [Qemu-devel] [PATCH v1] kvm: drop wrong assertion creating problems with pflash List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: David Hildenbrand , qemu-devel@nongnu.org Cc: Paolo Bonzini , Radim =?UTF-8?Q?Kr=C4=8Dm=C3=A1=C5=99?= , kvm@vger.kernel.org On Wed, 2017-09-20 at 16:50 +0200, David Hildenbrand wrote: > pflash toggles mr->romd_mode. So this assert does not always hold. >=20 > 1) a device was added with !mr->romd_mode, therefore effectively not > =C2=A0=C2=A0=C2=A0creating a kvm slot as we want to trap every access (= add =3D false). > 2) mr->romd_mode was toggled on before remove it. There is now > =C2=A0=C2=A0=C2=A0actually no slot to remove and the asser is wrong. >=20 > So let's just drop the assert. Works without any obvious bad side effects. Tested-by: Gerd Hoffmann cheers, Gerd