[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-ID: <20200423094547.2066-1-yi.zhao@windriver.com>
Date: Thu, 23 Apr 2020 17:45:47 +0800
From: Yi Zhao <yi.zhao@...driver.com>
To: <linville@...driver.com>, <netdev@...r.kernel.org>
Subject: ethtool -s always return 0 even for errors
Hi,
The ethtool -s returns 0 when it fails with an error (stderr):
$ ethtool -s eth0 duplex full
Cannot advertise duplex full
$ echo $?
0
$ ethtool -s eth0 speed 10
Cannot advertise speed 10
$ echo $?
0
$ ethtool -s eth1 duplex full
Cannot get current device settings: No such device
not setting duplex
$ echo $?
0
Is this a correct behavior of ethtool?
Thanks,
Yi
Powered by blists - more mailing lists