Re: [PATCH] ethtool: fix SPEED_UNKNOWN definition to avoid signed-unsigned comparison

2019-04-03 Thread Zhivich, Michael
On 4/2/19, 4:26 PM, "David Miller" wrote: > From: Michael Zhivich > Date: Mon, 1 Apr 2019 13:14:28 -0400 > >> When building C++ userspace code that includes ethtool.h >> with "-Werror -Wall", g++ complains about signed-unsigned comparison in >> ethtool_validate_speed() due to definition of SPEE

Re: [PATCH] ethtool: fix SPEED_UNKNOWN definition to avoid signed-unsigned comparison

2019-04-02 Thread David Miller
From: Michael Zhivich Date: Mon, 1 Apr 2019 13:14:28 -0400 > When building C++ userspace code that includes ethtool.h > with "-Werror -Wall", g++ complains about signed-unsigned comparison in > ethtool_validate_speed() due to definition of SPEED_UNKNOWN as -1. > > Change definition of SPEED_UNKN

[PATCH] ethtool: fix SPEED_UNKNOWN definition to avoid signed-unsigned comparison

2019-04-01 Thread Michael Zhivich
When building C++ userspace code that includes ethtool.h with "-Werror -Wall", g++ complains about signed-unsigned comparison in ethtool_validate_speed() due to definition of SPEED_UNKNOWN as -1. Change definition of SPEED_UNKNOWN to UINT_MAX to match the type of ethtool_validate_speed() argument