mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
synced 2024-10-04 08:08:54 +00:00
ethtool: do not print warning for applications using legacy API
[ Upstream commit71891e2dab
] In kernel log ths message appears on every boot: "warning: `NetworkChangeNo' uses legacy ethtool link settings API, link modes are only partially reported" When ethtool link settings API changed, it started complaining about usages of old API. Ironically, the original patch was from google but the application using the legacy API is chrome. Linux ABI is fixed as much as possible. The kernel must not break it and should not complain about applications using legacy API's. This patch just removes the warning since using legacy API's in Linux is perfectly acceptable. Fixes:3f1ac7a700
("net: ethtool: add new ETHTOOL_xLINKSETTINGS API") Signed-off-by: Stephen Hemminger <stephen@networkplumber.org> Signed-off-by: David Decotigny <decot@googlers.com> Signed-off-by: David S. Miller <davem@davemloft.net> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
parent
d3ccc74c89
commit
d7e3ea5326
1 changed files with 2 additions and 13 deletions
|
@ -754,15 +754,6 @@ static int ethtool_set_link_ksettings(struct net_device *dev,
|
||||||
return dev->ethtool_ops->set_link_ksettings(dev, &link_ksettings);
|
return dev->ethtool_ops->set_link_ksettings(dev, &link_ksettings);
|
||||||
}
|
}
|
||||||
|
|
||||||
static void
|
|
||||||
warn_incomplete_ethtool_legacy_settings_conversion(const char *details)
|
|
||||||
{
|
|
||||||
char name[sizeof(current->comm)];
|
|
||||||
|
|
||||||
pr_info_once("warning: `%s' uses legacy ethtool link settings API, %s\n",
|
|
||||||
get_task_comm(name, current), details);
|
|
||||||
}
|
|
||||||
|
|
||||||
/* Query device for its ethtool_cmd settings.
|
/* Query device for its ethtool_cmd settings.
|
||||||
*
|
*
|
||||||
* Backward compatibility note: for compatibility with legacy ethtool,
|
* Backward compatibility note: for compatibility with legacy ethtool,
|
||||||
|
@ -789,10 +780,8 @@ static int ethtool_get_settings(struct net_device *dev, void __user *useraddr)
|
||||||
&link_ksettings);
|
&link_ksettings);
|
||||||
if (err < 0)
|
if (err < 0)
|
||||||
return err;
|
return err;
|
||||||
if (!convert_link_ksettings_to_legacy_settings(&cmd,
|
convert_link_ksettings_to_legacy_settings(&cmd,
|
||||||
&link_ksettings))
|
&link_ksettings);
|
||||||
warn_incomplete_ethtool_legacy_settings_conversion(
|
|
||||||
"link modes are only partially reported");
|
|
||||||
|
|
||||||
/* send a sensible cmd tag back to user */
|
/* send a sensible cmd tag back to user */
|
||||||
cmd.cmd = ETHTOOL_GSET;
|
cmd.cmd = ETHTOOL_GSET;
|
||||||
|
|
Loading…
Reference in a new issue