Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

Merge tag 'nios2_update_for_v6.18' of git://git.kernel.org/pub/scm/linux/kernel/git/dinguyen/linux

Pull NIOS2 updates from Dinh Nguyen:

- Replace __ASSEMBLY__ with __ASSEMBLER__ in headers

- Set memblock.current_limit when setting pfn limits

* tag 'nios2_update_for_v6.18' of git://git.kernel.org/pub/scm/linux/kernel/git/dinguyen/linux:
nios2: ensure that memblock.current_limit is set when setting pfn limits
nios2: Replace __ASSEMBLY__ with __ASSEMBLER__ in non-uapi headers
nios2: Replace __ASSEMBLY__ with __ASSEMBLER__ in uapi headers

+32 -17
+2 -2
arch/nios2/include/asm/entry.h
··· 10 10 #ifndef _ASM_NIOS2_ENTRY_H 11 11 #define _ASM_NIOS2_ENTRY_H 12 12 13 - #ifdef __ASSEMBLY__ 13 + #ifdef __ASSEMBLER__ 14 14 15 15 #include <asm/processor.h> 16 16 #include <asm/registers.h> ··· 117 117 addi sp, sp, SWITCH_STACK_SIZE 118 118 .endm 119 119 120 - #endif /* __ASSEMBLY__ */ 120 + #endif /* __ASSEMBLER__ */ 121 121 #endif /* _ASM_NIOS2_ENTRY_H */
+2 -2
arch/nios2/include/asm/page.h
··· 26 26 #define PAGE_OFFSET \ 27 27 (CONFIG_NIOS2_MEM_BASE + CONFIG_NIOS2_KERNEL_REGION_BASE) 28 28 29 - #ifndef __ASSEMBLY__ 29 + #ifndef __ASSEMBLER__ 30 30 31 31 /* 32 32 * This gives the physical RAM offset. ··· 90 90 91 91 #include <asm-generic/getorder.h> 92 92 93 - #endif /* !__ASSEMBLY__ */ 93 + #endif /* !__ASSEMBLER__ */ 94 94 95 95 #endif /* _ASM_NIOS2_PAGE_H */
+2 -2
arch/nios2/include/asm/processor.h
··· 36 36 /* Kuser helpers is mapped to this user space address */ 37 37 #define KUSER_BASE 0x1000 38 38 #define KUSER_SIZE (PAGE_SIZE) 39 - #ifndef __ASSEMBLY__ 39 + #ifndef __ASSEMBLER__ 40 40 41 41 # define TASK_SIZE 0x7FFF0000UL 42 42 # define TASK_UNMAPPED_BASE (PAGE_ALIGN(TASK_SIZE / 3)) ··· 72 72 73 73 #define cpu_relax() barrier() 74 74 75 - #endif /* __ASSEMBLY__ */ 75 + #endif /* __ASSEMBLER__ */ 76 76 77 77 #endif /* _ASM_NIOS2_PROCESSOR_H */
+2 -2
arch/nios2/include/asm/ptrace.h
··· 18 18 /* This struct defines the way the registers are stored on the 19 19 stack during a system call. */ 20 20 21 - #ifndef __ASSEMBLY__ 21 + #ifndef __ASSEMBLER__ 22 22 struct pt_regs { 23 23 unsigned long r8; /* r8-r15 Caller-saved GP registers */ 24 24 unsigned long r9; ··· 78 78 79 79 int do_syscall_trace_enter(void); 80 80 void do_syscall_trace_exit(void); 81 - #endif /* __ASSEMBLY__ */ 81 + #endif /* __ASSEMBLER__ */ 82 82 #endif /* _ASM_NIOS2_PTRACE_H */
+2 -2
arch/nios2/include/asm/registers.h
··· 6 6 #ifndef _ASM_NIOS2_REGISTERS_H 7 7 #define _ASM_NIOS2_REGISTERS_H 8 8 9 - #ifndef __ASSEMBLY__ 9 + #ifndef __ASSEMBLER__ 10 10 #include <asm/cpuinfo.h> 11 11 #endif 12 12 ··· 44 44 45 45 /* tlbmisc register bits */ 46 46 #define TLBMISC_PID_SHIFT 4 47 - #ifndef __ASSEMBLY__ 47 + #ifndef __ASSEMBLER__ 48 48 #define TLBMISC_PID_MASK ((1UL << cpuinfo.tlb_pid_num_bits) - 1) 49 49 #endif 50 50 #define TLBMISC_WAY_MASK 0xf
+2 -2
arch/nios2/include/asm/setup.h
··· 8 8 9 9 #include <asm-generic/setup.h> 10 10 11 - #ifndef __ASSEMBLY__ 11 + #ifndef __ASSEMBLER__ 12 12 #ifdef __KERNEL__ 13 13 14 14 extern char exception_handler_hook[]; ··· 18 18 extern void pagetable_init(void); 19 19 20 20 #endif/* __KERNEL__ */ 21 - #endif /* __ASSEMBLY__ */ 21 + #endif /* __ASSEMBLER__ */ 22 22 23 23 #endif /* _ASM_NIOS2_SETUP_H */
+2 -2
arch/nios2/include/asm/thread_info.h
··· 24 24 #define THREAD_SIZE_ORDER 1 25 25 #define THREAD_SIZE 8192 /* 2 * PAGE_SIZE */ 26 26 27 - #ifndef __ASSEMBLY__ 27 + #ifndef __ASSEMBLER__ 28 28 29 29 /* 30 30 * low level task data that entry.S needs immediate access to ··· 61 61 62 62 return (struct thread_info *)(sp & ~(THREAD_SIZE - 1)); 63 63 } 64 - #endif /* !__ASSEMBLY__ */ 64 + #endif /* !__ASSEMBLER__ */ 65 65 66 66 /* 67 67 * thread information flags
+1 -1
arch/nios2/include/asm/traps.h
··· 12 12 13 13 #define TRAP_ID_SYSCALL 0 14 14 15 - #ifndef __ASSEMBLY__ 15 + #ifndef __ASSEMBLER__ 16 16 void _exception(int signo, struct pt_regs *regs, int code, unsigned long addr); 17 17 void do_page_fault(struct pt_regs *regs, unsigned long cause, 18 18 unsigned long address);
+2 -2
arch/nios2/include/uapi/asm/ptrace.h
··· 13 13 #ifndef _UAPI_ASM_NIOS2_PTRACE_H 14 14 #define _UAPI_ASM_NIOS2_PTRACE_H 15 15 16 - #ifndef __ASSEMBLY__ 16 + #ifndef __ASSEMBLER__ 17 17 18 18 #include <linux/types.h> 19 19 ··· 80 80 __u32 regs[49]; 81 81 }; 82 82 83 - #endif /* __ASSEMBLY__ */ 83 + #endif /* __ASSEMBLER__ */ 84 84 #endif /* _UAPI_ASM_NIOS2_PTRACE_H */
+15
arch/nios2/kernel/setup.c
··· 142 142 *max_high = PFN_DOWN(memblock_end_of_DRAM()); 143 143 } 144 144 145 + static void __init adjust_lowmem_bounds(void) 146 + { 147 + phys_addr_t block_start, block_end; 148 + u64 i; 149 + phys_addr_t memblock_limit = 0; 150 + 151 + for_each_mem_range(i, &block_start, &block_end) { 152 + if (block_end > memblock_limit) 153 + memblock_limit = block_end; 154 + } 155 + 156 + memblock_set_current_limit(memblock_limit); 157 + } 158 + 145 159 void __init setup_arch(char **cmdline_p) 146 160 { 147 161 console_verbose(); ··· 171 157 /* Keep a copy of command line */ 172 158 *cmdline_p = boot_command_line; 173 159 160 + adjust_lowmem_bounds(); 174 161 find_limits(&min_low_pfn, &max_low_pfn, &max_pfn); 175 162 176 163 memblock_reserve(__pa_symbol(_stext), _end - _stext);