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 17105A0548; Thu, 11 Nov 2021 09:51:36 +0100 (CET) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id F0C58410EF; Thu, 11 Nov 2021 09:51:35 +0100 (CET) Received: from EUR02-VE1-obe.outbound.protection.outlook.com (mail-eopbgr20079.outbound.protection.outlook.com [40.107.2.79]) by mails.dpdk.org (Postfix) with ESMTP id 15A4740E28 for ; Thu, 11 Nov 2021 09:51:35 +0100 (CET) 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=11WcnQXokN5aI7hd8X5TjAUixUzYqqU4mkr4qaLM3f8=; b=veAtqs9Uk4FipuzELgow+kpLhPBrmFyhAAHO/pMUV5T6+mIzRgdWQ361oGeM6msPb1RAskrP6347CV5MTdSBYzUY5h0I15CcAoLmlQ43yatZ5YACxLOMYJQ4ijKUnK0rOfrSLVnBZxg6HO5LvPp8+6P0YHetGQO7I3mWtXyeMWk= Received: from DB6PR0501CA0026.eurprd05.prod.outlook.com (2603:10a6:4:67::12) by AM6PR08MB5541.eurprd08.prod.outlook.com (2603:10a6:20b:74::22) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4669.13; Thu, 11 Nov 2021 08:51:33 +0000 Received: from DB5EUR03FT038.eop-EUR03.prod.protection.outlook.com (2603:10a6:4:67:cafe::14) by DB6PR0501CA0026.outlook.office365.com (2603:10a6:4:67::12) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4690.19 via Frontend Transport; Thu, 11 Nov 2021 08:51:33 +0000 X-MS-Exchange-Authentication-Results: spf=pass (sender IP is 63.35.35.123) smtp.mailfrom=arm.com; dkim=pass (signature was verified) header.d=armh.onmicrosoft.com;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 DB5EUR03FT038.mail.protection.outlook.com (10.152.21.84) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4690.19 via Frontend Transport; Thu, 11 Nov 2021 08:51:33 +0000 Received: ("Tessian outbound c71e1a752bff:v108"); Thu, 11 Nov 2021 08:51:33 +0000 X-CR-MTA-TID: 64aa7808 Received: from 91b0377a0603.3 by 64aa7808-outbound-1.mta.getcheckrecipient.com id 855206CA-E0E3-4D88-B3B1-E0604E76A1F5.1; Thu, 11 Nov 2021 08:51:23 +0000 Received: from EUR04-VI1-obe.outbound.protection.outlook.com by 64aa7808-outbound-1.mta.getcheckrecipient.com with ESMTPS id 91b0377a0603.3 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384); Thu, 11 Nov 2021 08:51:23 +0000 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=KunuloZmeg3aWacoqtsfuwYeD3GVxrKMTWKWdXHQOoXV/X/yysOJahYvYQzVhC8n1GvRrOBMnVFi8q72/l1lgQQCtFnQ2NAY4Nu7TP5fgLb5rrpYJrbfbdBV3qczpY2WxkWKZpQQSxiua8m9FM2j+/kjL+IVFxOOli0XpJsBXZ5SMyc24PgUJ2qhXBFB7vgZvwFoQn9RjDbJmYjRWlINZXdSoP02pbQM6ESYWZ8WPwLgnyNLN6VXptUpNy/4Ka9IVIOxmxnKXs2K8uF5ReoeuZk1zxAYFQZF8j0tgGP1T8Wu8INyL1K34RgX9LNzkAsFwGgFTsQr5IUgRPNhnDexow== 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=11WcnQXokN5aI7hd8X5TjAUixUzYqqU4mkr4qaLM3f8=; b=AT4lgmozHzuaVlK9N9F19VM4/ex3JqfhUk3nssiFnUpHVFhYy1CIVxdZuX+gIvN8ukJDWSGgDUK9cVsVAefWhKEGVNztx5ElYNyqAxoI4/5cW2wtULBo80Qk0r6T+KXrhy2P96R7WG/KFWNJUlV6sG/cAZj8cTpaBw7uC8F8pVesNbvjs4tfLa0xieV8h9ZiR/RHUoiwGy6fLX6M8SXgpVkJHmITHFri+IKzE6WPCVjNuWOZ4V8jtezvRqiD1FIFItV9fQ9nP2GERq7ID+Ns0LpdsNzsIs79L2d+t+W7Ri07hTk63wdxW2v122HXw9c3RKC7H2PP0WDy+L6N6cWsog== 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=11WcnQXokN5aI7hd8X5TjAUixUzYqqU4mkr4qaLM3f8=; b=veAtqs9Uk4FipuzELgow+kpLhPBrmFyhAAHO/pMUV5T6+mIzRgdWQ361oGeM6msPb1RAskrP6347CV5MTdSBYzUY5h0I15CcAoLmlQ43yatZ5YACxLOMYJQ4ijKUnK0rOfrSLVnBZxg6HO5LvPp8+6P0YHetGQO7I3mWtXyeMWk= Received: from DU2PR08MB7287.eurprd08.prod.outlook.com (2603:10a6:10:2d6::20) by DU2PR08MB7342.eurprd08.prod.outlook.com (2603:10a6:10:2f1::6) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4628.16; Thu, 11 Nov 2021 08:51:20 +0000 Received: from DU2PR08MB7287.eurprd08.prod.outlook.com ([fe80::455c:4503:6b3a:1b05]) by DU2PR08MB7287.eurprd08.prod.outlook.com ([fe80::455c:4503:6b3a:1b05%8]) with mapi id 15.20.4690.019; Thu, 11 Nov 2021 08:51:20 +0000 From: Joyce Kong To: Honnappa Nagarahalli , "thomas@monjalon.net" , "david.marchand@redhat.com" , Ruifeng Wang , "konstantin.ananyev@intel.com" , "rsanford@akamai.com" , "erik.g.carrillo@intel.com" , "olivier.matz@6wind.com" , "yipeng1.wang@intel.com" , "sameh.gobriel@intel.com" , "bruce.richardson@intel.com" , "vladimir.medvedkin@intel.com" , "anatoly.burakov@intel.com" , "andrew.rybchenko@oktetlabs.ru" , "jerinj@marvell.com" , "declan.doherty@intel.com" , "ciara.power@intel.com" , "xiaoyun.li@intel.com" , "nicolas.chautru@intel.com" , "maryam.tahhan@intel.com" , "reshma.pattan@intel.com" , "cristian.dumitrescu@intel.com" , "Yigit, Ferruh" CC: "dev@dpdk.org" , nd , nd Subject: RE: [PATCH v1 10/12] app/testpmd: use compiler atomic builtins for port sync Thread-Topic: [PATCH v1 10/12] app/testpmd: use compiler atomic builtins for port sync Thread-Index: AQHX1b+SMRwKSP3pZkqJ+fX5j/IMXav9/K+A Date: Thu, 11 Nov 2021 08:51:19 +0000 Message-ID: References: <20210802101847.3462-1-joyce.kong@arm.com> <20210802101847.3462-11-joyce.kong@arm.com> In-Reply-To: Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-ts-tracking-id: 1C4EC6F4AB60F140B4A4D8D83ECAB5CC.0 x-checkrecipientchecked: true Authentication-Results-Original: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=arm.com; x-ms-publictraffictype: Email X-MS-Office365-Filtering-Correlation-Id: ca3e6e0c-270d-4304-a29e-08d9a4f0764e x-ms-traffictypediagnostic: DU2PR08MB7342:|AM6PR08MB5541: x-ld-processed: f34e5979-57d9-4aaa-ad4d-b122a662184d,ExtAddr X-Microsoft-Antispam-PRVS: x-checkrecipientrouted: true nodisclaimer: true x-ms-oob-tlc-oobclassifiers: OLM:6430;OLM:6430; X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam-Untrusted: BCL:0; X-Microsoft-Antispam-Message-Info-Original: 2+ccl4NYJap0C+PA0iAdHfYhCQQr59jcPw/hlQlDWpZTliFQYL+GuWdKNCnuJwqB5HhFSacU/RikmQLgusyaeLamVbg7vd4N7GvaOYwnF8rDWYEI5UFizPU/kfkKlYk0eCR4gbIiuAJFJaL4y88JWnDptDPcEc2RpfWvdYp0gmjr44HHNR3GLhZn48AiaGsAJdf6gilEvj7k1sMrR1Kx7zl1FGJ0xSYi/JKWG/PFo6n322hokaUO3ATz7yPgLVudQl1nYV4wqIBBcqgAEtgsHyqqYGm0D99ZqZyFYJntw9d/wz1pH2dc1cVOrKJm5ENzWGa+3B2+CPJ0HLD0U8uYxuCtmf/TDiOEdSMaKQbpekagFUtkLNqUIQAgpLz9U1dxBwLgtORcHJWR8SZa56Ap3UFUOjHMJ5qNfcsP4tYDgq/XvExtTSxy029WV6zMZ7bO+FcmY9HW+DtJz4uR00ILm/CDluLvd0/cieOveKCbFSPqJY8aNORcf3QLeoIq9rEqVO0/q0XQihxibeUvW4SONKgE4D5XfkN32D0cuf081pePwerWWcImjTndglcxKOCM9SvGvj35xv9FwOE2dYq25REBHn2B8EMvQ93ytBM00s9BXNnohRTFxuuQ4cDsyj2JfdFEC/j5OIikIHElPAR9np8LxFhASc+R+W+f3/xEq1thClsz2R5OMmjG+/nkiWY3OBK9rrlypIKK1/VzF7zp2NpyyU+6hCwLCwd+i3A73bw= X-Forefront-Antispam-Report-Untrusted: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:DU2PR08MB7287.eurprd08.prod.outlook.com; PTR:; CAT:NONE; SFS:(4636009)(366004)(4744005)(26005)(52536014)(7416002)(66946007)(9686003)(71200400001)(64756008)(4326008)(508600001)(33656002)(38070700005)(66556008)(66476007)(316002)(2906002)(921005)(186003)(122000001)(55016002)(66446008)(110136005)(5660300002)(76116006)(54906003)(8676002)(38100700002)(7696005)(83380400001)(86362001)(8936002)(6506007); DIR:OUT; SFP:1101; Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-MS-Exchange-Transport-CrossTenantHeadersStamped: DU2PR08MB7342 Original-Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=arm.com; X-EOPAttributedMessage: 0 X-MS-Exchange-Transport-CrossTenantHeadersStripped: DB5EUR03FT038.eop-EUR03.prod.protection.outlook.com X-MS-Office365-Filtering-Correlation-Id-Prvs: df66df59-16d3-4ed6-b5d5-08d9a4f06e64 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: AITBQTaIeOUqLRHM3iRiUTozkLAPqHG9HSFxojmoFDoeUPTzghr41M9DPdq02+G47HUlBd3V4+DF9R0ULjSRFwkkHnmTZxFd9QfZt9kgtqLu9vAiOwMzYpVTYYDk6if6c5epuk7ECTdj7MnTFx5rbAb1PZ4QBCeE6wbjyBTjiqzYFXN5MlmjumBHWIvoiI8IPdZRpXYdC4UFZa28yhTV4yx/dDAdqU4hKzM/NcpJP1FCNw53kFdmJvCcREdBZwpHMVj5L9mnEhsFdUyZJ+ppGspkNSbSK6in53dAFNRj0LxVeTnjLlZDMHLeIiJ4R6IC4ZZBmDy3c5TxuZ2ryeg9IV2cwFmoahcOniqy6lecXm3VBsR5ao8DpJBZlKogoyNhW6iYh2y540T3++A/2BQFjGI3aQAtPxYgbWJyesl9CBikXSdHtAfqSX3WfeJ0ZCBzZjJF1W+UPVeNKNZPM9WhYIFb+Desqsd3q66enZkhb/BlnA6kPUVuKqI0pJtsX1h3IEJDtPmqyhMuq9Lrbxw+tKgNQ4zPa2obWgeh2fmlNzJj+rEhBINIOWsGYaZFrIrdETV/4wLLO7OePcFg9pPEIPCxvqiQgOlVG+aUDcrXwF5jHWam2bTAWUEVoEh01U6yLSv7dRMT9bD+C9g5MEXO5Yq4eRzJiXTtqPYRRUjsvf6x1DfzbMvfbFrUgSTDlYhRrE25HgkUJN50Xo0opd2oNgaxcEcholLZwnPztYceCO4= 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)(46966006)(36840700001)(356005)(4326008)(921005)(5660300002)(54906003)(55016002)(81166007)(4744005)(7696005)(33656002)(8676002)(110136005)(9686003)(316002)(8936002)(82310400003)(2906002)(36860700001)(47076005)(26005)(186003)(52536014)(336012)(86362001)(83380400001)(6506007)(508600001)(70206006)(70586007); DIR:OUT; SFP:1101; X-OriginatorOrg: arm.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 11 Nov 2021 08:51:33.3537 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: ca3e6e0c-270d-4304-a29e-08d9a4f0764e 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: DB5EUR03FT038.eop-EUR03.prod.protection.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: AM6PR08MB5541 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 > + Ferruh >=20 > >=20 > Hi Joyce/Ferruh, > I do not think the port_status changes need to be handled atomically= . The > changes to port_status do not seem to be happening from multiple threads. > It seems to be getting modified during initialization or through the test= pmd > prompt. >=20 > Do we really need atomic operations on port_status? >=20 Hi Honnappa, Seem you are right, I shall remove the atomic operations for port_status. Joyce > > > > Replace rte_atomic16_cmpset operation with compiler atomic CAS > > operation for port status sync in testpmd case. > > > > Signed-off-by: Joyce Kong > > Reviewed-by: Ruifeng Wang > > --- > > app/test-pmd/testpmd.c | 75 > > +++++++++++++++++++++++++++--------------- > > 1 file changed, 48 insertions(+), 27 deletions(-) > >