]>
git.proxmox.com Git - mirror_edk2.git/blob - StdLib/LibC/Main/bswap16.c
1 /* $NetBSD: bswap16.c,v 1.1 2005/12/20 19:28:51 christos Exp $ */
4 * Written by Manuel Bouyer <bouyer@NetBSD.org>.
8 //#include <sys/cdefs.h>
9 //#if defined(LIBC_SCCS) && !defined(lint)
10 //__RCSID("$NetBSD: bswap16.c,v 1.1 2005/12/20 19:28:51 christos Exp $");
11 //#endif /* LIBC_SCCS and not lint */
13 //#include <sys/types.h>
14 //#include <machine/bswap.h>
21 return ((x
<< 8) & 0xff00) | ((x
>> 8) & 0x00ff);