diff options
| author | Mark Peek <mp@FreeBSD.org> | 2024-03-13 23:53:07 +0000 |
|---|---|---|
| committer | Mark Peek <mp@FreeBSD.org> | 2024-03-14 00:05:19 +0000 |
| commit | 63a7c4be4ad524629292eee659d6542f1c5e9c21 (patch) | |
| tree | 7b96b6e36dd1136e6fbcc7789441888ab3569088 | |
| parent | 220ee18f196482c534a659d1eb50db26c54ca7d0 (diff) | |
| download | src-63a7c4be4ad524629292eee659d6542f1c5e9c21.tar.gz src-63a7c4be4ad524629292eee659d6542f1c5e9c21.zip | |
hyperv/hn: Don't return error when setting media to autoselect
Setting media to autoselect would always return EOPNOTSUPP.
As autoselect is the only valid media, this change now returns
success instead.
PR: 264253
Reported by: Prakash Shiva <prakashs0234@gmail.com>
Reviewed by: Dexuan Cui <decui microsoft com>, whu
Approved by: whu
MFC after: 2 weeks
| -rw-r--r-- | sys/dev/hyperv/netvsc/if_hn.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/sys/dev/hyperv/netvsc/if_hn.c b/sys/dev/hyperv/netvsc/if_hn.c index 9949e0a16ab1..9f51f5b32199 100644 --- a/sys/dev/hyperv/netvsc/if_hn.c +++ b/sys/dev/hyperv/netvsc/if_hn.c @@ -1103,7 +1103,8 @@ static int hn_ifmedia_upd(if_t ifp __unused) { - return EOPNOTSUPP; + /* Ignore since autoselect is the only defined and valid media */ + return (0); } static void |
