]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
net: pcs: xpcs: remove return statements in void function
authorRussell King (Oracle) <rmk+kernel@armlinux.org.uk>
Thu, 17 Oct 2024 11:53:10 +0000 (12:53 +0100)
committerPaolo Abeni <pabeni@redhat.com>
Wed, 23 Oct 2024 14:10:16 +0000 (16:10 +0200)
commitfd4056db7aee901677a3c62534b2d31b38678cb4
tree41a80d261c8b762aa86967e0fe818939afc4e34b
parent11afdf3b2ecee038dda8a38b6b6e6d232e64a210
net: pcs: xpcs: remove return statements in void function

While using "return" when calling a void returning function inside a
function that returns void doesn't cause a compiler warning, it looks
weird. Convert the bunch of if() statements to a switch() and remove
these return statements.

Signed-off-by: Russell King (Oracle) <rmk+kernel@armlinux.org.uk>
Tested-by: Serge Semin <fancer.lancer@gmail.com>
Signed-off-by: Paolo Abeni <pabeni@redhat.com>
drivers/net/pcs/pcs-xpcs.c