diff --git a/Makefile b/Makefile index 5f30dcfd..c1610a82 100644 --- a/Makefile +++ b/Makefile @@ -78,7 +78,6 @@ endif AFLAGS := $(COMMON_FLAGS) -D__ASSEMBLY__ -nostdlib -nostdinc CFLAGS := $(COMMON_FLAGS) -std=gnu99 -O3 -g -Wall -Wextra -ffreestanding -nostdlib -nostdinc -CFLAGS += -Iinclude CFLAGS += -mno-red-zone -mno-mmx -mno-sse -mno-sse2 CFLAGS += -fno-stack-protector -fno-exceptions -fno-builtin -fomit-frame-pointer -fcf-protection="none" CFLAGS += -mcmodel=kernel -fno-pic -fno-asynchronous-unwind-tables -fno-unwind-tables diff --git a/arch/x86/entry.S b/arch/x86/entry.S index 7ef392df..6b508885 100644 --- a/arch/x86/entry.S +++ b/arch/x86/entry.S @@ -46,11 +46,7 @@ ENTRY(asm_interrupt_handler_\sym) SAVE_REGS call \func RESTORE_REGS -#if defined(__x86_64__) - iretq -#else - iret -#endif + IRET END_FUNC(asm_interrupt_handler_\sym) .endm diff --git a/include/semaphore.h b/include/semaphore.h index 2a3fb539..e6bd52ea 100644 --- a/include/semaphore.h +++ b/include/semaphore.h @@ -35,9 +35,7 @@ typedef struct sem sem_t; #define MAX_SEMAPHORE_VALUE (_U32(-1) / 2) #define SEM_INIT(value) \ - { \ - .v = {(value) } \ - } + { .v = {(value)}, } extern int32_t sem_value(const sem_t *sem);