From f16f0d4f3468350bcf256dbb222c7d87bafff507 Mon Sep 17 00:00:00 2001 From: Alan Cox Date: Thu, 4 Jun 2015 19:23:07 +0100 Subject: [PATCH] 6809: define cpu_to_le32/reverse --- Kernel/cpu-6809/cpu.h | 3 +++ 1 file changed, 3 insertions(+) diff --git a/Kernel/cpu-6809/cpu.h b/Kernel/cpu-6809/cpu.h index fe68c4bd..ab2bab08 100644 --- a/Kernel/cpu-6809/cpu.h +++ b/Kernel/cpu-6809/cpu.h @@ -55,6 +55,9 @@ typedef union { /* this structure is endian dependent */ #define cpu_to_le16(x) swab(x) #define le16_to_cpu(x) swab(x) +#define cpu_to_le32(x) ((((uint32_t)cpu_to_le16((x) & 0xFFFF)) << 16) | \ + (uint32_t)cpu_to_le16((x) >> 16)) +#define le32_to_cpu(x) cpu_to_le32(x) /* Sane behaviour for unused parameters */ #define used(x) -- 2.34.1