Received: by 2002:a05:7412:251c:b0:e2:908c:2ebd with SMTP id w28csp2384102rda; Wed, 25 Oct 2023 00:41:08 -0700 (PDT) X-Google-Smtp-Source: AGHT+IFJAaOsTL1LpX7C1dd9Zipq+VWTwlTppUmvmd3rPYKbzFTicP6gfTbhIcg94muoboa2Ak1e X-Received: by 2002:a05:6902:1083:b0:d9c:7b92:90b9 with SMTP id v3-20020a056902108300b00d9c7b9290b9mr16970831ybu.14.1698219668289; Wed, 25 Oct 2023 00:41:08 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1698219668; cv=pass; d=google.com; s=arc-20160816; b=kh/3oN9nkMAPeSPQ68RkTNRg7wMY1IkC4Z3b9IK8YhijMZwWSqslq/T52ae+uf8DR2 KtSvRnwy1lxb2wSJDcFBvcE1hSKjoQfSWd7E+Y3HXVYmEp4KVP9TnJWldmLpjuXpBwFK 8ChrSUIhbpanLIH/tOeazvAgRAdeVmwtRKbetJy/QP//utDmz7FW57mRXmkHKa16Gi2j 4go++5ZGnHJbn27ys1+rMW3CYjBIMyEzdSY1zvVUhicu0l44C/aJF8nXvDB1wicGVbZB 3ZteEq3/y55INB+hYHyspvgxg5sph2HuGW1/RSKr2RsRLCpb6SvtREKkdquMwuWRsffV I29g== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:mime-version:content-transfer-encoding :content-language:accept-language:in-reply-to:references:message-id :date:thread-index:thread-topic:subject:cc:to:from:dkim-signature; bh=0ivp/FOguYwEEq2B/Rp4D0Vhac2t3g/9rKxXED4N2qc=; fh=rzJXgqYMkpXQIFArmKrceTst9cIY3xeR6wJcDhf4/fY=; b=AIoFfn3sjSkoxNpUdU9Fj0J4yPXhQFdKDP5DKwq9vp1eJUn5thWFWtMdMK4eiI6T4w uBQ0kW0osLLExFhJBneJT9/GSttnKhCq4nxUrprYvl8WycjDA8Otsh5szg/e8KIL0TUs 9O5C7HDT1PCYuwr1t5zc6AQDhO8FC2deAoasqqQ9ahDZ47GlDkY92zFYgqllOsXzay3O rxBo9XT572vMWaHOpefOCgOlpSELNAO6ZLOb+IYPEs4lYVPX6ck6/kAexQz70dxUwcq4 VR9yTy61TBPO9BGf30rEgEonIhZA3/2qdm4ejJDQ90VmSWsojyohxcEiOx6iHUwvaFKi FCHQ== ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@intel.com header.s=Intel header.b="RxUmB0/2"; arc=pass (i=1 spf=pass spfdomain=intel.com dkim=pass dkdomain=intel.com dmarc=pass fromdomain=intel.com); spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:5 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=intel.com Return-Path: Received: from groat.vger.email (groat.vger.email. [2620:137:e000::3:5]) by mx.google.com with ESMTPS id r134-20020a25768c000000b00d9abc7dd745si10326433ybc.144.2023.10.25.00.41.07 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 25 Oct 2023 00:41:08 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:5 as permitted sender) client-ip=2620:137:e000::3:5; Authentication-Results: mx.google.com; dkim=pass header.i=@intel.com header.s=Intel header.b="RxUmB0/2"; arc=pass (i=1 spf=pass spfdomain=intel.com dkim=pass dkdomain=intel.com dmarc=pass fromdomain=intel.com); spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:5 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=intel.com Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by groat.vger.email (Postfix) with ESMTP id 30C818086506; Wed, 25 Oct 2023 00:40:36 -0700 (PDT) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.10 at groat.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S233137AbjJYHkQ (ORCPT + 99 others); Wed, 25 Oct 2023 03:40:16 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:38446 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S233023AbjJYHkL (ORCPT ); Wed, 25 Oct 2023 03:40:11 -0400 X-Greylist: delayed 112 seconds by postgrey-1.37 at lindbergh.monkeyblade.net; Wed, 25 Oct 2023 00:39:30 PDT Received: from mgamail.intel.com (mgamail.intel.com [198.175.65.10]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 46837326F; Wed, 25 Oct 2023 00:39:30 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1698219571; x=1729755571; h=from:to:cc:subject:date:message-id:references: in-reply-to:content-transfer-encoding:mime-version; bh=0ivp/FOguYwEEq2B/Rp4D0Vhac2t3g/9rKxXED4N2qc=; b=RxUmB0/2qV4HF4zss7mSoqkp3NYRwrGNHED889aaTBq9CFAEjkUeIt+O TTULl7f4paCgaXnoWcTSGA72JyQhTOoLoJ4xBU/GIPnhU0BUGdqmMz5A1 MGI380bgLIDc7RcnQrUGjPdiNQ5X699iKoG+d2ITVbGi+ooWvgk7b/YhQ jppkehOMs/nLasswrbOy6ccdWH5/UhHH7zk54Ibdf5djIaEZcgwF9uVIa ReqcMJOPHCTrNvp8+nZJREij85cvW1j2UBBOpNwRSJxeX3mxHAliw+ZNB SJI1u7O8CdvBoFuc2T73ZYXV34Ig2c8WKvW6MCWZ9D8uoyOEJefLgpago A==; X-IronPort-AV: E=McAfee;i="6600,9927,10873"; a="19015" X-IronPort-AV: E=Sophos;i="6.03,250,1694761200"; d="scan'208";a="19015" Received: from orsmga002.jf.intel.com ([10.7.209.21]) by orvoesa102.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 25 Oct 2023 00:37:37 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=McAfee;i="6600,9927,10873"; a="758787437" X-IronPort-AV: E=Sophos;i="6.03,250,1694761200"; d="scan'208";a="758787437" Received: from orsmsx602.amr.corp.intel.com ([10.22.229.15]) by orsmga002.jf.intel.com with ESMTP/TLS/AES256-GCM-SHA384; 25 Oct 2023 00:37:29 -0700 Received: from orsmsx602.amr.corp.intel.com (10.22.229.15) by ORSMSX602.amr.corp.intel.com (10.22.229.15) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2507.32; Wed, 25 Oct 2023 00:37:28 -0700 Received: from ORSEDG602.ED.cps.intel.com (10.7.248.7) by orsmsx602.amr.corp.intel.com (10.22.229.15) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2507.32 via Frontend Transport; Wed, 25 Oct 2023 00:37:28 -0700 Received: from NAM11-DM6-obe.outbound.protection.outlook.com (104.47.57.169) by edgegateway.intel.com (134.134.137.103) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.1.2507.32; Wed, 25 Oct 2023 00:37:28 -0700 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=YTZQ6B98uBCcxm22We7kXS1Rh42Ik2N4iuPIHMauHZ+059TRgBg6sMYcagBZU75Xd3+5MypPTxYZPcZtkkzaDTPaC4CxxSAhvzQNdlfD9lU7mMz5uPsIBPBhk6k8V9ipMZfq9b1uZcd7lwDkatKZhxycz77Z4ch6jE/XjE0M4v8tnNrYWVnGpXWGKgf0CLLU0O4m6mzxX9fVKF/CVsmxzndq9HaGPvYFdOVUz154lbWRILKgFdTwV0fRL5F2fYDRE+BYeMYmNrZ1N3amNQFZXzSblupHexq/6lc6t1MfQFCLpFGvDDd0slcKLPIF5aSvoRtuibPHqb22W0qS+x+6Rg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=0ivp/FOguYwEEq2B/Rp4D0Vhac2t3g/9rKxXED4N2qc=; b=ZuQZxRnHz3Rm3x/D2z8/a6wqSv54Cu+TfX3DC2qGvrl3+Wk1Ky0STthX5Id8DCfcllBRynOdW6+YXZsvyZtxAJj/YPHic2MHMxXldlNgOIk8v1P6mlyNEdq9x3CCrhq4tVNqC15u8UcIlHhaV2ls5m6Y/pxufPmuAO6HQ5b+ZnQCgeIVUv+/GZSjSLs3jxpw30cL27EsoaO8IdbrILW/txfa/1ybswrDqhs8KgDuBYffASDX3LbAs56Jg0cm/KLqHEbXv2qgf4eP98xunFNaO8eqHB18bf8pBSiNDbXFv5ak4CbgPE+YWywcn+HeJcx7uywOs9S8hdo9zhVbhWgzig== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=intel.com; dmarc=pass action=none header.from=intel.com; dkim=pass header.d=intel.com; arc=none Received: from BN9PR11MB5276.namprd11.prod.outlook.com (2603:10b6:408:135::18) by DS7PR11MB7740.namprd11.prod.outlook.com (2603:10b6:8:e0::11) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6933.19; Wed, 25 Oct 2023 07:37:25 +0000 Received: from BN9PR11MB5276.namprd11.prod.outlook.com ([fe80::e7a4:a757:2f2e:f96a]) by BN9PR11MB5276.namprd11.prod.outlook.com ([fe80::e7a4:a757:2f2e:f96a%3]) with mapi id 15.20.6907.032; Wed, 25 Oct 2023 07:37:25 +0000 From: "Tian, Kevin" To: "Liu, Yi L" , "joro@8bytes.org" , "alex.williamson@redhat.com" , "jgg@nvidia.com" , "robin.murphy@arm.com" , "baolu.lu@linux.intel.com" CC: "cohuck@redhat.com" , "eric.auger@redhat.com" , "nicolinc@nvidia.com" , "kvm@vger.kernel.org" , "mjrosato@linux.ibm.com" , "chao.p.peng@linux.intel.com" , "yi.y.sun@linux.intel.com" , "peterx@redhat.com" , "jasowang@redhat.com" , "shameerali.kolothum.thodi@huawei.com" , "lulu@redhat.com" , "suravee.suthikulpanit@amd.com" , "iommu@lists.linux.dev" , "linux-kernel@vger.kernel.org" , "linux-kselftest@vger.kernel.org" , "Duan, Zhenzhong" , "Martins, Joao" Subject: RE: [PATCH] iommu/vt-d: Enhance capability check for nested parent domain allocation Thread-Topic: [PATCH] iommu/vt-d: Enhance capability check for nested parent domain allocation Thread-Index: AQHaBorb53ixZf3YA0SmpGP4jnQvU7BaHwOQ Date: Wed, 25 Oct 2023 07:37:24 +0000 Message-ID: References: <20231024150011.44642-1-yi.l.liu@intel.com> In-Reply-To: <20231024150011.44642-1-yi.l.liu@intel.com> Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: authentication-results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=intel.com; x-ms-publictraffictype: Email x-ms-traffictypediagnostic: BN9PR11MB5276:EE_|DS7PR11MB7740:EE_ x-ms-office365-filtering-correlation-id: 1f52765d-294e-4f56-3b7f-08dbd52d3b6f x-ld-processed: 46c98d88-e344-4ed4-8496-4ed7712e255d,ExtAddr x-ms-exchange-senderadcheck: 1 x-ms-exchange-antispam-relay: 0 x-microsoft-antispam: BCL:0; x-microsoft-antispam-message-info: lvC551GvujgdykzK9uwVe5Nbmr6YWbhkgUX9auF5R461/bSSdjX4Jyz7UYcAwDEhw+oAOV+MXQV+VZZDvZBwlq5G/9buNDChMBHACDPKAR/nBkBQ5QrS8uH9uaq6UPaoobgNz7/Fo2iRRpwDoUG/0Gxdj65OcLs3WuTipOo35rovJtr2JGz3Z7olZTifnx16rW8sFVoQSgbrxKYld/1+7Ufmafhmo5z7cNHC28jFd90aqHgLZNnWCPYScx3VQEHlQWOVpmA4ihAqAugR77FctG5B/Yaywo5GlVL8aifg0bQ97EyLOMmLIWWusQckH2KAGRtPbdS9o8QbcSx4OHy03nyTQJ2F0u02G9LvFYgHHxWWAEoaCLsrYFWYn1ns1OxiOiEahpihOp5HSq+M+rN/LTJvrwazRfurlVQzIxzAtu3U62uk+8O8o2Nagz5j4sLReWXa+2IPopXZ4s3p8J5sQAxO6HC/xVbs/3XCdw1884M0jXIMzurT2ZH9CrnswVlN5pkp9ucHOHtDEJh8LiIwuIugjpi6yxwdcVnyAP6GqRTwRV2IITZGpqf51w9Dh35SI6RMqa1Edif215NUKRBJTjiA8k8MxC9Xs/PwWPLeEq07pwQ700xm52jSc+mLoZly x-forefront-antispam-report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:BN9PR11MB5276.namprd11.prod.outlook.com;PTR:;CAT:NONE;SFS:(13230031)(136003)(376002)(39860400002)(366004)(396003)(346002)(230922051799003)(64100799003)(1800799009)(451199024)(186009)(110136005)(26005)(478600001)(76116006)(86362001)(6506007)(316002)(7696005)(54906003)(64756008)(66476007)(66446008)(66946007)(66556008)(38100700002)(38070700009)(33656002)(52536014)(2906002)(4744005)(8676002)(122000001)(71200400001)(7416002)(4326008)(8936002)(82960400001)(5660300002)(41300700001)(55016003)(9686003);DIR:OUT;SFP:1102; x-ms-exchange-antispam-messagedata-chunkcount: 1 x-ms-exchange-antispam-messagedata-0: =?us-ascii?Q?Guz/1qPVd7iVAstK0iky6U6g/eW8tFgmF6LhNRc+GhoXuuDr0PnmzAxCi5T2?= =?us-ascii?Q?UOh5STHAPVVSPvj2MshQJDcFDGL0wpu9tST/lQBQw9qIkOcuIf/wj/Vab3V4?= =?us-ascii?Q?AEDxfF60YINoBg3XC/sQhwXVmtd9QPfy6KnAg2JlkS/R+365Vg07ee3Wf04M?= =?us-ascii?Q?kgI9RXNBgnJoyx8B/REdoHgdruiA7meTgcb7q95zkufNbY3tfRW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ecYVjWrPC+xmGx4MMg/l/9gDU5jL8tm?= =?us-ascii?Q?li3mjJlj1J9hYz6X8Kz5kbpsllt1lQHiaoTYemKjA81JaVC2uXSO21aIJWxx?= =?us-ascii?Q?pCVd+zSvjMbsx1FYLi03d9r3JuUKnkcj52bBpKr+E2ABrKsL0E//VPsNeF7W?= =?us-ascii?Q?jGLtoqOTPKSk9V7t3OhiXcBSmnrXldRv0joWNnKyqkg0Ym7DJ7IL95uL+W4E?= =?us-ascii?Q?O23ZAHWwZ5h1WZIyoTgKfA+Yqv25ZYQPgsm3Vj8yx9wyAcJOxGQbEfdmEuqh?= =?us-ascii?Q?/iY0Nzc2oVfyruCV1wNjx9iFrPPzjxeqMUg0Q40TqPTCpYMP8NXU4rXBCJi9?= =?us-ascii?Q?9JGtNXI66TZek7rcBb/+l8J+m9ilSFWBsBuLTqocbLi3nETGhFsxryB6dcnf?= =?us-ascii?Q?/9KtPBylsj22Es1v+AarR67BSah6zfnJkYCevaS5BiBFYuX7r6PDS0DfI/t5?= =?us-ascii?Q?GP99OK+KcvBjLugddflvKKbkVhjh9yVpn1bbNdTL?= Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-AuthSource: BN9PR11MB5276.namprd11.prod.outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: 1f52765d-294e-4f56-3b7f-08dbd52d3b6f X-MS-Exchange-CrossTenant-originalarrivaltime: 25 Oct 2023 07:37:24.9940 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: 46c98d88-e344-4ed4-8496-4ed7712e255d X-MS-Exchange-CrossTenant-mailboxtype: HOSTED X-MS-Exchange-CrossTenant-userprincipalname: WTEq87QHAqd7Jpds8ysv4+oCBaM3oEh4x7N3Lg941UPXIsgOPkuieLF3XaUPquex6/QReH/A1Q5J8KW8xqecOA== X-MS-Exchange-Transport-CrossTenantHeadersStamped: DS7PR11MB7740 X-OriginatorOrg: intel.com X-Spam-Status: No, score=-0.9 required=5.0 tests=DKIMWL_WL_HIGH,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on groat.vger.email Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (groat.vger.email [0.0.0.0]); Wed, 25 Oct 2023 00:40:36 -0700 (PDT) > From: Liu, Yi L > Sent: Tuesday, October 24, 2023 11:00 PM >=20 > This adds the scalable mode check before allocating the nested parent > domain > as checking nested capability is not enough. User may turn off scalable m= ode > which also means no nested support even if the hardware supports it. >=20 > Fixes: c97d1b20d383 ("iommu/vt-d: Add domain_alloc_user op") > Signed-off-by: Yi Liu Reviewed-by: Kevin Tian