lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <595c352b-b8a2-6d73-b4d4-a042de51fa34@mellanox.com>
Date:   Thu, 21 Mar 2019 11:47:01 +0000
From:   Moshe Shemesh <moshe@...lanox.com>
To:     Jakub Kicinski <jakub.kicinski@...ronome.com>,
        Saeed Mahameed <saeedm@...lanox.com>
CC:     "David S. Miller" <davem@...emloft.net>,
        "netdev@...r.kernel.org" <netdev@...r.kernel.org>,
        Or Gerlitz <ogerlitz@...lanox.com>,
        John Hurley <john.hurley@...ronome.com>,
        Tariq Toukan <tariqt@...lanox.com>
Subject: Re: [net-next 09/15] net: Move the definition of the default Geneve
 udp port to public header file



On 3/21/2019 1:54 AM, Jakub Kicinski wrote:
> On Wed, 20 Mar 2019 16:39:53 -0700, Saeed Mahameed wrote:
>> From: Moshe Shemesh <moshe@...lanox.com>
>>
>> Move the definition of the default Geneve udp port from the geneve
>> source to the header file, so we can re-use it from drivers.
>> Modify existing drivers to use it.
>>
>> Signed-off-by: Moshe Shemesh <moshe@...lanox.com>
>> Reviewed-by: Or Gerlitz <ogerlitz@...lanox.com>
>> Cc: John Hurley <john.hurley@...ronome.com>
>> Cc: Jakub Kicinski <jakub.kicinski@...ronome.com>
>> Reviewed-by: Tariq Toukan <tariqt@...lanox.com>
>> Signed-off-by: Saeed Mahameed <saeedm@...lanox.com>
>> ---
>>   drivers/net/ethernet/netronome/nfp/flower/main.h | 2 +-
>>   drivers/net/geneve.c                             | 2 --
>>   include/net/geneve.h                             | 2 ++
>>   3 files changed, 3 insertions(+), 3 deletions(-)
>>
>> diff --git a/drivers/net/ethernet/netronome/nfp/flower/main.h b/drivers/net/ethernet/netronome/nfp/flower/main.h
>> index c0945a5fd1a4..7afe66eff684 100644
>> --- a/drivers/net/ethernet/netronome/nfp/flower/main.h
>> +++ b/drivers/net/ethernet/netronome/nfp/flower/main.h
>> @@ -35,7 +35,7 @@ struct nfp_app;
>>   #define NFP_FL_MASK_ID_LOCATION		1
>>   
>>   #define NFP_FL_VXLAN_PORT		4789
>> -#define NFP_FL_GENEVE_PORT		6081
>> +#define NFP_FL_GENEVE_PORT		GENEVE_UDP_PORT
> 
> Why not remove the now duplicated define and
> 
> s/NFP_FL_GENEVE_PORT/GENEVE_UDP_PORT/
> 
> throughout the code?

Just thought you would prefer it this way ...
Anyway, sure, I will change it.

> 
>>   /* Extra features bitmap. */
>>   #define NFP_FL_FEATS_GENEVE		BIT(0)
>> diff --git a/drivers/net/geneve.c b/drivers/net/geneve.c
>> index 5583d993480d..c05b1207358d 100644
>> --- a/drivers/net/geneve.c
>> +++ b/drivers/net/geneve.c
>> @@ -22,8 +22,6 @@
>>   
>>   #define GENEVE_NETDEV_VER	"0.6"
>>   
>> -#define GENEVE_UDP_PORT		6081
>> -
>>   #define GENEVE_N_VID		(1u << 24)
>>   #define GENEVE_VID_MASK		(GENEVE_N_VID - 1)
>>   
>> diff --git a/include/net/geneve.h b/include/net/geneve.h
>> index fc6a7e0a874a..bced0b1d9fe4 100644
>> --- a/include/net/geneve.h
>> +++ b/include/net/geneve.h
>> @@ -4,6 +4,8 @@
>>   
>>   #include <net/udp_tunnel.h>
>>   
>> +#define GENEVE_UDP_PORT		6081
>> +
>>   /* Geneve Header:
>>    *  +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
>>    *  |Ver|  Opt Len  |O|C|    Rsvd.  |          Protocol Type        |
> 

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ