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 8E730A00C4; Thu, 29 Sep 2022 10:32:56 +0200 (CEST) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 4751A40E5A; Thu, 29 Sep 2022 10:32:56 +0200 (CEST) Received: from mga01.intel.com (mga01.intel.com [192.55.52.88]) by mails.dpdk.org (Postfix) with ESMTP id D712040694 for ; Thu, 29 Sep 2022 10:32:53 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1664440374; x=1695976374; h=from:to:cc:subject:date:message-id:references: in-reply-to:content-transfer-encoding:mime-version; bh=+GK3+0EHOBebbapGfSsjgLlvTx7zwtbEcmJYZ2YxPxQ=; b=A81G8bp2hPWJPu2hlAcjNUCD3VqBsXp/erIUcU0vWpIAIBg33PHEaq2/ uTEoOjIGavp/QwvB8k9O1EVTeWc0QlezO4p/L3MFxsf2o8/mjo/sb0C38 NG7+UdnlKXHkanSfByAjXOjf51mhPWD9OHfdr18F1Efn5nVxtTeyFi9Dc 7H4A/tEk+pEqy7kbyJ6g7QkVYMTaI+0CEXExj6tEF1KeZiBWGiyjxT5KZ bPetiv92oUH0MPvHAw9XSN9Pm/Q2GhVCMaJvUsg/0sSK2HjWfW8VL3Lro FiCXJ89XiS3elVvoaO3mcMUThhmwk046AHcfrMkgPfx7xX0UjtajFz2Oa Q==; X-IronPort-AV: E=McAfee;i="6500,9779,10484"; a="328206597" X-IronPort-AV: E=Sophos;i="5.93,354,1654585200"; d="scan'208";a="328206597" Received: from fmsmga006.fm.intel.com ([10.253.24.20]) by fmsmga101.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 29 Sep 2022 01:32:53 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=McAfee;i="6500,9779,10484"; a="867301674" X-IronPort-AV: E=Sophos;i="5.93,354,1654585200"; d="scan'208";a="867301674" Received: from orsmsx603.amr.corp.intel.com ([10.22.229.16]) by fmsmga006.fm.intel.com with ESMTP; 29 Sep 2022 01:32:52 -0700 Received: from orsmsx609.amr.corp.intel.com (10.22.229.22) by ORSMSX603.amr.corp.intel.com (10.22.229.16) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2375.31; Thu, 29 Sep 2022 01:32:51 -0700 Received: from ORSEDG601.ED.cps.intel.com (10.7.248.6) by orsmsx609.amr.corp.intel.com (10.22.229.22) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2375.31 via Frontend Transport; Thu, 29 Sep 2022 01:32:51 -0700 Received: from NAM10-MW2-obe.outbound.protection.outlook.com (104.47.55.104) by edgegateway.intel.com (134.134.137.102) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.1.2375.31; Thu, 29 Sep 2022 01:32:51 -0700 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=dT1Ax7VAmLxT9ZOxcsdFlz/hcSRzlWUMwjdC1/eHvkgggzG0GN6O+MLGW7dlLwF6xvhTDCeIeyzurN0frfTQRcgZzib8LeBaUQFjr9vobK1CW4xlG5pFOzk/chFUBvzMK+zu/iv1yV3+nMlQUat+Ie2bqaQoRbGBeeB5YHI62bQ5+Oh9pundWiE8pVqsTdsIqpGlf82OTDwJalDMBQiEGkxGhJhhT8SswNNlgX1Jy8z9rf39k+oftyfwIilOa76OnTaRZiIxmv9pkhHw+Xyz3qHEIjXgwtxUPxmr3QCvXaLJ6xiWUKdNLrUw0c5uC1ibVSbg7eH9OvzFlf0g8E5Yjg== 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=odMo5qUfep2m2gj+ATLD8ICEMR+IPjwPV5Lgi4Ecu9I=; b=h7u6s80f3gN8tSSSQg0X1rJcIbL4Z3gAdgH+/upj0TVHzEC2M8HjCOsilLa+TQICrUGCvM0M0HDcHJA7KmxHLO+QuDMgiRTn+TsijrmQllu8nkHhmqb221YCedaBl4q5XYDu4hSqErhPPFjR3P2ExS9NSOVxXcTG7FfdYyoNSB+cQCr8I/Z2PF9LF8l92343Bz8m6MfvntunMC5zC33x5CN49HAm7KDyEu12EYC7oycbg6iaReeF2MZs4GUOO7iRRJNFfwMWVnL+A7M4p+ZPlqG9r/04Z2Kgc2hLCjZcnlqZB9h7cpAfubYwzRrxMUzlsB+r3QXRsHvVy144qDsopg== 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 SA2PR11MB4810.namprd11.prod.outlook.com (2603:10b6:806:116::15) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5676.20; Thu, 29 Sep 2022 08:32:45 +0000 Received: from SN6PR11MB3504.namprd11.prod.outlook.com ([fe80::39bf:57b1:4824:d40d]) by SN6PR11MB3504.namprd11.prod.outlook.com ([fe80::39bf:57b1:4824:d40d%6]) with mapi id 15.20.5676.017; Thu, 29 Sep 2022 08:32:45 +0000 From: "Xia, Chenbo" To: David Marchand , "dev@dpdk.org" CC: Maxime Coquelin , Ray Kinsella Subject: RE: [PATCH] vhost: remove deprecated helpers Thread-Topic: [PATCH] vhost: remove deprecated helpers Thread-Index: AQHY0mWLlLMdpJxy706Bg8TtcJlXQ630RLCAgAHBbzA= Date: Thu, 29 Sep 2022 08:32:45 +0000 Message-ID: References: <20220927113608.3015654-1-david.marchand@redhat.com> In-Reply-To: Accept-Language: en-US, zh-CN Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: dlp-product: dlpe-windows dlp-reaction: no-action dlp-version: 11.6.500.17 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: SN6PR11MB3504:EE_|SA2PR11MB4810:EE_ x-ms-office365-filtering-correlation-id: d1a4a5bf-93a8-4470-4b8d-08daa1f52ee5 x-ms-exchange-senderadcheck: 1 x-ms-exchange-antispam-relay: 0 x-microsoft-antispam: BCL:0; x-microsoft-antispam-message-info: IhZEVlDMNVkzIha1KQlrGv2AtWpGXZLQIojDq6z7gii5tzLumugTWg0OG4wrKFSuBPOaRS060fnJnDjm/B0WZXDulGCQTTozUVGhdnpUu52bPSu+3KWNqRcuy78x1RKY7GQBbndWhip1J3wnbpd2aqFIn2LR4UvXCSQLtK4QdakKM8FJVL40WmLfVuvgMGDfGcbf9F/gLA0Tkueij7qQdounNpsjGXx6rqXb0MsqBIU9fmbx9205O5RB6mQiJFmyoaUZBND/FF0da68yxLjpP5axL+xP/zfd6hLFm/sjgqLvQKWf7yNAawInkW5tFBKd36JmT2vnnEmKivw5NupyYmw504ekAIIt7LfQvWMne6p5f3DF0Aw0WONtBAcXFHPKthaL44mswThoB9tBsRqdocvN7hAEcVd7Ui1eVmd9gl3ArNQSynuF9nJ5nWbhdZMzsddPOm5tjF0+pr130e2IE5vS3t98oBntsM56fQ9AtsClLHHpcg6nLBC4bK8/L1osx3MI9cAwARZFSyR3PQrAOsD7v8QtzbN8ReL+4k5Mn8uk2yj4xjPsEqUk9bop/teu5ukWvstok8gal29bwPSO8e02gxK14ajYFsfZY/23Eaq1k//6QlI2+CQXyw4TbfAjMZAZLKlFP3+TUlqNv9sANDcCkqqbetgBp7fB0MP/u72O/wTqNdeoTsfkQNFlT85/CMjA+xZP4usKe1baaWwuTH+sOVDruYQ+tzR94a5dhUygYmy/baogV4jfPBceJ6jz2paYBptVNjlgubTYI3WCvQ== 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:(13230022)(396003)(376002)(366004)(136003)(346002)(39860400002)(451199015)(83380400001)(186003)(38070700005)(86362001)(122000001)(38100700002)(82960400001)(52536014)(8936002)(5660300002)(64756008)(66446008)(66476007)(66556008)(66946007)(76116006)(41300700001)(4326008)(2906002)(53546011)(478600001)(7696005)(6506007)(26005)(9686003)(316002)(54906003)(110136005)(8676002)(55016003)(71200400001)(33656002); DIR:OUT; SFP:1102; x-ms-exchange-antispam-messagedata-chunkcount: 1 x-ms-exchange-antispam-messagedata-0: =?us-ascii?Q?e4tRFWjBkvIZLycZUHM9EX/tJke/9m/xaBbAgg50fB2Howqe3t2J7/RxKyqy?= =?us-ascii?Q?5mReJzNkbL2CSIRoQMy3Cgq1hfLnyUBasqGPWC7/FXiTUpIFAh42g7R36o6V?= =?us-ascii?Q?bh8kxz4tgzntqBGJ73tmqDlHinNfSu4dCSJJ4v0Y1jYmJiqZYMTr1Wytsj8v?= =?us-ascii?Q?8KD0YRNCeiGM/+Hy4D6kpUjQd3OO3SEDJc2VFzvPZlMfzkR1H9ukrFWT7ItB?= =?us-ascii?Q?VsEJ6hILOburJplVzhgAAxgB1VN+ZldF/yBx9csj9thjUIN5CCg7uzr+kjv2?= =?us-ascii?Q?NOcPt8YpNcgS8sQvOjqzmL1UVQyKrjD6tqOYC4tQZBz2MEZx2Xrwnt2NKYvt?= =?us-ascii?Q?YX8Sz7VOHLcUsRNR6omyLq1Fl+zusBuuzCKGeJMDuUh5qbelKu4bbMcZn21f?= =?us-ascii?Q?1UZQ/J9rx13yRzTHoqfCnMHt9j9w10+sLtRMXrsN7oN/ceVT+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kAKVQD9BelOebdP2kb4q5OOMYxHLw61kfaXi3Zp3eAff?= =?us-ascii?Q?EYOg1lewMprfyennQ9Z1BG0z2T9tApqPel/EAX4izI5y5tCmIdSEKnkie6HO?= =?us-ascii?Q?HXis9FIrretMH+Fu3TULsqlZ5x6CfwzkzbLpZVcRufb0KoKNRqjuDfPyPpqj?= =?us-ascii?Q?as4+veOUxsCAp82+JY+o1+NmXKB9ukBub+9XviblVr59e6LyJ+L1JF6YWaw5?= =?us-ascii?Q?MIREvcJheMmMAJOvCIFsN/nyd5crTUYHxT6NmCqu?= 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: d1a4a5bf-93a8-4470-4b8d-08daa1f52ee5 X-MS-Exchange-CrossTenant-originalarrivaltime: 29 Sep 2022 08:32:45.1716 (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: FnMPgsk6cKx2qhuYykv0K7v987oiG6cbdvVC74SSjufpvFanyl65KFez71pIY3gFB059I39RR0vheqsz26HfRQ== X-MS-Exchange-Transport-CrossTenantHeadersStamped: SA2PR11MB4810 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: Xia, Chenbo > Sent: Wednesday, September 28, 2022 12:43 PM > To: David Marchand ; dev@dpdk.org > Cc: Maxime Coquelin ; Ray Kinsella > > Subject: RE: [PATCH] vhost: remove deprecated helpers >=20 > > -----Original Message----- > > From: David Marchand > > Sent: Tuesday, September 27, 2022 7:36 PM > > To: dev@dpdk.org > > Cc: Maxime Coquelin ; Xia, Chenbo > > ; Ray Kinsella > > Subject: [PATCH] vhost: remove deprecated helpers > > > > Those helpers have been marked as deprecated for a long time and have > > documented equivalent helpers. > > > > Signed-off-by: David Marchand > > --- > > doc/guides/rel_notes/release_22_11.rst | 3 ++ > > lib/vhost/rte_vhost.h | 55 -------------------------- > > lib/vhost/version.map | 2 - > > lib/vhost/vhost.c | 11 ------ > > 4 files changed, 3 insertions(+), 68 deletions(-) > > > > diff --git a/doc/guides/rel_notes/release_22_11.rst > > b/doc/guides/rel_notes/release_22_11.rst > > index 684bf74596..7f61cdf56a 100644 > > --- a/doc/guides/rel_notes/release_22_11.rst > > +++ b/doc/guides/rel_notes/release_22_11.rst > > @@ -204,6 +204,9 @@ API Changes > > Names for the telemetry commands are now similarly limited. > > The parameters for telemetry commands are unaffected by this change. > > > > +* vhost: Removed deprecated ``rte_vhost_gpa_to_vva`` and > > + ``rte_vhost_get_queue_num`` helpers. > > + > > * raw/ifgpa: The function ``rte_pmd_ifpga_get_pci_bus`` has been > removed. > > > > > > diff --git a/lib/vhost/rte_vhost.h b/lib/vhost/rte_vhost.h > > index 617425e8d6..bb7d86a432 100644 > > --- a/lib/vhost/rte_vhost.h > > +++ b/lib/vhost/rte_vhost.h > > @@ -354,44 +354,6 @@ struct rte_vhost_stat_name { > > /** > > * Convert guest physical address to host virtual address > > * > > - * This function is deprecated because unsafe. > > - * New rte_vhost_va_from_guest_pa() should be used instead to ensure > > - * guest physical ranges are fully and contiguously mapped into > > - * process virtual address space. > > - * > > - * @param mem > > - * the guest memory regions > > - * @param gpa > > - * the guest physical address for querying > > - * @return > > - * the host virtual address on success, 0 on failure > > - */ > > -__rte_deprecated > > -static __rte_always_inline uint64_t > > -rte_vhost_gpa_to_vva(struct rte_vhost_memory *mem, uint64_t gpa) > > -{ > > - struct rte_vhost_mem_region *reg; > > - uint32_t i; > > - > > - for (i =3D 0; i < mem->nregions; i++) { > > - reg =3D &mem->regions[i]; > > - if (gpa >=3D reg->guest_phys_addr && > > - gpa < reg->guest_phys_addr + reg->size) { > > - return gpa - reg->guest_phys_addr + > > - reg->host_user_addr; > > - } > > - } > > - > > - return 0; > > -} > > - > > -/** > > - * Convert guest physical address to host virtual address safely > > - * > > - * This variant of rte_vhost_gpa_to_vva() takes care all the > > - * requested length is mapped and contiguous in process address > > - * space. > > - * > > * @param mem > > * the guest memory regions > > * @param gpa > > @@ -696,23 +658,6 @@ int rte_vhost_get_mtu(int vid, uint16_t *mtu); > > */ > > int rte_vhost_get_numa_node(int vid); > > > > -/** > > - * @deprecated > > - * Get the number of queues the device supports. > > - * > > - * Note this function is deprecated, as it returns a queue pair number= , > > - * which is vhost specific. Instead, rte_vhost_get_vring_num should > > - * be used. > > - * > > - * @param vid > > - * vhost device ID > > - * > > - * @return > > - * The number of queues, 0 on failure > > - */ > > -__rte_deprecated > > -uint32_t rte_vhost_get_queue_num(int vid); > > - > > /** > > * Get the number of vrings the device supports. > > * > > diff --git a/lib/vhost/version.map b/lib/vhost/version.map > > index 18574346d5..7a00b65740 100644 > > --- a/lib/vhost/version.map > > +++ b/lib/vhost/version.map > > @@ -41,14 +41,12 @@ DPDK_23 { > > rte_vhost_get_mtu; > > rte_vhost_get_negotiated_features; > > rte_vhost_get_numa_node; > > - rte_vhost_get_queue_num; > > rte_vhost_get_vdpa_device; > > rte_vhost_get_vhost_ring_inflight; > > rte_vhost_get_vhost_vring; > > rte_vhost_get_vring_base; > > rte_vhost_get_vring_base_from_inflight; > > rte_vhost_get_vring_num; > > - rte_vhost_gpa_to_vva; > > rte_vhost_log_used_vring; > > rte_vhost_log_write; > > rte_vhost_rx_queue_count; > > diff --git a/lib/vhost/vhost.c b/lib/vhost/vhost.c > > index aa671f47a3..abf17eb509 100644 > > --- a/lib/vhost/vhost.c > > +++ b/lib/vhost/vhost.c > > @@ -859,17 +859,6 @@ rte_vhost_get_numa_node(int vid) > > #endif > > } > > > > -uint32_t > > -rte_vhost_get_queue_num(int vid) > > -{ > > - struct virtio_net *dev =3D get_device(vid); > > - > > - if (dev =3D=3D NULL) > > - return 0; > > - > > - return dev->nr_vring / 2; > > -} > > - > > uint16_t > > rte_vhost_get_vring_num(int vid) > > { > > -- > > 2.37.3 >=20 > Reviewed-by: Chenbo Xia Applied to next-virtio/main, thanks