| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
| |
while in the manpage add volatile where the code has it too.
ok miod@ guenther@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* you can #include <sys/endian.h> instead of <machine/endian.h>,
and ditto <endian.h> (fixes code that pulls in <sys/endian.h> first)
* those will always export the symbols that POSIX specified for
<endian.h>, including the new {be,le}{16,32,64}toh() set. c.f.
http://austingroupbugs.net/view.php?id=162
if __BSD_VISIBLE then you also get the symbols that our <machine/endian.h>
currently exports (ntohs, NTOHS, dlg's bemtoh*, etc)
* when doing POSIX compiles (not __BSD_VISIBLE), then <netinet/in.h> and
<arpa/inet.h> will *stop* exporting the extra symbols like BYTE_ORDER
and betoh*
ok deraadt@
|
|
|
|
| |
extra restrictions on ordering.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
archs have instrutions that can do this, and the rest that dont get
to use wrappers around the byteswap(3) api.
this provides MI backends for sparc64 and powerpc which get a big
benefit from this because byteswapping in registers is really hard
for them.
the intended use case is for reading and writing bits of dma memory
handed to and from hardware.
discussed with miod@ guenther@ deraadt@
ok miod@ kettenis@
|
|
|
|
|
|
| |
__STRICT_ALIGNMENT is talking about accessing of integer types; it does
not cover doubles or floats or other things
ok miod kettenis
|
|
|
|
| |
Discussed and okay drahn@. Okay deraadt@.
|
|
|
|
| |
Okay guenther@, millert@.
|
| |
|
|
|
|
|
| |
in sys/cdefs.h) instead of _FOO_SOURCE. Also fix several namespace
pollution issues, including the byte order defines. OK deraadt@
|
| |
|
| |
|
|
|
|
|
|
|
|
|
| |
(don't forget that cpp is `lazy':
#define A B
#define B value
#if A == value
works, since A isn't extended before it's needed, by which time B is known)
|
|
|
|
|
|
| |
part. Some ports can optimize the swap operations. This also means the
general API is extended with swap16, swap32, htobe16, htobe32, betoh16,
betoh32, htole16, htole32, letoh16 and letoh32.
|
| |
|
|
|
|
|
| |
usage in new ip_* code, since fixed. Added usage notes to prevent future
confusion in this regard.
|
| |
|
| |
|
|
|
|
| |
htonl and friends.
|
| |
|
|
|
|
| |
Some merging with NetBSD port.
|
|
NOTE: This will not work until the other pieces are checked in.
This is primarily the NetBSD powerpc port, with modifications
to support ELF.
|