summaryrefslogtreecommitdiffstats
path: root/kernel/trace/trace_stat.h
diff options
context:
space:
mode:
authorMichael Straube <straube.linux@gmail.com>2018-06-27 19:36:47 +0200
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2018-06-28 15:46:01 +0200
commit375a2bd2758395ecf8aed01ea264953afede6a4f (patch)
tree3747a78534f847b709e318688560f4fde947a5a1 /kernel/trace/trace_stat.h
parentstaging: rtl8723bs: fix comparsion to NULL - coding style (diff)
downloadlinux-375a2bd2758395ecf8aed01ea264953afede6a4f.tar.xz
linux-375a2bd2758395ecf8aed01ea264953afede6a4f.zip
staging: rtl8723bs: refactor rtw_macaddr_cfg()
Using is_broadcast_ether_addr() and is_zero_ether_addr() instead of testing each byte of the mac[] array for 0xff and 0x00 shortens the code and improves readability. If np == NULL, of_get_property() returns NULL, hence the "np" check is not needed. Instead of a fixed default mac address use a random one to reduce the likelihood of mac address collision. Thanks to Joe Perches and Dan Carpenter. Suggested-by: Joe Perches <joe@perches.com> Suggested-by: Dan Carpenter <dan.carpenter@oracle.com> Signed-off-by: Michael Straube <straube.linux@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'kernel/trace/trace_stat.h')
0 files changed, 0 insertions, 0 deletions