Date: Wed, 8 Mar 2017 09:53:20 +0000 (UTC) From: Hans Petter Selasky <hselasky@FreeBSD.org> To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r314904 - head/sys/compat/linuxkpi/common/include/linux Message-ID: <201703080953.v289rKo6071249@repo.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: hselasky Date: Wed Mar 8 09:53:20 2017 New Revision: 314904 URL: https://svnweb.freebsd.org/changeset/base/314904 Log: Implement eth_zero_addr() in the LinuxKPI. MFC after: 1 week Sponsored by: Mellanox Technologies Modified: head/sys/compat/linuxkpi/common/include/linux/etherdevice.h Modified: head/sys/compat/linuxkpi/common/include/linux/etherdevice.h ============================================================================== --- head/sys/compat/linuxkpi/common/include/linux/etherdevice.h Wed Mar 8 08:57:35 2017 (r314903) +++ head/sys/compat/linuxkpi/common/include/linux/etherdevice.h Wed Mar 8 09:53:20 2017 (r314904) @@ -100,6 +100,12 @@ eth_broadcast_addr(u8 *pa) } static inline void +eth_zero_addr(u8 *pa) +{ + memset(pa, 0, 6); +} + +static inline void random_ether_addr(u8 * dst) { if (read_random(dst, 6) == 0)
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201703080953.v289rKo6071249>