--- zzzz-none-000/linux-3.18.24/arch/mips/include/asm/thread_info.h 2015-10-31 20:39:51.000000000 +0000 +++ rtl96-5690pro-762/linux-3.18.24/arch/mips/include/asm/thread_info.h 2024-08-14 08:36:36.000000000 +0000 @@ -36,6 +36,7 @@ */ struct restart_block restart_block; struct pt_regs *regs; + long syscall; /* syscall number */ }; /* @@ -68,6 +69,9 @@ #endif /* !__ASSEMBLY__ */ /* thread information allocation */ +#ifdef CONFIG_KERNEL_STACK_SIZE_ORDER +#define THREAD_SIZE_ORDER (CONFIG_KERNEL_STACK_SIZE_ORDER) +#else #if defined(CONFIG_PAGE_SIZE_4KB) && defined(CONFIG_32BIT) #define THREAD_SIZE_ORDER (1) #endif @@ -86,6 +90,7 @@ #ifdef CONFIG_PAGE_SIZE_64KB #define THREAD_SIZE_ORDER (0) #endif +#endif /* CONFIG_KERNEL_STACK_SIZE_ORDER */ #define THREAD_SIZE (PAGE_SIZE << THREAD_SIZE_ORDER) #define THREAD_MASK (THREAD_SIZE - 1UL) @@ -159,15 +164,19 @@ * We stash processor id into a COP0 register to retrieve it fast * at kernel exception entry. */ -#if defined(CONFIG_MIPS_PGD_C0_CONTEXT) +#if defined(CONFIG_MIPS_PGD_C0_CONTEXT) #define SMP_CPUID_REG 20, 0 /* XCONTEXT */ #define ASM_SMP_CPUID_REG $20 #define SMP_CPUID_PTRSHIFT 48 #else #define SMP_CPUID_REG 4, 0 /* CONTEXT */ #define ASM_SMP_CPUID_REG $4 +#ifdef CONFIG_CPU_RLX +#define SMP_CPUID_PTRSHIFT 21 +#else #define SMP_CPUID_PTRSHIFT 23 #endif +#endif #ifdef CONFIG_64BIT #define SMP_CPUID_REGSHIFT (SMP_CPUID_PTRSHIFT + 3)