Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 22 Aug 2012 07:26:34 -0600
From:      Warner Losh <imp@bsdimp.com>
To:        John Baldwin <jhb@freebsd.org>
Cc:        freebsd-hackers@freebsd.org, Adrian Chadd <adrian@freebsd.org>, freebsd-net@freebsd.org, Mitya <mitya@cabletv.dp.ua>, Wojciech Puchar <wojtek@wojtek.tensor.gdynia.pl>
Subject:   Re: Replace bcopy() to update ether_addr
Message-ID:  <2DB48390-4FB8-49ED-A176-CF593ED57502@bsdimp.com>
In-Reply-To: <201208220802.14588.jhb@freebsd.org>
References:  <50324DB4.6080905@cabletv.dp.ua> <420BA06C-C776-47DB-B3BB-F1414C115F99@bsdimp.com> <CAJ-VmokQLD6YgyrsOyez=3cLm4Q8jZOnJ9vo4Wq3sjRu%2BG-E7A@mail.gmail.com> <201208220802.14588.jhb@freebsd.org>

next in thread | previous in thread | raw e-mail | index | archive | help

On Aug 22, 2012, at 6:02 AM, John Baldwin wrote:

> On Tuesday, August 21, 2012 12:34:42 pm Adrian Chadd wrote:
>> Hi,
>>=20
>> What about just creating an ETHER_ADDR_COPY(dst, src) and putting =
that
>> in a relevant include file, then hide the ugliness there?
>>=20
>> The same benefits will likely appear when copying wifi MAC addresses
>> to/from headers.
>>=20
>> Thanks, I'm glad someone noticed this.
>=20
> I doubt we even _need_ the ugliness.  We should just use *dst =3D *src
> unless there is a compelling reason not to.

Agreed.  We should do that, and then check the generated code to be sure =
there isn't a compelling reason there :)

Warner




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?2DB48390-4FB8-49ED-A176-CF593ED57502>