Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 746ff60f authored by Glauber de Oliveira Costa's avatar Glauber de Oliveira Costa Committed by Ingo Molnar
Browse files

x86: move desc_empty to where they belong



This patch moves the (duplicated) desc_empty implementation to desc.h,
where the descriptor things belong.

Signed-off-by: default avatarGlauber de Oliveira Costa <gcosta@redhat.com>
Signed-off-by: default avatarIngo Molnar <mingo@elte.hu>
Signed-off-by: default avatarThomas Gleixner <tglx@linutronix.de>
parent 053de044
Loading
Loading
Loading
Loading
+6 −0
Original line number Diff line number Diff line
@@ -71,6 +71,12 @@ static inline void pack_gate(gate_desc *gate, unsigned char type,

#endif

static inline int desc_empty(const void *ptr)
{
	const u32 *desc = ptr;
	return !(desc[0] | desc[1]);
}

#ifdef CONFIG_PARAVIRT
#include <asm/paravirt.h>
#else
+0 −6
Original line number Diff line number Diff line
@@ -21,12 +21,6 @@
#include <linux/init.h>
#include <asm/desc_defs.h>

static inline int desc_empty(const void *ptr)
{
	const u32 *desc = ptr;
	return !(desc[0] | desc[1]);
}

/*
 * Default implementation of macro that returns current
 * instruction pointer ("program counter").
+0 −6
Original line number Diff line number Diff line
@@ -20,12 +20,6 @@
#include <linux/cpumask.h>
#include <asm/desc_defs.h>

static inline int desc_empty(const void *ptr)
{
	const u32 *desc = ptr;
	return !(desc[0] | desc[1]);
}

/*
 * Default implementation of macro that returns current
 * instruction pointer ("program counter").