]> git.baikalelectronics.ru Git - kernel.git/commit
ethtool: netlink: Slightly simplify 'ethnl_features_to_bitmap()'
authorChristophe JAILLET <christophe.jaillet@wanadoo.fr>
Sun, 28 Nov 2021 11:03:30 +0000 (12:03 +0100)
committerJakub Kicinski <kuba@kernel.org>
Tue, 30 Nov 2021 04:16:46 +0000 (20:16 -0800)
commit0b17be2a4dd5ac1334d8e0ae7c0b26f4fed71af8
treec2b390cca7821520d5791b2a90a807af6310475d
parente2aaf4fdbb6913a082b49241427e31a86c9168da
ethtool: netlink: Slightly simplify 'ethnl_features_to_bitmap()'

The 'dest' bitmap is fully initialized by the 'for' loop, so there is no
need to explicitly reset it.

This also makes this function in line with 'ethnl_features_to_bitmap32()'
which does not clear the destination before writing it.

Signed-off-by: Christophe JAILLET <christophe.jaillet@wanadoo.fr>
Link: https://lore.kernel.org/r/17fca158231c6f03689bd891254f0dd1f4e84cb8.1638091829.git.christophe.jaillet@wanadoo.fr
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
net/ethtool/features.c