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 CBCEF45C9B; Wed, 13 Nov 2024 00:38:39 +0100 (CET) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 9C80B402BC; Wed, 13 Nov 2024 00:38:39 +0100 (CET) Received: from NAM10-DM6-obe.outbound.protection.outlook.com (mail-dm6nam10on2065.outbound.protection.outlook.com [40.107.93.65]) by mails.dpdk.org (Postfix) with ESMTP id 82EFD40265 for ; Wed, 13 Nov 2024 00:38:37 +0100 (CET) ARC-Seal: i=1; a=rsa-sha256; s=arcselector10001; d=microsoft.com; cv=none; b=xzuBIP8ecz7ZS4uC2ItN97MCyZ5zXX0/BocE2R8U2SRaJwyBYwcO3mb2rOtY2gy6Jgx8dTWwDr2cplvJZDR0Yf6JldxqtaaMbiHy6m567uAnXOT1SlbAyHU3TAKDqXdRpYJxqbsch92gg3XgMxOKrRuol7EAuJzVfrHibQxRteCXMBNTzNVxh7j5ZoyC8cYpPpmk2XPlDybq+uhSsdq0abo1IGZNoN7J90+dxLjeII7U7d3xSQ0WnePfW9l98cF1nAfRVFl5OZpTF4LiX2cq+GOKFcB0629pM677pm0LSrCCbFa5ecDGF1VykEdhs0R4ueyYsW71SAE5ZKb5L6alLw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector10001; 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=RKbOMOQBFlO5FSb+ANhIB4N4QUaoivJzCIRg0VAnrAo=; b=vvcxTdTlUwaNsy1TiSB8XoAsZiwI46KQN8teQk3fhOQ5Z88vMk9RsFsx1k3GH9yxTiibZUWPTVClmbOhQxOwv/b8IVFcvndnj2cSzXh3ZsnyRNkcH+HaZBJ079txiyZ5w3Tp4VJ/c6HAGC2by6eBhnfGjmZ/0Q5dYaccBfYoaDZ9ohKubZtWKmGkvbNruSp2h8YqTsAZilNhCFF6AbTvdqROLiMje1cG60gHhgeIY5eZZoVlArnKVww5Wttx0NSfHBo+pmDN0j2diPDCQQ08WDTkLMmXzPepQqcVFHDSnvEQvtrmWzyZxfDWajCvkI98yt76SwkPp24MapJ7EE/lYQ== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=amd.com; dmarc=pass action=none header.from=amd.com; dkim=pass header.d=amd.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=amd.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=RKbOMOQBFlO5FSb+ANhIB4N4QUaoivJzCIRg0VAnrAo=; b=0l9RtugKWTgs/Azec5t9EZ0Gg4Na6d59BQ34PPZhS+nSnh8Kux+/l8xQw09d54UlZc+z51YcmLw1gu7YTAeULmdIXi/8BDKsALZIIwf8XKKxKfuzthYXcmcRBtknccPcdSCVJqVZoHWRzyGVa6SioJj2FXguKx0qGFAP0zH/vNw= Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=amd.com; Received: from SJ2PR12MB8830.namprd12.prod.outlook.com (2603:10b6:a03:4d0::9) by SN7PR12MB7935.namprd12.prod.outlook.com (2603:10b6:806:349::11) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.8137.28; Tue, 12 Nov 2024 23:38:35 +0000 Received: from SJ2PR12MB8830.namprd12.prod.outlook.com ([fe80::c3eb:df02:eaa9:2055]) by SJ2PR12MB8830.namprd12.prod.outlook.com ([fe80::c3eb:df02:eaa9:2055%4]) with mapi id 15.20.8158.013; Tue, 12 Nov 2024 23:38:34 +0000 Message-ID: <150e064f-121f-4488-a67a-4307d847d154@amd.com> Date: Tue, 12 Nov 2024 23:38:29 +0000 User-Agent: Mozilla Thunderbird Subject: Re: [PATCH v7 07/17] net/r8169: add support for hardware operations To: Howard Wang , dev@dpdk.org Cc: pro_nic_dpdk@realtek.com References: <20241112095804.42091-1-howard_wang@realsil.com.cn> <20241112095804.42091-8-howard_wang@realsil.com.cn> Content-Language: en-US From: Ferruh Yigit In-Reply-To: <20241112095804.42091-8-howard_wang@realsil.com.cn> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit X-ClientProxiedBy: LO4P265CA0104.GBRP265.PROD.OUTLOOK.COM (2603:10a6:600:2c3::8) To SJ2PR12MB8830.namprd12.prod.outlook.com (2603:10b6:a03:4d0::9) MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: SJ2PR12MB8830:EE_|SN7PR12MB7935:EE_ X-MS-Office365-Filtering-Correlation-Id: 4b9c0437-7f51-4edb-ecff-08dd03731fd8 X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0;ARA:13230040|376014|366016|1800799024; X-Microsoft-Antispam-Message-Info: =?utf-8?B?bVl5VndESWZ2anBIL2gxOE1pNlFNTWxkdUdUbnVNbGxQbkhIL1l3Qnl5NmdW?= =?utf-8?B?aG94QW4rZ0dYY1UwR3JxRHZiMGl0NzdCajQ0K0tIVEEzZEh2eURLSXBhOWNv?= =?utf-8?B?a000aFhDanlLcE5jQ0YzUmF0RjV5dXFqdmoxR0JnZ2JEMnNEak9vSlpxRmhl?= =?utf-8?B?enBWcEpPVDBYMUR4a3J0ZHo4Y3VVNk83MlBVY3Z0VnI2ZG9qL2JwVlVxekhC?= =?utf-8?B?NHZGT1NZRjBxYms5d3JOTWljSHl4c2NUMTUydUt5MXhRRHBQdTVDd1dNdEJU?= =?utf-8?B?Z0FKQ01pNkZXKytUNDRmNEVLL2pJeDc5Yi9ZMjJ6RHpWZHRMUWI5Ny8ydngx?= =?utf-8?B?dVd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?B?MVl2OUt0R1dJSms3ajlTR0xtc3RKT3ZKU0lMajJuRmdYdDIwZHc1OEhXZ1R3?= =?utf-8?B?K1hOczJFWHNwS3laVHJiWUQwWDdkMHdyN1NmUE1kSFFEUkUwb2RmQ3ExdFps?= =?utf-8?B?NStWZ0dnNDE1MW9lM1ZNUEhkeFMvRDJvR2JscGpIdFJDU2I4ZEZ2UkozTzNr?= =?utf-8?B?OEdUYmhZNGNtdnNtOTJtWEtObW5qNndPZjFac2Q0ekdWaVlEVDZURDhQNkI3?= =?utf-8?B?dzJqMTVCbHhiU1grcE5MOFFVVUtJUkNUV1FTV2pxbHFtekp4VUVxTEVSVjFY?= =?utf-8?B?cXpRTXgrbytKU0lLeGxEckhVSnpvM2RQRGYrNFNoUkdnOUNVKzhHeTN3UTkw?= =?utf-8?B?Y2pJbjNSbHVEc3ZEcnlCTU1EZ1ZFT1Y3WEkzUUZnciswamFuS1ozeHVreXVt?= =?utf-8?B?TElwcXQ5SkdCZlFWdlZnUGt4WHNYM0FNYU11WURzaGFuQ2l6OEFxSFV3OFdQ?= =?utf-8?Q?HS95w+cW44FUIhAh1j/whvR1MiyI/ubHJawLxBV?= X-Forefront-Antispam-Report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:SJ2PR12MB8830.namprd12.prod.outlook.com; PTR:; CAT:NONE; SFS:(13230040)(376014)(366016)(1800799024); DIR:OUT; SFP:1101; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: =?utf-8?B?RkxhT3J3UXgzSVNhdTcyNHhUSW1TN0NrNjl5eVBFODZEYzh6VC8rcWhVaXR1?= =?utf-8?B?S0doOWZTM1docEFFUnRVbHJibTZwbUFDcE9PN2pYY2ptby93MFFmZjJBRkpw?= =?utf-8?B?TGtYV2xHbFNvRzRBdEg0azFZSUNsSWZ2UmpJSnIzWTR4ZFJ1ZGtsY2c4cmxs?= =?utf-8?B?Vz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eXZjTXlxTVdnMk5LMk5v?= =?utf-8?B?T3JEYUtGUUFlTE90bFkzYVgyWndZZG1tTmVXekEzbkJpcWx6eUZEeG1xU0Nn?= =?utf-8?B?U29Bci9kT2hqRy9EWk5aVzlOcU5vSlZxV0ViUCsreFgzQWlTdi9Tam1VSW01?= =?utf-8?Q?nhsNjYQ+6oKhO6RaMHijDNebt?= X-OriginatorOrg: amd.com X-MS-Exchange-CrossTenant-Network-Message-Id: 4b9c0437-7f51-4edb-ecff-08dd03731fd8 X-MS-Exchange-CrossTenant-AuthSource: SJ2PR12MB8830.namprd12.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 12 Nov 2024 23:38:34.9364 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 3dd8961f-e488-4e60-8e11-a82d994e183d X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: e+8LClJ7kqoL468SxqNUb1Bm0pnO2Go0d06xC28U8kbkS5KQt7qbXM6TnTFNis0g X-MS-Exchange-Transport-CrossTenantHeadersStamped: SN7PR12MB7935 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 11/12/2024 9:57 AM, Howard Wang wrote: > + > +#define TRUE 1 > +#define FALSE 0 > Also checkpatch has BOOL_COMPARISON warnings [1], technically "(hw->NotWrMcuPatchCode == TRUE)" can be "(hw->NotWrMcuPatchCode)" they are same. As you are defining TRUE & FALSE as above (since this is compatibility header, I understand the reason of defining them), check can be misleading, consider following case: hw->NotWrMcuPatchCode = FALSE; hw->NotWrMcuPatchCode += 3; if (hw->NotWrMcuPatchCode == TRUE) // The result is unexpected This is not hard requirement, except from checkpatch warning, but can you please double check? [1] CHECK:BOOL_COMPARISON: Using comparison to TRUE is error prone #396: FILE: drivers/net/r8169/base/rtl8125a.c:380: + if (hw->NotWrMcuPatchCode == TRUE) CHECK:BOOL_COMPARISON: Using comparison to TRUE is error prone #2403: FILE: drivers/net/r8169/base/rtl8125b.c:358: + if (hw->NotWrMcuPatchCode == TRUE) CHECK:BOOL_COMPARISON: Using comparison to TRUE is error prone #3617: FILE: drivers/net/r8169/base/rtl8125bp.c:83: + if (hw->NotWrMcuPatchCode == TRUE) CHECK:BOOL_COMPARISON: Using comparison to TRUE is error prone #4180: FILE: drivers/net/r8169/base/rtl8125d.c:212: + if (hw->NotWrMcuPatchCode == TRUE) CHECK:BOOL_COMPARISON: Using comparison to TRUE is error prone #5355: FILE: drivers/net/r8169/base/rtl8126a.c:495: + if (hw->NotWrMcuPatchCode == TRUE)