/*
 * This file is subject to the terms and conditions of the GNU General Public
 * License.  See the file "COPYING" in the main directory of this archive
 * for more details.
 *
 * Copyright (C) by Equator Technologies
 */
#ifndef _ASM_BSP_BYTEORDER_H
#define _ASM_BSP_BYTEORDER_H

#include <asm/types.h>
#include <eti/mm.h>

/* NOTE: swab16 actually does a 16-bit partitioned swap if it's 
 *       passed a 32-bit value with non-zero values in the upper 2 bytes */
#define __arch__swab16(x) hmpv_bcopyrev_32(x, 0x3, 0x1)
#define __arch__swab32(x) hmpv_bcopyrev_32(x, 0x3, 0x3)
#define __arch__swab64(x) hmpv_bcopyrev_64(x, 0x7, 0x7)

#include <linux/byteorder/little_endian.h>

#endif	/* _ASM_BSP_BYTEORDER_H */
