aboutsummaryrefslogtreecommitdiffstats
path: root/src/util.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/util.h')
-rw-r--r--src/util.h10
1 files changed, 10 insertions, 0 deletions
diff --git a/src/util.h b/src/util.h
index 92b3e5c9..6c08a3c6 100644
--- a/src/util.h
+++ b/src/util.h
@@ -110,6 +110,16 @@ static inline u32 __htonl(u32 val) {
#define htons(x) __htons_constant(x)
#define ntohs(x) htons(x)
+static inline u16 cpu_to_le16(u16 x)
+{
+ return x;
+}
+
+static inline u32 cpu_to_le32(u32 x)
+{
+ return x;
+}
+
static inline u32 getesp(void) {
u32 esp;
asm("movl %%esp, %0" : "=rm"(esp));