Commit 54450af6 authored by Linus Torvalds's avatar Linus Torvalds
Browse files

Merge tag 'parisc-for-6.12-rc1' of...

Merge tag 'parisc-for-6.12-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/deller/parisc-linux

Pull parisc architecture updates from Helge Deller:

 - On parisc we now use the generic clockevent framework for timekeeping

 - Although there is no 64-bit glibc/userspace for parisc yet, for
   testing purposes one can run statically linked 64-bit binaries. This
   patchset contains two patches which fix 64-bit userspace which has
   been broken since kernel 4.19

 - Fix the userspace stack position and size when the ADDR_NO_RANDOMIZE
   personality is enabled

 - On other architectures mmap(MAP_GROWSDOWN | MAP_STACK) creates a
   downward-growing stack. On parisc mmap(MAP_STACK) is now sufficient
   to create an upward-growing stack

* tag 'parisc-for-6.12-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/deller/parisc-linux:
  parisc: Allow mmap(MAP_STACK) memory to automatically expand upwards
  parisc: Use PRIV_USER instead of hardcoded value
  parisc: Fix itlb miss handler for 64-bit programs
  parisc: Fix 64-bit userspace syscall path
  parisc: Fix stack start for ADDR_NO_RANDOMIZE personality
  parisc: Convert to generic clockevents
  parisc: pdc_stable: Constify struct kobj_type
parents 932d2d1f 5d698966
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -72,7 +72,7 @@ config PARISC
	select GENERIC_SCHED_CLOCK
	select GENERIC_IRQ_MIGRATION if SMP
	select HAVE_UNSTABLE_SCHED_CLOCK if SMP
	select LEGACY_TIMER_TICK
	select GENERIC_CLOCKEVENTS
	select CPU_NO_EFFICIENT_FFS
	select THREAD_INFO_IN_TASK
	select NEED_DMA_MAP_STATE
+14 −0
Original line number Diff line number Diff line
@@ -11,4 +11,18 @@ static inline bool arch_memory_deny_write_exec_supported(void)
}
#define arch_memory_deny_write_exec_supported arch_memory_deny_write_exec_supported

static inline unsigned long arch_calc_vm_flag_bits(unsigned long flags)
{
	/*
	 * The stack on parisc grows upwards, so if userspace requests memory
	 * for a stack, mark it with VM_GROWSUP so that the stack expansion in
	 * the fault handler will work.
	 */
	if (flags & MAP_STACK)
		return VM_GROWSUP;

	return 0;
}
#define arch_calc_vm_flag_bits(flags) arch_calc_vm_flag_bits(flags)

#endif /* __ASM_MMAN_H__ */
+1 −1
Original line number Diff line number Diff line
@@ -298,7 +298,7 @@ extern unsigned int toc_handler_csum;
extern void do_cpu_irq_mask(struct pt_regs *);
extern irqreturn_t timer_interrupt(int, void *);
extern irqreturn_t ipi_interrupt(int, void *);
extern void start_cpu_itimer(void);
extern void parisc_clockevent_init(void);
extern void handle_interruption(int, struct pt_regs *);

/* called from assembly code: */
+2 −4
Original line number Diff line number Diff line
@@ -1051,8 +1051,7 @@ ENTRY_CFI(intr_save) /* for os_hpmc */
	STREG           %r16, PT_ISR(%r29)
	STREG           %r17, PT_IOR(%r29)

#if 0 && defined(CONFIG_64BIT)
	/* Revisit when we have 64-bit code above 4Gb */
#if defined(CONFIG_64BIT)
	b,n		intr_save2

skip_save_ior:
@@ -1060,8 +1059,7 @@ skip_save_ior:
	 * need to adjust iasq/iaoq here in the same way we adjusted isr/ior
	 * above.
	 */
	extrd,u,*	%r8,PSW_W_BIT,1,%r1
	cmpib,COND(=),n	1,%r1,intr_save2
	bb,COND(>=),n	%r8,PSW_W_BIT,intr_save2
	LDREG		PT_IASQ0(%r29), %r16
	LDREG		PT_IAOQ0(%r29), %r17
	/* adjust iasq/iaoq */
+1 −1
Original line number Diff line number Diff line
@@ -297,7 +297,7 @@ smp_cpu_init(int cpunum)
	enter_lazy_tlb(&init_mm, current);

	init_IRQ();   /* make sure no IRQs are enabled or pending */
	start_cpu_itimer();
	parisc_clockevent_init();
}


Loading