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 AA839A0C46; Wed, 9 Jun 2021 17:52:17 +0200 (CEST) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 295F14069B; Wed, 9 Jun 2021 17:52:17 +0200 (CEST) Received: from mail-lf1-f51.google.com (mail-lf1-f51.google.com [209.85.167.51]) by mails.dpdk.org (Postfix) with ESMTP id 4D88B4003C for ; Wed, 9 Jun 2021 17:52:15 +0200 (CEST) Received: by mail-lf1-f51.google.com with SMTP id a1so29025651lfr.12 for ; Wed, 09 Jun 2021 08:52:15 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=date:from:to:cc:subject:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=mHXSFBwQz7IYrtohqmdFmCqn56CiqYhstQYdC+7WSOw=; b=O63/6j/JiVerSv7YOpYM/NLVm9Yq9oa463mlbk0oSqszl6BJpNn9H9o+H475ei0bVu tADem8nZryU8ijjl+v5OLKQLMAfAlep1h/VFt61yrYAm//RlM+gZR9Bszq9yvGKKGOcC xFjFIMhiyqMW2p0FbMckGKdOkMO06rSqwniILJ1Vp2uV3RtIEKucWfnnQA8Qbx5G+QPj 6ioCGjop5SiMJCze6tz7SuWwxc8GPJ/e7PiSZtMLOaD454S7Men0rQOfCUORvfksLGUx 9DgvAePPwoa3HZBX9bsDXQ3MVJVtqvk0DmFxncQ1T0DOfo0Wjjy4n3mMxuSg92NzBsbV 4tIg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=mHXSFBwQz7IYrtohqmdFmCqn56CiqYhstQYdC+7WSOw=; b=W7tJp98X9TnPVByhGeS6kh/876aGsC7VTHe4+J8KjBB5UGOM9rmlJWMVseb7rXR/HF h7Xg0u5C4MB7c23tSMK57qZelkTzwQo6UMSZ3dN1aqf+TP+7yP+0mGX1gdgb8g/2lzpS lVVr+s+CKNtWeZ5nx7YauHlGm7RCP+rLOZbDN46dgmszWjIPrBpOWAXzH9ndxXqY5kd5 /NGGn+vze2fOIW0GPKx0yzU00GQQExit5NyRkGlN9Rwlz3y4/UsGmA+SJ4PsGHJfIA/G o/4h5bOFGBHchz4Q80hcdNasFitD0KG+KTCQrdNnSmQ/UjIbYB+HQw1NR1jMAopawSg3 oJdQ== X-Gm-Message-State: AOAM533k7h/CCp8DxtYvrc27YkYdBnG2PFZQm1pK8fz9Rqjb6axeVoah BZMnqBTOrHxjt2TtRAD44EM= X-Google-Smtp-Source: ABdhPJx85Ixy8ajvNjpy5D8G45YdEgH0zjbcdcfodr2OSifUgAYXYna99nrjI58kugrc5ShmZUJeWg== X-Received: by 2002:a05:6512:2289:: with SMTP id f9mr140412lfu.142.1623253934763; Wed, 09 Jun 2021 08:52:14 -0700 (PDT) Received: from sovereign (broadband-37-110-65-23.ip.moscow.rt.ru. [37.110.65.23]) by smtp.gmail.com with ESMTPSA id g24sm20488lfv.228.2021.06.09.08.52.13 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 09 Jun 2021 08:52:14 -0700 (PDT) Date: Wed, 9 Jun 2021 18:52:12 +0300 From: Dmitry Kozlyuk To: Akhil Goyal Cc: "dev@dpdk.org" , Ferruh Yigit , Fiona Trahe , Ashish Gupta , Khoa To , Ray Kinsella , Neil Horman , Thomas Monjalon , "bruce.richardson@intel.com" , Konstantin Ananyev , Jerin Jacob Kollanukkaran , "Zhang, Roy Fan" Message-ID: <20210609185212.4786eca3@sovereign> In-Reply-To: References: <20210310235421.23259-1-dmitry.kozliuk@gmail.com> <20210520184254.16790-1-dmitry.kozliuk@gmail.com> <20210520223140.6bef6046@sovereign> X-Mailer: Claws Mail 3.17.6 (GTK+ 2.24.32; x86_64-pc-linux-gnu) MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Subject: Re: [dpdk-dev] [EXT] [PATCH v3] doc: announce API changes for Windows compatibility 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" 2021-05-20 20:17 (UTC+0000), Akhil Goyal: > > > > 2021-05-20 18:59 (UTC+0000), Akhil Goyal: > > > > Windows system headers define `s_addr`, `min`, and `max` macros which > > > > break structure definitions containing fields with one of these names. > > > > Undefining those macros would break consumer code that relies on > > them. > > > > > > > > > > From the commit message the requirement for changing the structure > > definitions > > > Is not clear. Please note that 'min' - 'max' are not macros. These are > > variables of a > > > structure which should not break any other structure/Macro in windows. > > > > Err, yes, that's what the commit message says. > > Structure fields of course break nothing; they are broken by Windows > > macros. > > Would this make more sense? > > > > > > Windows headers define `s_addr`, `min`, and `max` as macros. > > If DPDK headers are included after Windows ones, DPDK structure > > definitions containing fields with these names get broken. > > If DPDK headers undefined these macros, it could break consumer > > code > > relying on these macros. It is proposed to rename structure fields > > in DPDK, because Win32 headers are more widely used and harder > > to fix. > > Yes it makes more sense now. But ideally it should be fixed in windows. > This may be just one such issue, there may be many more. > Will this also mean that nobody can define a local variable 'min'? > Is this acceptable? Only in public headers. There happens to be one such, rte_lru_x86.h. > Any macro definition in a subsystem should have a prefix to denote that, > Just like in DPDK 'RTE_' is added. > Macros with generic names should be avoided so that we do not get into > these issues. > > Adding more people for comments. I don't have a good feeling about > this change. Friendly ping to everyone Akhil cc'ed. As far as I understand, if we want to fix it in 21.11, deprecation notice should make it into 21.08.