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 7500BA0548; Wed, 1 Jun 2022 11:35:26 +0200 (CEST) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 1A79940689; Wed, 1 Jun 2022 11:35:26 +0200 (CEST) Received: from mga02.intel.com (mga02.intel.com [134.134.136.20]) by mails.dpdk.org (Postfix) with ESMTP id ABFC94003F for ; Wed, 1 Jun 2022 11:35:22 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1654076123; x=1685612123; h=message-id:date:subject:to:cc:references:from: in-reply-to:content-transfer-encoding:mime-version; bh=5RagobpUHVxk2mWQoYkK6LRhYKSq9wWldM7y4kOoEi8=; b=PXeopVt+lQLF47uGSVUNLX8wWikJQWT+bxBNIyEdAmGJGUT6ct2rIXe7 kfAxtHJJiQ5Xgq9bS04eGI/ajrZmoz0mJCANLMZvae9itGpP68gYbUb/G 0tw+6C3JewmpqO4zsMOVp3gEqy/ZoTGywiXsS9bdwfN+oa3TMg+J/5ECo lui7eFpFJVW7RXmVLLDbq6beUAwBVSqDXb/MNw5BgUX/OAxFwY88VryBy G2xPJvrfKxn84DEyerIKILZhtZV/cGsbTN8L79iZKL+XUone/uwOkd9mv gnECT5ZU2mzENyUo6La0eYKFM8AI0wEpLL1feSwM14y6c0LRUfKQpyz0B g==; X-IronPort-AV: E=McAfee;i="6400,9594,10364"; a="263167532" X-IronPort-AV: E=Sophos;i="5.91,266,1647327600"; d="scan'208";a="263167532" Received: from orsmga006.jf.intel.com ([10.7.209.51]) by orsmga101.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 01 Jun 2022 02:35:21 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.91,266,1647327600"; d="scan'208";a="552225223" Received: from orsmsx606.amr.corp.intel.com ([10.22.229.19]) by orsmga006.jf.intel.com with ESMTP; 01 Jun 2022 02:35:21 -0700 Received: from orsmsx612.amr.corp.intel.com (10.22.229.25) by ORSMSX606.amr.corp.intel.com (10.22.229.19) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2308.27; Wed, 1 Jun 2022 02:35:20 -0700 Received: from orsmsx603.amr.corp.intel.com (10.22.229.16) by ORSMSX612.amr.corp.intel.com (10.22.229.25) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2308.27; Wed, 1 Jun 2022 02:35:20 -0700 Received: from orsedg603.ED.cps.intel.com (10.7.248.4) 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.2308.27 via Frontend Transport; Wed, 1 Jun 2022 02:35:20 -0700 Received: from NAM10-BN7-obe.outbound.protection.outlook.com (104.47.70.107) by edgegateway.intel.com (134.134.137.100) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.1.2308.27; Wed, 1 Jun 2022 02:35:20 -0700 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=ABu6AImJvoLj5HWvVKCWS9NybV/8DiWwYV46pf3fS41lRjghXRW5LHq4uwVDq9PNf8PCg+nU18XcDsgXLZJ8dWW/rEc5O+K9aJGr1oF6NLd0YkKLbRgKgAD+OiGcRqqTqLu+EnrwsLVVFPY05wwPGaWxNL/A/6ObMUM/CpobtnjOXy6aY37NOCnhjFoMQChEiu8OlS9rjmxYcWWjbSqb+mBmLc/g/vnD5Nw19MGYun0A6uCvFmI8ESoJaJWnMFrrVFlqM9UVDjHY/3kZTWn5C225az2+kbzCQsb60SdWkBSisjYAUjS9s0+dMKHquf8uDVNZxjJcfWpV3wn4nCaZ6A== 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=sipI86Uz50OzunLlXQC4YldB7CsIQfF5CkPNW35dwlo=; b=ifhu1RaNdBCSSRMmrS/NwHuwJSz9ROh8E6AGdLVGjaYIq2C/S2yZCNKFE+vf7Pm94dlDQ8WNvDktk3x7moopYoCXOQGL8EBOnOXNsAiKL7I2AmNoAcgq/OyfgKOQEGLBl+PSkpwcLMkiBymqohZsgb/cS41rnyBum5/GJWr8AzB75sC99q7lpKWVjD4x9ozvNq4FgZhedTYlh6lTgg5xNtehh22VLsW69IGVitK8QwOK6zS+K8gtP8zRueR8j1sqXAFheduxkyqzBuRgcXRJ6lS5JKRFPfPgZztSpAFFRpYoGEyKd0EYWSPgNH+EbFC6SBko172qXuvudUSqvLOoeQ== 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 Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=intel.com; Received: from PH7PR11MB5765.namprd11.prod.outlook.com (2603:10b6:510:139::7) by CO6PR11MB5667.namprd11.prod.outlook.com (2603:10b6:5:35b::15) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5314.12; Wed, 1 Jun 2022 09:35:18 +0000 Received: from PH7PR11MB5765.namprd11.prod.outlook.com ([fe80::c8b7:8aa7:c8eb:34eb]) by PH7PR11MB5765.namprd11.prod.outlook.com ([fe80::c8b7:8aa7:c8eb:34eb%6]) with mapi id 15.20.5273.023; Wed, 1 Jun 2022 09:35:18 +0000 Message-ID: <02675591-f6f5-4b54-e84e-7d22c6a979da@intel.com> Date: Wed, 1 Jun 2022 10:35:13 +0100 User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:91.0) Gecko/20100101 Firefox/91.0 Thunderbird/91.9.1 Subject: Re: [PATCH v3 1/2] lpm: add const to lpm arg of rte_lpm_lookup Content-Language: en-US To: Stanislaw Kardach CC: , Frank Zhao , Sam Grove , , References: <20220527181822.716758-1-kda@semihalf.com> <20220530182437.56853-1-kda@semihalf.com> From: "Medvedkin, Vladimir" In-Reply-To: <20220530182437.56853-1-kda@semihalf.com> Content-Type: text/plain; charset="UTF-8"; format=flowed Content-Transfer-Encoding: 7bit X-ClientProxiedBy: LO4P123CA0421.GBRP123.PROD.OUTLOOK.COM (2603:10a6:600:18b::12) To PH7PR11MB5765.namprd11.prod.outlook.com (2603:10b6:510:139::7) MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 7a3d24ef-2108-4c44-9ff8-08da43b20a36 X-MS-TrafficTypeDiagnostic: CO6PR11MB5667:EE_ 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: MwC7Q4JyJLT4ddYNbAHC6L8bNGj6VrnQI9wsWUDMgxJqlOgrGAnoHcpiQ0dk4hpIjwXBkfyTeYM3rVt0lAhJXBE/k2dg7vw1sT7B8/xjS9r0y/ioUxh+4cIkYHVs8dQKt6MxcWbnqZZGB6LzDuPXV4eDCboZ9zoaxlAZGDlgUmDmS7rH7AYx324zXczoUGdc01MkBQ/S0xjODb2tsE5vfRFTy1odaN3mUEL4TUFXqUVLffWhZVKFALdQfBAf1PuP39IR+FLxh//30hVjcOMF947rVKIWYQFXZa+UDd5GKVm8ETIsA/60WSIagHL/3sRpR+hbIWe9AjKGFIpFQaWb+0j2ebmGC0i75NvqBX+g0O6T+1gh4mv5kBXN53suLVIIkcW72pApIOzY83BC49kSzZ3mdeRalTGIyzduoXTGfdbF9l8MI5gx191IG7a324kOh9YbSHRiAij1ZC0KRB0BdLXz3EXnRca8T7CXIRjpohosaAr84XncWqdsGSc2acs8jMLc3BESgpz7OMPBIdI1WOTgAFGcoFSSWSH3m2Yp1rdwHw2zQ/zd6ZwK6NJ79DV5EEXBUorNpJBYyFG+fX3QUaLafRP6Z1vZM/Vkqzr/zvx+gB9SRvbJ+eoOpxhNnG5piYgGvpskrpTpgp8humSSoqFQNvOkI+4njd6ob7+CROyNwJ6yrWiQiW7Jyb3VI4ok0Q8lnlkr2oUcReA2dMoFVTOmHgW045w1j65r2W/gHJs= X-Forefront-Antispam-Report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:PH7PR11MB5765.namprd11.prod.outlook.com; PTR:; CAT:NONE; SFS:(13230001)(366004)(26005)(6512007)(6666004)(6506007)(53546011)(8936002)(36756003)(2616005)(186003)(31686004)(2906002)(4744005)(8676002)(4326008)(86362001)(6486002)(66476007)(508600001)(54906003)(66946007)(5660300002)(82960400001)(83380400001)(38100700002)(31696002)(316002)(66556008)(6916009)(43740500002)(45980500001); DIR:OUT; SFP:1102; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: =?utf-8?B?dG01Y2hRWis0d0daUkZZRGdQTEN1RVFwMFJvVENHMVdNTmZ4SzhueEo3Y3Jz?= =?utf-8?B?SWlOSkdOdStScGlFZWRrbEYxbnV3SnZ6OVdwTWlybTkvU0dZZmQ3RHlhYkov?= =?utf-8?B?MHpxYktWcDZpR2xLYzl1WnFCSTJ6NUEzeTFLOUhaL21xbjZEaTJjMExmSUR0?= =?utf-8?B?RGV0cXUxN0RNQ05PUWoweVdQVHVxRzVRSE50TFMrRFpjTnFzZGZ5TjBKcUdG?= =?utf-8?B?a0VTMzlsVjlIMGtvOUJFdDJWNkxMK2tpREUwNXVsaWRNb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TWJKTDQwT1FJdDVTZ0VhNkRCUUpvN2RDRStYWGlRWXFzMFl4?= =?utf-8?B?NTJUOTVqMlg0L3o3Q0tuVWRuSHRHMGRqUGd3TWFGM2VMSHBUUzFZYitRdi9m?= =?utf-8?B?Q3lJeWhVRzZMYU5BS3dnM3pBeDlSeDF6VHhiV0laM0kxWDJEdXFVN0t5akxV?= =?utf-8?B?ZEc2K2FQTlB2V0hCRXRvNVNJbmpJT0NnYWo4Z1BtdktXN3dZaWVDejlYSTRQ?= =?utf-8?B?azVxZW54U0hGNU1LYVhyVWxSdFlwcGc1MU1WM2ZYdlAxMDczZURETHp2SllQ?= =?utf-8?Q?SX/kZJECMIsQ3KFk=3D?= X-MS-Exchange-CrossTenant-Network-Message-Id: 7a3d24ef-2108-4c44-9ff8-08da43b20a36 X-MS-Exchange-CrossTenant-AuthSource: PH7PR11MB5765.namprd11.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 01 Jun 2022 09:35:18.2656 (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: 6DsiueWI8UVDmEnwZCRhctrtoCIfEt2w+aDR9uuVB89LTkajllW1I1UIE8SE2KK/HmV82W2e1n2y5CvFsXPznsFKRAcxSGZHxE/pcQ5Epzg= X-MS-Exchange-Transport-CrossTenantHeadersStamped: CO6PR11MB5667 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 On 30/05/2022 19:24, Stanislaw Kardach wrote: > All other rte_lpm_lookup* functions take lpm argument as a const. As the > basic rte_lpm_lookup() performs the same function, it should also do > that. > > As this function is inline, no API/ABI change happens. > > Signed-off-by: Stanislaw Kardach > --- > lib/lpm/rte_lpm.h | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/lib/lpm/rte_lpm.h b/lib/lpm/rte_lpm.h > index eb91960e81..1cf863a146 100644 > --- a/lib/lpm/rte_lpm.h > +++ b/lib/lpm/rte_lpm.h > @@ -279,7 +279,7 @@ rte_lpm_delete_all(struct rte_lpm *lpm); > * -EINVAL for incorrect arguments, -ENOENT on lookup miss, 0 on lookup hit > */ > static inline int > -rte_lpm_lookup(struct rte_lpm *lpm, uint32_t ip, uint32_t *next_hop) > +rte_lpm_lookup(const struct rte_lpm *lpm, uint32_t ip, uint32_t *next_hop) > { > unsigned tbl24_index = (ip >> 8); > uint32_t tbl_entry; Acked-by: Vladimir Medvedkin -- Regards, Vladimir