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 0ABAAA00C4; Wed, 12 Oct 2022 14:23:12 +0200 (CEST) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id ADD4A4303E; Wed, 12 Oct 2022 14:23:11 +0200 (CEST) Received: from NAM11-BN8-obe.outbound.protection.outlook.com (mail-bn8nam11on2041.outbound.protection.outlook.com [40.107.236.41]) by mails.dpdk.org (Postfix) with ESMTP id B844842EF7 for ; Wed, 12 Oct 2022 14:23:09 +0200 (CEST) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=bkTtlR9GA7KtB5vL5C6/VZMzPjdvXAHr9wGCLAOLMu+tBWfpazwPkQHO6DLypYHt8s5XX9pTUQuaIZ/YvtAllQv4KHHLV7cYyax1mGtwqOgLKmmOow7Ov1Vrbk87c00aTgPV8TTNmyPdmfn5X/R/H4m776vzPJAHL/uxuUc5Za9JizcE394pl4wpx+zpiwMeQZyOhCcS+UBwfWLCr93Ocuw8h2MHLQ/PfFM4rrDCWkQn4Vsg3Gdz6Kmxdq7/Z71+B5+NtDtE8gLRHUA7uVW7WkDYwSDMrPphgEzqPu8vlSe+PrZO4DLOP+odWyIpgrgZOMvA0QiUhQIPECuFYWh9UQ== 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=i+7yQsXq2CkOrd+EGtwUFsyaDmyP7LF6Wkz85+MD8bA=; b=JCCGspcX4tMPnzt7lrYoNpOhUfnFOL/4eoERQzIjspwq032yOWsfIHFRAtZ3zca1qiXG5BMmF592wM9e/z9URniNzHO6LdoRynWkGAYVXzaEPY1tQY/6DKRXjd1yRqlSdw9m5fG9k13Xz6XQ8mU+4XGH95ImsVdeaTILq4vP6UkEUV9PY4hpCEVFY8mzrw5iFtU7OlXbhW+sofjoj3AhpGekX7u3guJJOtEieeQABPPzZTCd5QUbyI0kLW7KYTeDg6rv+RANvVPuEzX7yBtCWOxvLJnKSoiCaSup1vxEXkmXFtnYYEmX0a2Of9nwATImEdA2/oqpxAPJaNry172ieQ== 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=i+7yQsXq2CkOrd+EGtwUFsyaDmyP7LF6Wkz85+MD8bA=; b=qv5kLjKBS4lkfzGGio/vtejVg1XIQrbRSr4uYxpszch8L+P6/EQu/TMfVfIBeFOeSe10AOlQu+njx+1mU8uW1SUai0neV+JMhQr9pyO6SaEwXl0L0BrmudwpYDG8twxczsqYI0aF9H0fBacVatxXHE1LbnWwG6VXT89WvmYN+l8= Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=amd.com; Received: from DM6PR12MB4297.namprd12.prod.outlook.com (2603:10b6:5:211::20) by BY5PR12MB4196.namprd12.prod.outlook.com (2603:10b6:a03:205::21) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5709.21; Wed, 12 Oct 2022 12:23:07 +0000 Received: from DM6PR12MB4297.namprd12.prod.outlook.com ([fe80::b9fd:e732:4585:6b25]) by DM6PR12MB4297.namprd12.prod.outlook.com ([fe80::b9fd:e732:4585:6b25%7]) with mapi id 15.20.5676.036; Wed, 12 Oct 2022 12:23:07 +0000 Message-ID: Date: Wed, 12 Oct 2022 13:23:03 +0100 User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:102.0) Gecko/20100101 Thunderbird/102.3.2 Subject: Re: [PATCH] net/bonding: fix socket_id type Content-Language: en-US To: Markus Theil , dev@dpdk.org Cc: Chas Williams , Min Hu , Thorben Roemer References: <20221012114523.9569-1-markus.theil@tu-ilmenau.de> From: Ferruh Yigit In-Reply-To: <20221012114523.9569-1-markus.theil@tu-ilmenau.de> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-ClientProxiedBy: LO4P123CA0627.GBRP123.PROD.OUTLOOK.COM (2603:10a6:600:294::15) To DM6PR12MB4297.namprd12.prod.outlook.com (2603:10b6:5:211::20) MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: DM6PR12MB4297:EE_|BY5PR12MB4196:EE_ X-MS-Office365-Filtering-Correlation-Id: 330c2e38-53cb-4fc2-fb5a-08daac4c84dc X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: 4mKSSQhOfavzXzXS70tkA2nrav6AhAnbaCKadCvt7H4bRomxTia14mAxnp7HyCh5/MgEgEaIektohSHFQm6I/SYoIESl+zIdThluwdew+7q3b6ajV8+yq7lqhxE2kaWXdEzBiyqyd7oqXnmJWYVHEr/nlJxqre0kPiCChuxs6dWV6OiBENcRq+Bb7Gbj+8VAGSMzLafM4aBqnK8YAIYFFmSo1HWq9tBQJo9ovonLYFnaJrI3pmGmcnzL0ReJMYH5O77C6vZCr1bauqu+i0oiPjWGtqReM9Fpi3WSzvonbve9DTVTS9Rs4EZtqsPEagzjpWO+LJmLdHB7mEDo9ruqaqSThNQ3qPrMJHXDHtCX1fRNgLpLz5Yo7PShgY69lvSY1DgilhCND027eM1qNyyRKoygl470ArnROulHyOtGE4BgA2aZAr2Bht0El+fl+D/Rg+YxUBlV0NEZHQLUUMJAr3C7Ug6R33ZpjU2b0BEOWl1o1Nb0Z5wvUE8fHYSvD8qoteVlpq8/91PSWpG6EdUBoLuIyAEwWrAFcgIJselvrMFUMus6sed+PI4MHgaH1uxWj1CH8voFWBE0IJ0DrGnOU4TlaD+enQqKcmgv4V0QRy+K9Ox+QvyaqpI3LHuXqmsX2iCLyYSqyJzH/zXg/fJcRTy6LFCMoux4MKNj4239uZRG+KlLsNox3/jGF5NGFG4TMqusw/sUOOEdWreU8BYE/Pjc4FZTwiHwxw5m3DsQ08w2IvRz5S4+vXgLaK0ip3PTous27OoXZtxE7gFi2oeyhz6pPTSoHT8eZZ+2J2aAHKE= X-Forefront-Antispam-Report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:DM6PR12MB4297.namprd12.prod.outlook.com; PTR:; CAT:NONE; SFS:(13230022)(4636009)(136003)(376002)(366004)(39860400002)(346002)(396003)(451199015)(53546011)(26005)(6666004)(6506007)(6512007)(31686004)(83380400001)(2616005)(186003)(478600001)(6486002)(316002)(44832011)(36756003)(66946007)(5660300002)(8676002)(54906003)(66476007)(4326008)(66556008)(41300700001)(2906002)(38100700002)(31696002)(86362001)(8936002)(45980500001)(43740500002); DIR:OUT; SFP:1101; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: =?utf-8?B?UEJ1THZLem0rNFViZE5FRnlyU1QrcGh5ZG80SnN3N3gzZWxpbVpISlc4di9F?= =?utf-8?B?NkFGQUlLTGVtUDJMTmN3WGxHUHd6Rks3dWU1OHl5cGZtWFRqU3lmV1VtWmlx?= =?utf-8?B?OUFUZ0V2RWdLYnNVUnN1a1hIMGlWNE9INWJ0WFdqdDhKVVF5SGZJRXY0SFJy?= =?utf-8?B?V3ZSU1dWczJBUUF3RHI0OGFmT3Zmd1o3cnBxT0JrQVl5bnd2ZERPWFlta0Zy?= =?utf-8?B?VEh6K3EvdHVEaG1XSDZTUFZmYlpVZE9iS0FvcTQrMU0wbGNOREQxTlBvU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SFJRNkRlVjlmK0hkZXNlaTFiNWdMOXBP?= =?utf-8?Q?IXnGMPM/U4xvHiTU9dK7HBZnf?= X-OriginatorOrg: amd.com X-MS-Exchange-CrossTenant-Network-Message-Id: 330c2e38-53cb-4fc2-fb5a-08daac4c84dc X-MS-Exchange-CrossTenant-AuthSource: DM6PR12MB4297.namprd12.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 12 Oct 2022 12:23:07.4787 (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: GDFp4JhlXN08gQ9CtHzvU3YX3EUdlwKFuENyCGnMtTe08PMcVoHzKHT4gjnsNx9L X-MS-Exchange-Transport-CrossTenantHeadersStamped: BY5PR12MB4196 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 10/12/2022 12:45 PM, Markus Theil wrote: > From: Thorben Roemer > > DPDK uses int or u32 in most other places for > socket IDs. Fix compilation warnings by also > using int in the bonding code. > Hi Markus, 'rte_eth_bond_create()' is part of API, so changing it impacts the users. Since 'rte_socket_id()' returns 'int', it is reasonable to make 'socket_id' parameter type 'int', but I am not sure if it worth the trouble it may cause in user end. Maybe we can announce the change in this release and update the API in v23.11? Can you please list the mentioned compile warning? > Signed-off-by: Thorben Roemer > --- > drivers/net/bonding/rte_eth_bond.h | 2 +- > drivers/net/bonding/rte_eth_bond_api.c | 2 +- > 2 files changed, 2 insertions(+), 2 deletions(-) > > diff --git a/drivers/net/bonding/rte_eth_bond.h b/drivers/net/bonding/rte_eth_bond.h > index 874aa91a5f..3ce2b29052 100644 > --- a/drivers/net/bonding/rte_eth_bond.h > +++ b/drivers/net/bonding/rte_eth_bond.h > @@ -99,7 +99,7 @@ extern "C" { > * Port Id of created rte_eth_dev on success, negative value otherwise > */ > int > -rte_eth_bond_create(const char *name, uint8_t mode, uint8_t socket_id); > +rte_eth_bond_create(const char *name, uint8_t mode, int socket_id); > > /** > * Free a bonded rte_eth_dev device > diff --git a/drivers/net/bonding/rte_eth_bond_api.c b/drivers/net/bonding/rte_eth_bond_api.c > index b44dd219cb..3c6e236382 100644 > --- a/drivers/net/bonding/rte_eth_bond_api.c > +++ b/drivers/net/bonding/rte_eth_bond_api.c > @@ -148,7 +148,7 @@ deactivate_slave(struct rte_eth_dev *eth_dev, uint16_t port_id) > } > > int > -rte_eth_bond_create(const char *name, uint8_t mode, uint8_t socket_id) > +rte_eth_bond_create(const char *name, uint8_t mode, int socket_id) > { > struct bond_dev_private *internals; > struct rte_eth_dev *bond_dev;