Firewire: Type fix for byte swapping

Cast return value of __swap_int32 to uint32_t, as suggested by Ingo.

Remedies uint32 %08x warnings treated as errors in the Big Endian code path.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@38106 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
Andreas Färber 2010-08-15 09:37:20 +00:00
parent a4c54e94e8
commit 756ea297c2

View File

@ -94,8 +94,8 @@ typedef uint32_t fwohcireg_t;
/* for PCI */
#if BYTE_ORDER == BIG_ENDIAN
#ifdef __HAIKU__
#define htole32(x) __swap_int32(x)
#define le32toh(x) __swap_int32(x)
#define htole32(x) ((uint32_t)__swap_int32(x))
#define le32toh(x) ((uint32_t)__swap_int32(x))
#endif
#define FWOHCI_DMA_WRITE(x, y) ((x) = htole32(y))
#define FWOHCI_DMA_READ(x) le32toh(x)