From nobody Mon May 6 13:32:53 2024 Delivered-To: importer@patchew.org Received-SPF: temperror (zoho.com: Error in retrieving data from DNS) client-ip=208.118.235.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Authentication-Results: mx.zohomail.com; spf=temperror (zoho.com: Error in retrieving data from DNS) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org Return-Path: Received: from lists.gnu.org (208.118.235.17 [208.118.235.17]) by mx.zohomail.com with SMTPS id 1510241684840662.4421376325278; Thu, 9 Nov 2017 07:34:44 -0800 (PST) Received: from localhost ([::1]:37521 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1eCoqd-0006U7-RD for importer@patchew.org; Thu, 09 Nov 2017 10:34:31 -0500 Received: from eggs.gnu.org ([2001:4830:134:3::10]:46367) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1eCooW-0005GW-Jn for qemu-devel@nongnu.org; Thu, 09 Nov 2017 10:32:21 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1eCooQ-00034c-QT for qemu-devel@nongnu.org; Thu, 09 Nov 2017 10:32:20 -0500 Received: from mx1.redhat.com ([209.132.183.28]:56678) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1eCooQ-00034E-KA; Thu, 09 Nov 2017 10:32:14 -0500 Received: from smtp.corp.redhat.com (int-mx06.intmail.prod.int.phx2.redhat.com [10.5.11.16]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id C5A237F3F4; Thu, 9 Nov 2017 15:32:13 +0000 (UTC) Received: from localhost (ovpn-117-99.ams2.redhat.com [10.36.117.99]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 99D336375E; Thu, 9 Nov 2017 15:32:09 +0000 (UTC) From: Cornelia Huck To: peter.maydell@linaro.org Date: Thu, 9 Nov 2017 16:32:03 +0100 Message-Id: <20171109153204.26436-2-cohuck@redhat.com> In-Reply-To: <20171109153204.26436-1-cohuck@redhat.com> References: <20171109153204.26436-1-cohuck@redhat.com> X-Scanned-By: MIMEDefang 2.79 on 10.5.11.16 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.25]); Thu, 09 Nov 2017 15:32:13 +0000 (UTC) X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] [fuzzy] X-Received-From: 209.132.183.28 Subject: [Qemu-devel] [PULL for-2.11 1/2] s390x/pci: let pci devices start in configured mode X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: thuth@redhat.com, david@redhat.com, Cornelia Huck , agraf@suse.de, qemu-devel@nongnu.org, borntraeger@de.ibm.com, qemu-s390x@nongnu.org, rth@twiddle.net Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: "Qemu-devel" X-ZohoMail: RSF_6 Z_629925259 SPT_0 Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" From: Christian Borntraeger Currently, to enable a pci device in the guest, the user has to issue echo 1 > /sys/bus/pci/slots/00000000/power. This is not what people expect. On an LPAR, the user can put a PCI device in configured or deconfigured state via IOCDS. The "start in deconfigured state" can be used for "sharing" a pci function across LPARs. This is not what we are going to use in KVM, so always start configured. Signed-off-by: Christian Borntraeger Acked-by: Yi Min Zhao Reviewed-by: Pierre Morel Message-Id: <20171107175455.73793-2-borntraeger@de.ibm.com> Signed-off-by: Cornelia Huck --- hw/s390x/s390-pci-bus.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/hw/s390x/s390-pci-bus.c b/hw/s390x/s390-pci-bus.c index e7a58e81f7..2b1e1409bf 100644 --- a/hw/s390x/s390-pci-bus.c +++ b/hw/s390x/s390-pci-bus.c @@ -715,7 +715,7 @@ static void s390_pcihost_hot_plug(HotplugHandler *hotpl= ug_dev, pbdev->pdev =3D pdev; pbdev->iommu =3D s390_pci_get_iommu(s, pdev->bus, pdev->devfn); pbdev->iommu->pbdev =3D pbdev; - pbdev->state =3D ZPCI_FS_STANDBY; + pbdev->state =3D ZPCI_FS_DISABLED; =20 if (s390_pci_msix_init(pbdev)) { error_setg(errp, "MSI-X support is mandatory " --=20 2.13.6 From nobody Mon May 6 13:32:53 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zoho.com: domain of gnu.org designates 208.118.235.17 as permitted sender) client-ip=208.118.235.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Authentication-Results: mx.zohomail.com; spf=pass (zoho.com: domain of gnu.org designates 208.118.235.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org Return-Path: Received: from lists.gnu.org (208.118.235.17 [208.118.235.17]) by mx.zohomail.com with SMTPS id 1510241792551703.3989297541341; Thu, 9 Nov 2017 07:36:32 -0800 (PST) Received: from localhost ([::1]:37533 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1eCosO-000875-7f for importer@patchew.org; Thu, 09 Nov 2017 10:36:20 -0500 Received: from eggs.gnu.org ([2001:4830:134:3::10]:46346) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1eCooU-0005GK-BO for qemu-devel@nongnu.org; Thu, 09 Nov 2017 10:32:22 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1eCooT-00035x-07 for qemu-devel@nongnu.org; Thu, 09 Nov 2017 10:32:18 -0500 Received: from mx1.redhat.com ([209.132.183.28]:49262) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1eCooS-00035P-Qv; Thu, 09 Nov 2017 10:32:16 -0500 Received: from smtp.corp.redhat.com (int-mx03.intmail.prod.int.phx2.redhat.com [10.5.11.13]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id E482D2CE94F; Thu, 9 Nov 2017 15:32:15 +0000 (UTC) Received: from localhost (ovpn-117-99.ams2.redhat.com [10.36.117.99]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 813C46F971; Thu, 9 Nov 2017 15:32:15 +0000 (UTC) From: Cornelia Huck To: peter.maydell@linaro.org Date: Thu, 9 Nov 2017 16:32:04 +0100 Message-Id: <20171109153204.26436-3-cohuck@redhat.com> In-Reply-To: <20171109153204.26436-1-cohuck@redhat.com> References: <20171109153204.26436-1-cohuck@redhat.com> X-Scanned-By: MIMEDefang 2.79 on 10.5.11.13 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.29]); Thu, 09 Nov 2017 15:32:15 +0000 (UTC) X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] [fuzzy] X-Received-From: 209.132.183.28 Subject: [Qemu-devel] [PULL for-2.11 2/2] target/s390x: Finish implementing RISBGN X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: thuth@redhat.com, david@redhat.com, Cornelia Huck , Richard Henderson , agraf@suse.de, qemu-devel@nongnu.org, borntraeger@de.ibm.com, qemu-s390x@nongnu.org, rth@twiddle.net Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: "Qemu-devel" X-ZohoMail: RSF_0 Z_629925259 SPT_0 Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" From: Richard Henderson We added the entry to insn-data.def, but failed to update op_risbg to match. No need to special-case the imask inversion, since that is already ~0 for RISBG (and now RISBGN). Fixes: 375ee58bedcda359011fe7fa99e0647f66f9ffa0 Fixes: https://bugs.launchpad.net/qemu/+bug/1701798 (s390x part) Signed-off-by: Richard Henderson Message-Id: <20171107145546.767-1-richard.henderson@linaro.org> Reviewed-by: Thomas Huth Tested-by: Peter Maydell Signed-off-by: Cornelia Huck --- target/s390x/translate.c | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) diff --git a/target/s390x/translate.c b/target/s390x/translate.c index dee72a787d..85d0a6c3af 100644 --- a/target/s390x/translate.c +++ b/target/s390x/translate.c @@ -3432,6 +3432,7 @@ static ExitStatus op_risbg(DisasContext *s, DisasOps = *o) /* Adjust the arguments for the specific insn. */ switch (s->fields->op2) { case 0x55: /* risbg */ + case 0x59: /* risbgn */ i3 &=3D 63; i4 &=3D 63; pmask =3D ~0; @@ -3447,7 +3448,7 @@ static ExitStatus op_risbg(DisasContext *s, DisasOps = *o) pmask =3D 0x00000000ffffffffull; break; default: - abort(); + g_assert_not_reached(); } =20 /* MASK is the set of bits to be inserted from R2. @@ -3464,11 +3465,7 @@ static ExitStatus op_risbg(DisasContext *s, DisasOps= *o) insns, we need to keep the other half of the register. */ imask =3D ~mask | ~pmask; if (do_zero) { - if (s->fields->op2 =3D=3D 0x55) { - imask =3D 0; - } else { - imask =3D ~pmask; - } + imask =3D ~pmask; } =20 len =3D i4 - i3 + 1; --=20 2.13.6