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 F2D3FA0C46; Mon, 23 Aug 2021 23:18:36 +0200 (CEST) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 86D3D40151; Mon, 23 Aug 2021 23:18:36 +0200 (CEST) Received: from EUR03-VE1-obe.outbound.protection.outlook.com (unknown [40.107.5.53]) by mails.dpdk.org (Postfix) with ESMTP id 23E884014D for ; Mon, 23 Aug 2021 23:18:35 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=armh.onmicrosoft.com; s=selector2-armh-onmicrosoft-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=keBhg2DqyIEwopmjMuwJXUwizdkosbxWR7PCpPnhj7I=; b=UsXfO+gTISRwBvWQ9bODCseTyIJph0VTKclrouNNRfuEZ6V+1uOYwXgBg3ysGVVBuAePuEsEal7WKcwDxvclkWYqrOuC2FtTAoGhtdc6U1YXol7DqwLqwA30MhM7Uza5n9dxk1MZI2KqxUnmdZK4VnMmOjiSwBcXhSiHQuizae0= Received: from AS8PR04CA0192.eurprd04.prod.outlook.com (2603:10a6:20b:2f3::17) by AM7PR08MB5334.eurprd08.prod.outlook.com (2603:10a6:20b:10b::15) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4436.19; Mon, 23 Aug 2021 21:18:33 +0000 Received: from AM5EUR03FT050.eop-EUR03.prod.protection.outlook.com (2603:10a6:20b:2f3:cafe::63) by AS8PR04CA0192.outlook.office365.com (2603:10a6:20b:2f3::17) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4436.19 via Frontend Transport; Mon, 23 Aug 2021 21:18:33 +0000 X-MS-Exchange-Authentication-Results: spf=pass (sender IP is 63.35.35.123) smtp.mailfrom=arm.com; dpdk.org; dkim=pass (signature was verified) header.d=armh.onmicrosoft.com;dpdk.org; dmarc=pass action=none header.from=arm.com; Received-SPF: Pass (protection.outlook.com: domain of arm.com designates 63.35.35.123 as permitted sender) receiver=protection.outlook.com; client-ip=63.35.35.123; helo=64aa7808-outbound-1.mta.getcheckrecipient.com; Received: from 64aa7808-outbound-1.mta.getcheckrecipient.com (63.35.35.123) by AM5EUR03FT050.mail.protection.outlook.com (10.152.17.47) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4436.19 via Frontend Transport; Mon, 23 Aug 2021 21:18:33 +0000 Received: ("Tessian outbound 6ba9ec11d42b:v103"); Mon, 23 Aug 2021 21:18:33 +0000 X-CR-MTA-TID: 64aa7808 Received: from 53139ad84635.2 by 64aa7808-outbound-1.mta.getcheckrecipient.com id 5FEB4A56-C8C6-4089-834C-12A2760E8AE7.1; Mon, 23 Aug 2021 21:18:23 +0000 Received: from EUR04-HE1-obe.outbound.protection.outlook.com by 64aa7808-outbound-1.mta.getcheckrecipient.com with ESMTPS id 53139ad84635.2 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384); Mon, 23 Aug 2021 21:18:23 +0000 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=bw9TSzVrrzqKqrIIHiVgQTAxrn8JAcT2QBpHQQFX9FYVrn990iYOgy5XGJf46QuOuQWtwid+hs3KqjqxQ+xAFazMAO9SuNYxNIJBIAXrTrcIeQd3NxqBLDXk7if9cgm/apP6vzs3EIb0vbm08x52FicK2E8ef20HmwDym3FoeOHtfDVlVRfVnbrysSOTAfg4h7oZ2NC5Fr3z1ZYma4/bSZ1o69oP8bWgtbWiZ9rN+BcwZZPrlw9ZnoDZ5SKR4pL5p28IyYEohsp90XKRJY51NnGja0qPVdrFtKE3JJcLXNivM2D1eoJTuCF/Ob5PRfd1atC0I9gbbhab0pQH4NerrA== 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-SenderADCheck; bh=keBhg2DqyIEwopmjMuwJXUwizdkosbxWR7PCpPnhj7I=; b=AZpfPYS2wE1j92ys89suEWtkJ3lt2sDa3E5IHPmLN1+lKZUvw1b9GQ46lmzouuy7FD1j0AQ8qdAJ8BYsuGOmX8Ih6NakVuoZbA9dJSfoK9K1xnHETBWvtfdcBZEM8OfGvVTaXSb4CWkF9e6isAHL3Y8CL7ParJKlo0r68XbLQwfWk66LI0dsEsFkeDvkZ0jRwfXLpymrn39DC3/MjSa4g86HnpCY+mmpJBKiLwT5XA1IskdKp0rCGYknzDKVVZzoa53XWQlata/dEInLvZ/A2Ll95EQicTDpdUkRSRo1e9OGvDcqRodlFxunvDO+/9LvSw7V2iq/F9VYznXrhPEG3g== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=arm.com; dmarc=pass action=none header.from=arm.com; dkim=pass header.d=arm.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=armh.onmicrosoft.com; s=selector2-armh-onmicrosoft-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=keBhg2DqyIEwopmjMuwJXUwizdkosbxWR7PCpPnhj7I=; b=UsXfO+gTISRwBvWQ9bODCseTyIJph0VTKclrouNNRfuEZ6V+1uOYwXgBg3ysGVVBuAePuEsEal7WKcwDxvclkWYqrOuC2FtTAoGhtdc6U1YXol7DqwLqwA30MhM7Uza5n9dxk1MZI2KqxUnmdZK4VnMmOjiSwBcXhSiHQuizae0= Received: from DBAPR08MB5814.eurprd08.prod.outlook.com (2603:10a6:10:1b1::6) by DB6PR0801MB1960.eurprd08.prod.outlook.com (2603:10a6:4:76::21) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4436.22; Mon, 23 Aug 2021 21:18:16 +0000 Received: from DBAPR08MB5814.eurprd08.prod.outlook.com ([fe80::ac8f:622:c2d4:9e6d]) by DBAPR08MB5814.eurprd08.prod.outlook.com ([fe80::ac8f:622:c2d4:9e6d%9]) with mapi id 15.20.4436.025; Mon, 23 Aug 2021 21:18:16 +0000 From: Honnappa Nagarahalli To: Olivier Matz CC: "thomas@monjalon.net" , "dev@dpdk.org" , "lucp.at.work@gmail.com" , "david.marchand@redhat.com" , Ruifeng Wang , nd , nd Thread-Topic: [dpdk-dev] [PATCH] doc: abstract the behaviour of rte_ctrl_thread_create Thread-Index: AQHXi5w29ykrwJKtz0WfBbjvvU4iCKtrJ2pQgBXHLQCAALhu0A== Date: Mon, 23 Aug 2021 21:18:16 +0000 Message-ID: References: <20210730214453.19975-1-honnappa.nagarahalli@arm.com> <7793415.AuWXLK4XGA@thomas> In-Reply-To: Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-ts-tracking-id: 45DEDD8E45D20C4795AA6FB1B7F3B5F0.0 x-checkrecipientchecked: true Authentication-Results-Original: 6wind.com; dkim=none (message not signed) header.d=none;6wind.com; dmarc=none action=none header.from=arm.com; x-ms-publictraffictype: Email X-MS-Office365-Filtering-Correlation-Id: 571e343f-8438-484f-a580-08d9667b9031 x-ms-traffictypediagnostic: DB6PR0801MB1960:|AM7PR08MB5334: x-ld-processed: f34e5979-57d9-4aaa-ad4d-b122a662184d,ExtAddr x-ms-exchange-transport-forked: True X-Microsoft-Antispam-PRVS: x-checkrecipientrouted: true nodisclaimer: true x-ms-oob-tlc-oobclassifiers: OLM:9508;OLM:9508; X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam-Untrusted: BCL:0; X-Microsoft-Antispam-Message-Info-Original: ejw/3Ofbfj/90FN/Tc4YHC+XAdvkaK2uE4TA2Aji4DvzgvLDT7+R44+6txvRFu2jCRO3ggnCCN2gR89cdOfZsHhspOvCBYWbeIO271qxLHEsjUT4OzBwWwUW2yXIL2Tp9q+Njwsq8Aq9U66CBsqknzc4C+PntrTelCBrGNx0/qXCMJZaNLtTE9Z4rqaYvROxFh4V4HUa48I4Z/y7ZpCL4ljW/R2V0qf414W/maIwA+mKZtMxxnIZAW2aF6TVddhuu1KxJ8MJ/hJKCjRMIn0bvoBfBALHXnZxQ7TE2c6OdQxChb/jIoM0qyYK4soJ6eHBDANV12DSQACpv5uocBGkoqYw5B1KvmFC1jDHmJTwi3ZtoS/uBGWCNTTffhp5XfSNz2V0npngn4HUsvHOxIgkvyKgWEIfNNU0qboALkH4TwbpxqU/WXAnCf9VcgTeYzhdj1nkynhVa8i6G9ZXwyXcM25YKbvmhfS+ib+vlW9XKyhyDq/xScHLEtAD0M8PaJKYrHivOLX4fVqMFRMFWRhUB1iwU7Ab9HjHia71ZDudbdQblTXc41NEL0y39TV7PbycGXVz0mMD1cDgCIPtmWbeOJvB5fy3d5QYtDn1CvrLqeyTIHQAh1dYzV/blS7dn3VUYcyQDRrPtEf+f0si0xA2rdNwuDPlKEv65LwNJyse1i8Iwk6tZ8dPcKA3NxgDk3mvSmM58cKBSQraNeeNjz+R9cbWrrh6iaMTa3JS9lG7ZzHXMBZuMrOoyuCiG8e62nBLNlc/lU2wD/X/670v/ha9LLlDa1YYw1CFrN/zxa3kRuo= X-Forefront-Antispam-Report-Untrusted: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:DBAPR08MB5814.eurprd08.prod.outlook.com; PTR:; CAT:NONE; SFS:(4636009)(366004)(346002)(396003)(136003)(376002)(39850400004)(33656002)(38070700005)(83380400001)(26005)(6506007)(9686003)(6916009)(71200400001)(52536014)(186003)(2906002)(8676002)(316002)(7696005)(122000001)(54906003)(66946007)(76116006)(64756008)(966005)(66556008)(66446008)(55016002)(4326008)(66476007)(5660300002)(86362001)(8936002)(478600001)(38100700002); DIR:OUT; SFP:1101; x-ms-exchange-antispam-messagedata-chunkcount: 1 x-ms-exchange-antispam-messagedata-0: =?us-ascii?Q?Z6CgrpKpTyGrFSTAkvLodNjmzG6xC/v5Vuq1Fw/NgHDzNUp8yOc8vK6mPD2U?= =?us-ascii?Q?2olHTLgrSishdtJs0hlTx0RTMr9wvB/Tma2mfPTcetSfuJhF+PdQywOkF57W?= =?us-ascii?Q?MMrOwvlyQn03ivwmPoIDzrU3mSGZroka5ftXL/X5B6OJvJXdD2pJOJjjS4i0?= =?us-ascii?Q?5g42ESixL9CYOlF92hnbj/6Q6tWUnN8qbjX8dq/5g3EbQlrS84uriFrCiV1B?= =?us-ascii?Q?1/dU1/pTPz9ulFIpH4mhE4+ZelATvZOItWPVlQS+XrIvQ8VGE1479YHR3W8c?= =?us-ascii?Q?Zxow/LtTRJy9w6TCwHhkAZ3zSkkhJ1n/Tqx4PG9gpg57GNhAJQTr9u0MrQYC?= =?us-ascii?Q?17yr/Ae+3C4COSwxr5hURxjqkykIo3pNTy1untQiqsx923wvjTxKkHhMdPpN?= =?us-ascii?Q?ljT8LUztfEaKQ4Z54TifbpIYTFanVM/Im17GA0E86G0827mnymmaxnUBIAgR?= =?us-ascii?Q?EQR2zHdl8/1r7rMnqhE5DMqeeR7KVxVk3LrWWRxVP5c/uOHm9wcpEB8b+Jq4?= =?us-ascii?Q?x5c2BojO2KROXt2Ap52BLiWipfzGgXaDLGsVWfRMPzVrv2Z/poG6mLBpMbKY?= =?us-ascii?Q?qg99LRY6PTU6CFZfKcbyBuD7csq2ITBeEyIXQj5OfM0L2Gott1HRBOlv7XhC?= =?us-ascii?Q?7B8CgZeZVRSRrmAoYgxLopYBU6w/MJH4RMSXaEqN7Zs3niN99qQb2Y5uJ86n?= =?us-ascii?Q?Mg+BkmAQjIiQj45YNJGQcyXdf9oo53tp+lbMEc9tiJph57PFDBhIhs7qR+4g?= =?us-ascii?Q?R5povJBRupYbQyvmwVX7+LQpDJg2hofcZQ6OMVOSgWYRcuiIDvYksxG2bdXZ?= =?us-ascii?Q?KliZ7pT+zTTW0ZwDLc0Y12MYxyyPMWk6ugbqybix5vpfI76eA8iI+nEZRlc0?= =?us-ascii?Q?HSj23gbMMw/0aWvOqGBRRdhdyJnmvyWxsVfjYgyuBRnJpldV4dyizgg/kK4d?= =?us-ascii?Q?VPxRv+GnnBRBI5WpoiGXF7TIqCzCuu3Pu2R6HJtKk+PUYa7BBXt3SSnWTNFq?= =?us-ascii?Q?8m0OcmlqCoIIHRu7+zb1SHIg6VQW2EyEiLOyTGUhTtbe6qi5U28TzHMpAjha?= =?us-ascii?Q?U8f7cA1z7Uybpx42eJKaxHvQ2/8VVr2/3Gfegpawp7hTeNOz/8kLvjzWeH1u?= =?us-ascii?Q?9oh2qjzERerF99ig4SUelkeLmXTCqNfqGLbqeVZ/cZQPf9FudyqHSfeBlxNS?= =?us-ascii?Q?dUeUaiInDvzlly1gAz/B/vI8CmZD+croLZlTpy7+v1AzobUUyp9oKgGnmrmh?= =?us-ascii?Q?JhQFS1KUOgmx1l1U10h5ip8Cp0fKyLkP3y09xFVJQmERw81Utxz6PzjgUmZt?= =?us-ascii?Q?DPJ5vr8G0zLoVnu6psNuqKeA?= Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-MS-Exchange-Transport-CrossTenantHeadersStamped: DB6PR0801MB1960 Original-Authentication-Results: 6wind.com; dkim=none (message not signed) header.d=none;6wind.com; dmarc=none action=none header.from=arm.com; X-EOPAttributedMessage: 0 X-MS-Exchange-Transport-CrossTenantHeadersStripped: AM5EUR03FT050.eop-EUR03.prod.protection.outlook.com X-MS-Office365-Filtering-Correlation-Id-Prvs: 85335618-45a6-43d1-02a6-08d9667b861b X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: VQgGa8Fdx63rj2axl/RtAoB4XcswkabJqJukD4zatjhjoZO7mNpVm3vmYH9q0c0FsZYBBb2v03f6MAth26Vw9hVs0Ix5l9ARS6tfB6BQIqgLYKO+Y2BvyqOWMNrfndIKGK89OBnJxbocsrFM42cgaGSNuxn2wFNLyo7dn26mg93N0xEZitFCHijupCTNz0NR0SMvecDgCNXNIMIfcmCvF9UpyzhOdJPeA4x5hQ1nFynyoNWMlDHLUscTRkjkjueFrlm927chfhESW1ZlJ4ZWvz3hFibXfoHMTZIRoYXzdNhXaw5Si5yrzKZ9T+vaCMst5NfEZL1pVIZuYPOPSpM3I2FgBThb3+fyID2bpEI6lvtGku6j1mvVJv5hyFUp+c2eNjmoRBOKGC8qMYwuEgXzNFyUsRAnNdRp2YZpyvVzrTd3jcH1G8jveh0jSfu9GHHBnWl29x7mPBdx3F7ucqbrp1PRPYzghVb5umkRam5oSFQogabQI0uLH7N5EatMnIgymjZOhUFjfxJhh7+r4vRmXPQovuU88SV1vtqquaqR6nEL9VJkpCQO/mGOJWwOLUmli+sGOsghHipSa77X3xffBYorIaMgEUCW/C4rA8/k7rG1iSI92wA3/BUsI38lijnj4G8EPyhhC+aF8ASRxNNKThc79uNxKw8kPvTQMqJrUi6zfmoDkmcXh/euGd+n76mXzZJCEY6C58PL/J4nujSkgp85ns3abc8lyqBfoWZd/nyj+h3gJGKbdGo3pBM5QfLpeusgFZqDEAie3G1xsEqdAQ== X-Forefront-Antispam-Report: CIP:63.35.35.123; CTRY:IE; LANG:en; SCL:1; SRV:; IPV:CAL; SFV:NSPM; H:64aa7808-outbound-1.mta.getcheckrecipient.com; PTR:ec2-63-35-35-123.eu-west-1.compute.amazonaws.com; CAT:NONE; SFS:(4636009)(346002)(396003)(39850400004)(136003)(376002)(46966006)(36840700001)(52536014)(356005)(54906003)(82310400003)(47076005)(70206006)(6862004)(70586007)(9686003)(8936002)(55016002)(316002)(8676002)(82740400003)(81166007)(4326008)(6506007)(7696005)(83380400001)(186003)(478600001)(336012)(26005)(966005)(36860700001)(86362001)(5660300002)(33656002)(2906002); DIR:OUT; SFP:1101; X-OriginatorOrg: arm.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 23 Aug 2021 21:18:33.5149 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 571e343f-8438-484f-a580-08d9667b9031 X-MS-Exchange-CrossTenant-Id: f34e5979-57d9-4aaa-ad4d-b122a662184d X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=f34e5979-57d9-4aaa-ad4d-b122a662184d; Ip=[63.35.35.123]; Helo=[64aa7808-outbound-1.mta.getcheckrecipient.com] X-MS-Exchange-CrossTenant-AuthSource: AM5EUR03FT050.eop-EUR03.prod.protection.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: AM7PR08MB5334 Subject: Re: [dpdk-dev] [PATCH] doc: abstract the behaviour of rte_ctrl_thread_create 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 Sender: "dev" > > > > > > 30/07/2021 23:44, Honnappa Nagarahalli: > > > > The current expected behaviour of the function > > > > rte_ctrl_thread_create is rigid which makes the implementation of t= he > function complex. > > > > Make the expected behaviour abstract to allow for simplified > > > > implementation. > > > > > > > > With this change, the calls to pthread_setaffinity_np can be moved > > > > to the control thread. This will avoid the use of > > > > pthread_barrier_wait and simplify the synchronization mechanism > > > > between rte_ctrl_thread_create and the calling thread. > > > > > > > > Signed-off-by: Honnappa Nagarahalli > > > > --- > > > > +* eal: The expected behaviour of the function > > > > +``rte_ctrl_thread_create`` > > > > + abstracted to allow for simplified implementation. The new > > > > +behaviour is > > > > + as follows: > > > > + Creates a control thread with the given name. The affinity of > > > > +the new > > > > + thread is based on the CPU affinity retrieved at the time > > > > +rte_eal_init() > > > > + was called, the dataplane and service lcores are then excluded. > > > > > > I don't understand what is different of the current API: > > > * Wrapper to pthread_create(), pthread_setname_np() and > > > * pthread_setaffinity_np(). The affinity of the new thread is based > > > * on the CPU affinity retrieved at the time rte_eal_init() was > > > called, > > > * the dataplane and service lcores are then excluded. > > My concern is for the word "Wrapper". I am not sure how much we are > bound by that to keep the code as a "wrapper". > > The new patch does not change the high level behavior. >=20 > I am ok to remove the word "wrapper" from the description, and I agree it= can > be better described without quoting the pthread_* functions. >=20 > > Are you saying you are ok with the patch without the deprecation notice= ? >=20 > I don't think it requires a deprecation notice if the API and ABI is left > unchanged. To be honnest, I find a bit hard to understand what is really > changed by reading the deprecation notice: Thanks Olivier. I agree, I was also not sure. The term "wrapper" made me fe= el that we are defining certain return codes to the application. At the macro level, I think the expected behavior remains the same. >=20 > > +* eal: The expected behaviour of the function > > +``rte_ctrl_thread_create`` > > + abstracted to allow for simplified implementation. The new > > +behaviour is > > + as follows: > > + Creates a control thread with the given name. The affinity of the > > +new > > + thread is based on the CPU affinity retrieved at the time > > +rte_eal_init() > > + was called, the dataplane and service lcores are then excluded. >=20 > I'll send my comments to your patch: > http://patches.dpdk.org/project/dpdk/patch/20210802051652.3611-1- > honnappa.nagarahalli@arm.com/ >=20 >=20 > Thanks, > Olivier