From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id 96646A00C3; Thu, 12 May 2022 15:55:10 +0200 (CEST) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 6ACFD40E64; Thu, 12 May 2022 15:55:10 +0200 (CEST) Received: from mga07.intel.com (mga07.intel.com [134.134.136.100]) by mails.dpdk.org (Postfix) with ESMTP id A45DC40DDD for ; Thu, 12 May 2022 15:55:08 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1652363709; x=1683899709; h=from:to:cc:subject:date:message-id:references: in-reply-to:content-transfer-encoding:mime-version; bh=0uKY1MWC3Am+O6osVF0gt7piBc54V/5FtNNIw+XXi+M=; b=iLK180MXK3m5dItJIu56/GBBPMggnQ8hwS/UmnMoAX2w+3sF4qF76Kln XSF/1t4PsyLc9pjZ6srEKHVpuuSpQ8Aoqks2IW2gGgOG9BEhtSf8X3/ku 3S1YRXj1y7Y3n2D108TR5imzaIXBWmgIzXjfRHfO0tiI1IvKusbKznJSt mY9WAcuWJjnP38QjbzL4W3u7Yc3V3+XwOV+gs3Tbo4TeaOxv1agedbVM4 3IlIWZF8LpPI5AtdsHnLC0r5sGLfA/drvC1zEvOhe6UnTpZccZ2zpSNet 6GZr+2KbX7Iq68f3eUH/8D3gNaa7EGCq6tAYRd4buCPFXTaXbAMOEVqn4 g==; X-IronPort-AV: E=McAfee;i="6400,9594,10344"; a="333043540" X-IronPort-AV: E=Sophos;i="5.91,219,1647327600"; d="scan'208";a="333043540" Received: from fmsmga005.fm.intel.com ([10.253.24.32]) by orsmga105.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 12 May 2022 06:55:07 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.91,220,1647327600"; d="scan'208";a="895798631" Received: from fmsmsx606.amr.corp.intel.com ([10.18.126.86]) by fmsmga005.fm.intel.com with ESMTP; 12 May 2022 06:55:07 -0700 Received: from fmsmsx612.amr.corp.intel.com (10.18.126.92) by fmsmsx606.amr.corp.intel.com (10.18.126.86) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2308.27; Thu, 12 May 2022 06:55:06 -0700 Received: from fmsedg601.ED.cps.intel.com (10.1.192.135) by fmsmsx612.amr.corp.intel.com (10.18.126.92) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2308.27 via Frontend Transport; Thu, 12 May 2022 06:55:06 -0700 Received: from NAM10-MW2-obe.outbound.protection.outlook.com (104.47.55.108) by edgegateway.intel.com (192.55.55.70) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.1.2308.27; Thu, 12 May 2022 06:55:06 -0700 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=m7l45WIAHnLAJ7XzufTc1iZ8UDTb5w3VoXfZk2V6rgG5lhkLLo5Z5hPTFlM5UZgyoILi5KosMV14tgejgO0X/44eKF8VAf76B7XLxTtQVHnhAtMD6an+rItI9xJWUkv/IRUo6AsdzjsE4gfCOSz42AeBYLpnD10Lrn8pT1TApBhWDhUFFVg1pXRMwZh0EYQ2vJt2IjdDwVHwMTCimKAgY/Kct9QjldBWULFwBFYF0EylQw0j/azE+F+JVzXX5L153ZJ4X9ljpBSxPqR25PwadoOpLpF+/WLRGIrLhesQ723kM8eJFlksZHKh1C3iEalVam+YhkM8lbLl3/mJ/+ONkA== 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=kpkAp0iFX9i61u9XiprLuhK7WcfUhFf8+da6RmK3RZE=; b=RdlqEHdF6G4Tt3Cpv7sBezPTWWbuMaaX5Tsvjgnm1srwPYj+2mS9H6dQIgslIyj7JQ+6MgMag7FCgAYU/+5V1elxtqdxtstPfcSWXOYS0FhAAIO6GcwHJE008pIOtQ/J9h0N3kpIkeLgoe9+IFKR+crwtmeby6kauQgEdyG9Ms5qjcJzfhqErkc8fbIS6ju6UNqMDyEAHtTuoJaEWxxg7CwlbXE5e0jfjCVJJhjnPTj5mEZPNEj9eJvRj7MtVJfNiBQnP1NiWV/2z306xV9M2bIEokW+LcQzJI/pfolrFLg3HTHZnPS/5dd8HRnV4Fhn38y7BQGBVQvorDU3hVgsmQ== 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 SN6PR11MB3504.namprd11.prod.outlook.com (2603:10b6:805:d0::17) by BN6PR11MB1891.namprd11.prod.outlook.com (2603:10b6:404:107::10) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5227.22; Thu, 12 May 2022 13:55:04 +0000 Received: from SN6PR11MB3504.namprd11.prod.outlook.com ([fe80::2c8f:42df:ed85:99e5]) by SN6PR11MB3504.namprd11.prod.outlook.com ([fe80::2c8f:42df:ed85:99e5%4]) with mapi id 15.20.5227.023; Thu, 12 May 2022 13:55:04 +0000 From: "Xia, Chenbo" To: "Pei, Andy" , "dev@dpdk.org" CC: "maxime.coquelin@redhat.com" , "Cao, Gang" , "Liu, Changpeng" Subject: RE: [PATCH v7 13/18] vdpa/ifc: read virtio max queues from hardware Thread-Topic: [PATCH v7 13/18] vdpa/ifc: read virtio max queues from hardware Thread-Index: AQHYWheH4P4CuvF9+Eqr/cN2tbw4dq0bW2eQ Date: Thu, 12 May 2022 13:55:04 +0000 Message-ID: References: <1643093258-47258-2-git-send-email-andy.pei@intel.com> <1651048206-282372-1-git-send-email-andy.pei@intel.com> <1651048206-282372-14-git-send-email-andy.pei@intel.com> In-Reply-To: <1651048206-282372-14-git-send-email-andy.pei@intel.com> Accept-Language: en-US, zh-CN 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-office365-filtering-correlation-id: 1812da64-3df3-47ea-217c-08da341f0451 x-ms-traffictypediagnostic: BN6PR11MB1891:EE_ x-ld-processed: 46c98d88-e344-4ed4-8496-4ed7712e255d,ExtAddr x-microsoft-antispam-prvs: x-ms-exchange-senderadcheck: 1 x-ms-exchange-antispam-relay: 0 x-microsoft-antispam: BCL:0; x-microsoft-antispam-message-info: zCFjOgyaPOE4CMCtPtmsb44vQ/414qbjvgv8mj/zBolWRj75/457SuAOGjRdKf9LTuiIIKqsHY3RY4VZTeqPeLsfEZIhETalCMxLvFcM+Ym/7mQpdDpA9R0KcT2vrhAzEMBj9ztbuZ9PhK2XNt9k2E5LdIBLIl4c80nOnPmGE2lLYeUzzM0T+G3QWQa/WOro9vC91coqZjQohW3BUbLVW1lGD3pTBkY8sQskqfjA3kAN93VT+2JiBSHcNve7uaKi2EPIjsNaqsTz2M0t1s9/k/nv+t3RV1i+2rv/mVHDSh4Ef1OA2eEh8lxJb4Mu0HXV7BG/RRtzVquQhKeK+Iy6oHncDexPhS2lEsqiR6OEfH4PX/jVr8tRnW8cDAh3dXQQJ8oxMyxT8lFkT0Vet3ndZ9dMcNBlRyDyuROKDuTfk/x2ZbIRC09qgT3+GyQLUU5jvQNmAcv4XjNhL4g104W9PEYXIzLQ+b/yhlZQEojNVF9nSzkn0Il3/IVnpaVc6O83XoMtAOUj56O9Ulv+OI1or8855uMMGI4hld6Qy7N9uiWWwBTOmHVtCtfpyR0panIZAj7u8ky+Ki6dI5rW+dzb966JFjUAT11oXggti+NthcnEgkSqWE3SuG8KP9n8T72xnT3uRObtOxb7Byg/nlgbHjveiVhCqNpZcDSgM/lBZglDMbdPhwd+HdHsZcuPdRuPy4cRUJx17CdHJu7k/m7kYg== x-forefront-antispam-report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:SN6PR11MB3504.namprd11.prod.outlook.com; PTR:; CAT:NONE; SFS:(13230001)(366004)(8676002)(8936002)(66946007)(66556008)(66476007)(66446008)(76116006)(52536014)(54906003)(64756008)(316002)(38100700002)(86362001)(4326008)(107886003)(9686003)(53546011)(82960400001)(122000001)(7696005)(6506007)(508600001)(26005)(71200400001)(2906002)(33656002)(110136005)(38070700005)(55016003)(83380400001)(5660300002)(186003); DIR:OUT; SFP:1102; x-ms-exchange-antispam-messagedata-chunkcount: 1 x-ms-exchange-antispam-messagedata-0: =?us-ascii?Q?yjFsjJPVLl8xkJrXcImCuIL0MLXpC0m8NNfImEzTb1WFgI/rRLGNGIRZcBOL?= =?us-ascii?Q?RTnZ2MP30K/9weDCKDvjpyIQxfAqvzX576awUsL6RZJ5u6/b0mqEELvUOiH3?= =?us-ascii?Q?HQcAE/4sOHTDUhHwHs8E+fM2scCl3cGaoDmt4L3NsTuKt38D/95v9RC1mb3g?= =?us-ascii?Q?WUv1OU+HWWdT7LIRi4sxcEA6ZOr3fvEsyR9uR4vvp+5aha2qB2yWodfkIXle?= =?us-ascii?Q?UZLMk1YXdoF9+lBf/5uYukeC5TkowevzZbaeEwFCzbnSvXR7CbeOovXDHkP4?= =?us-ascii?Q?N/Y6hU0kgNHMMqt1wXrgF2H9iz/4ED71yJkt/DMxafoIBn54zqP3XQGC5RP0?= =?us-ascii?Q?SDt76N41gv3t7ndDMFPqa9FyaB34vEoyTJChcFfkQdkS73mWPvEXCJKgzZ49?= =?us-ascii?Q?OXUfuai3WAsSXL7+EMoh9rsKZsE9sPACj7UIvEOQiArG/CQc9J8ng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Ef9m0vOf2ofQxjxqrixzLKaLOfdrI6vZEQ7?= =?us-ascii?Q?OwSzBEpaXLp/JTKHJ0gxQyy1oofntuu163qGb+sI0itWvsQSPzgD6M84x/Ld?= =?us-ascii?Q?aJdTma0xPw6baek9OeCG07bzZodorRdEBkQJfgGyZYrGVEUnyB0odus7PQko?= =?us-ascii?Q?xY0boBKYTa9xsClkBWUyULPvkVWhXakG+eElNGEwKhYOjOVjkgS7YnUIsvd/?= =?us-ascii?Q?+ItrGztYUzOR3CajBl6WR2WDfLKT2RHtr4uJFNgy4vnIDDjsmN0VqH3n9+fd?= =?us-ascii?Q?ey53jsfEvI61K3jdfX0VhlL0f6yvqge9+se2SAAUrtn1xWcOJERjUMve/bLp?= =?us-ascii?Q?WUg9Gx7hgHo2qdwPWp63ISVYyicvZs6dxDDEH8S5TFlHujJ82HzJxyr6Wll8?= =?us-ascii?Q?3E2I7FzPtw=3D=3D?= 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: SN6PR11MB3504.namprd11.prod.outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: 1812da64-3df3-47ea-217c-08da341f0451 X-MS-Exchange-CrossTenant-originalarrivaltime: 12 May 2022 13:55:04.7090 (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: wvhfZyOfiRVX/4qAk5MpZGscbjcE2F+YGXpyl/+TFF/UtZvVF/+//6SH4D8wB02sCTwKEX4oic/R3MDGUwWaAQ== X-MS-Exchange-Transport-CrossTenantHeadersStamped: BN6PR11MB1891 X-OriginatorOrg: intel.com X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org > -----Original Message----- > From: Pei, Andy > Sent: Wednesday, April 27, 2022 4:30 PM > To: dev@dpdk.org > Cc: Xia, Chenbo ; maxime.coquelin@redhat.com; Cao, > Gang ; Liu, Changpeng > Subject: [PATCH v7 13/18] vdpa/ifc: read virtio max queues from hardware >=20 > Original code max_queues is set to IFCVF_MAX_QUEUES. > New code max_queues is the min of IFCVF_MAX_QUEUES and hardware num_queue= s. >=20 > Signed-off-by: Andy Pei > --- > drivers/vdpa/ifc/ifcvf_vdpa.c | 4 ++++ > 1 file changed, 4 insertions(+) >=20 > diff --git a/drivers/vdpa/ifc/ifcvf_vdpa.c b/drivers/vdpa/ifc/ifcvf_vdpa.= c > index 4060a44..5a8cf1c 100644 > --- a/drivers/vdpa/ifc/ifcvf_vdpa.c > +++ b/drivers/vdpa/ifc/ifcvf_vdpa.c > @@ -1457,6 +1457,10 @@ struct rte_vdpa_dev_info dev_info[] =3D { > internal->hw.blk_cfg->geometry.sectors); > DRV_LOG(INFO, "num_queues: 0x%08x", > internal->hw.blk_cfg->num_queues); > + > + /* reset max_queue here, to minimum modification */ > + internal->max_queues =3D RTE_MIN(IFCVF_MAX_QUEUES, > + internal->hw.blk_cfg->num_queues); MQ is not supported now in this driver, should we make this change later? Thanks, Chenbo > } >=20 > list->internal =3D internal; > -- > 1.8.3.1