Skip to content
Commit 4ecdc381 authored by Tapasweni Pathak's avatar Tapasweni Pathak Committed by Greg Kroah-Hartman
Browse files

staging: rtl8723au: core: Replace open coded version with existing hweight function



This patch replaces the open coded version with Linux's existing hweight
functions.
The original version checked each of the low four bits, accumulating and
returning the result. Instead, use a mask to select those four bits, and
pass the result to hweight8.
It also makes the code in this function simpler.

Signed-off-by: default avatarTapasweni Pathak <tapaswenipathak@gmail.com>
Reviewed-by: default avatarJosh Triplett <josh@joshtriplett.org>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent 2430454e
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment