From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from NAM02-SN1-obe.outbound.protection.outlook.com (mail-sn1nam02on0069.outbound.protection.outlook.com [104.47.36.69]) by dpdk.org (Postfix) with ESMTP id 0B99E2BAF for ; Wed, 30 Aug 2017 21:25:41 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=CAVIUMNETWORKS.onmicrosoft.com; s=selector1-cavium-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version; bh=Qa1iGNBhGhsKitZrrmytPGQbw26lOUIeGPyW4ZtFHYg=; b=X+Mgm2szZcY84hlJEQ5gjDl3SNNvYf7lPbBsBp/UC9ia1T4gfRw5fdB1LSNfXydOfjwxFN7B5kcrsPbSG1jVdFDk/3XpwWVeGzfj1trpozxhNDyC8p38xl9pZHm+hFm7sxlugfUZk4KYn7JzuzduQFVqwAY+XBjIfEayZ0B5qL4= Authentication-Results: spf=none (sender IP is ) smtp.mailfrom=Pavan.Bhagavatula@cavium.com; Received: from PBHAGAVATULA-LT (103.16.71.100) by CY4PR07MB3461.namprd07.prod.outlook.com (10.171.252.142) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384_P256) id 15.20.13.10; Wed, 30 Aug 2017 19:25:39 +0000 Date: Thu, 31 Aug 2017 00:55:17 +0530 From: Pavan Nikhilesh Bhagavatula To: Harry van Haaren Cc: dev@dpdk.org Message-ID: <20170830192515.GA14859@PBHAGAVATULA-LT> References: <1502800360-15782-1-git-send-email-harry.van.haaren@intel.com> <1503320296-51122-1-git-send-email-harry.van.haaren@intel.com> <1503320296-51122-2-git-send-email-harry.van.haaren@intel.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <1503320296-51122-2-git-send-email-harry.van.haaren@intel.com> User-Agent: Mutt/1.5.24 (2015-08-30) X-Originating-IP: [103.16.71.100] X-ClientProxiedBy: HK2PR02CA0212.apcprd02.prod.outlook.com (10.171.30.152) To CY4PR07MB3461.namprd07.prod.outlook.com (10.171.252.142) X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: e43535f8-0a53-41fb-bbdf-08d4efdce690 X-Microsoft-Antispam: UriScan:; BCL:0; PCL:0; RULEID:(300000500095)(300135000095)(300000501095)(300135300095)(22001)(300000502095)(300135100095)(2017030254152)(300000503095)(300135400095)(2017052603199)(201703131423075)(201703031133081)(201702281549075)(300000504095)(300135200095)(300000505095)(300135600095)(300000506095)(300135500095); SRVR:CY4PR07MB3461; X-Microsoft-Exchange-Diagnostics: 1; CY4PR07MB3461; 3:O7Nn2XYtlZ/YGWbxw63/G0cVGfC+6HCyQT2K2SL7LF+4CVZ5EvIzVPvzvlksApEWjcygvpl4iqPfKcqgZBNuE+n/c+f4LiPRIWTXCZ0K6A7bKlt5oFquRv98tATtfpkAYqEM8cJ5QS+fZ/J10PZYbJbg/hzlIZF/gcwmSdSm9qFGcmtuvh2vojKv0Tm7gc36Uen5v6MqhX8cmqiCl86+0NB7H7wKPkz7UUKA1mBTRlGlJ3vS0gdkQF4EDn4oU56y; 25:hw//FUXiL9S2uUElNaBpICJNVmlYC8hrhUP2SOSiL5KxVR8kWyXb+Nwgf7mjFVwS3IJHnyolU8Jrqmz2v4gyqlkHpqRIgvnivqACJK5C7Lq6D0spuhY87dgFFrpqTSoKuaEueP2E483iOnOkLnwoLqCX7h3jZnX2FscN/1pk3z7t/q42oF5g1VfhJm3Iij/+F1HfHxqH9UTwv54olNCRHgBWBtwoQhFE+eD/oMA/278qPRnAgstby/yKTkfjcMQSx/rV4KOdKgB7jS1qA11s2te1juE8KU2r5gqyeosKGS73tX1clgE9Pe5TqkoqelsTL9A3JKcbKieQWjDe6f+P+w==; 31:YNqYlG8PxDHbw6oU2zx17fLdQNrakJvDuY7EtAizoYW4l5F3N7WQYjJ4qPU5EhOsU8SjeukFf/LpONeBsIFgTw15d1yNYWRcsOHauxZAjVUmRCjQl/6S+xs624wB9nurw5CljfKqNm9nQpvlip2HvSP+fGGDKwlDaQNNuApXq6hZGFors9UIDsHWUTqQhKO+jWgZhR/vHk12BRiBQt8YlnVgncckSU55dkAYKJIpHhU= X-MS-TrafficTypeDiagnostic: CY4PR07MB3461: X-Microsoft-Exchange-Diagnostics: 1; CY4PR07MB3461; 20:f74bCXjM15w1kF2dZrlxfsIHzw+2IgnJo2e738GeIVbhdxYK7FcEpbbTkGKGEzsklkX91eU+TXai/myH6v65PPetwvnY7rKfsGttlQYYH331Eyp+TwTCOYV2AMXngC6YszDPTBW25no199NHzZHn293DISOo6cHJVSuuE1Ov4MLyiBmco+XYuqWG58tjzbI/HN0CkiX3bazvGjmqmLDMDm57/WZscPrXywlMOTI7nKfew6orAflcyTprxllSZxQex8/m0gyZ7+7KZ3mYfegPIwvoRadm5bBI1/Y5oEOporllyrd6XEZzyobuSbctaZcFM1zCvHtY8ezvgPJBT1Gw6hyR/09g4pXp+Qn5uH5CGaYo8nqHSPnrXNgW+SwALY7aMqyH4af/8tZcLV8TzG4xxG+tpCSPsRLhwXMAouMB7AK79hfdXqov1BHdwB/lBAV4wp5bZjd9pwbYYc4zoKu4404YVOI3rLOWNrWZdImRxYOw3cy78F6i34yUxhacyoMcu6HRpc6DS/mdVDTXhc2NVvrQBMrcKahm3AMeDObStf50S4avjynxHIP/+u7cxAZcl/KukCxSMUiJbHdWd5iMnaHWOrwkzE6WcR1/4MXfYCU=; 4:y4QUPdTlxPGX8dtqpKUKTjqQW6XfUZVeN5cbEV9NayBzTzcur7sxhRWc6eJJiIrPRR+pq/BJYbGiFyelT5vMCU64aUsz253YMU5+zkUgGuLPsPrGA4D69bIZ9fU+UWgW4bIucza2Z8//NI+Ag6+GQkJL6rclulCG92hw8MZn+70evoNA9h4e5adx4Fv0nxdzWQHczE/8O+t1BOGaUnjdOq6iKPPMYbgrlHiiEYsOtiycb687MwxBW+VtDBrdyooD/zfDE1RU9RFrAQpseRs8MT9bxIalmgB3GeWmgqDj8aM= X-Exchange-Antispam-Report-Test: UriScan:(228905959029699); X-Microsoft-Antispam-PRVS: X-Exchange-Antispam-Report-CFA-Test: BCL:0; PCL:0; RULEID:(100000700101)(100105000095)(100000701101)(100105300095)(100000702101)(100105100095)(6040450)(601004)(2401047)(5005006)(8121501046)(93006095)(3002001)(100000703101)(100105400095)(10201501046)(6041248)(20161123555025)(20161123558100)(20161123562025)(201703131423075)(201702281528075)(201703061421075)(201703061406153)(20161123560025)(20161123564025)(6072148)(201708071742011)(100000704101)(100105200095)(100000705101)(100105500095); SRVR:CY4PR07MB3461; BCL:0; PCL:0; RULEID:(100000800101)(100110000095)(100000801101)(100110300095)(100000802101)(100110100095)(100000803101)(100110400095)(100000804101)(100110200095)(100000805101)(100110500095); SRVR:CY4PR07MB3461; X-Forefront-PRVS: 041517DFAB X-Forefront-Antispam-Report: SFV:NSPM; SFS:(10009020)(6009001)(199003)(24454002)(189002)(1076002)(478600001)(105586002)(8936002)(81156014)(25786009)(33716001)(81166006)(83506001)(2950100002)(6666003)(42882006)(3846002)(6916009)(72206003)(6116002)(23726003)(7736002)(305945005)(8676002)(53936002)(229853002)(9686003)(4001350100001)(189998001)(106356001)(97736004)(55016002)(2906002)(101416001)(33656002)(4326008)(50986999)(54356999)(68736007)(6496005)(47776003)(76176999)(66066001)(50466002)(5660300001)(6246003)(110136004)(42186005)(18370500001)(107986001); DIR:OUT; SFP:1101; SCL:1; SRVR:CY4PR07MB3461; H:PBHAGAVATULA-LT; FPR:; SPF:None; PTR:InfoNoRecords; A:1; MX:1; LANG:en; Received-SPF: None (protection.outlook.com: cavium.com does not designate permitted sender hosts) X-Microsoft-Exchange-Diagnostics: =?us-ascii?Q?1; CY4PR07MB3461; 23:eki94iRakpm3RDATrq9Tm3gjlVk6lpgahf54LL1v2?= =?us-ascii?Q?79l+jdRnWzzOsQDpi9fK9U8lcR2A7Lb5Ju1vhM/5TDp5ztwU2qSCEYKMdTSc?= =?us-ascii?Q?wHwaAXBhSDk9s7Knbzu3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ZatgBXFG4rWvK3n8tWhq++asbCiG87bxRPPIWDhEBBzjzeT9eLg= SpamDiagnosticOutput: 1:99 SpamDiagnosticMetadata: NSPM X-OriginatorOrg: caviumnetworks.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 30 Aug 2017 19:25:39.3827 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 711e4ccf-2e9b-4bcf-a551-4094005b6194 X-MS-Exchange-Transport-CrossTenantHeadersStamped: CY4PR07MB3461 Subject: Re: [dpdk-dev] [PATCH v2 01/15] service: rework probe and get name to use ids X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 30 Aug 2017 19:25:42 -0000 On Mon, Aug 21, 2017 at 01:58:02PM +0100, Harry van Haaren wrote: > This commit adds a macro to easily validate a service ID, and then > lookup the service pointer, or return a user-specified error code. > This marco will be heavily used in the following patches as it will > be ID based instead of pointer-based. > > The probe_capability function is reworked to use an integer ID instead > of a pointer. Rework the service_get_name() function is updated to use > IDs. Unit tests are updated to keep things compiling after each commit. > > Signed-off-by: Harry van Haaren Acked-by: Pavan Nikhilesh