Merge remote-tracking branch 'asoc/for-5.14' into asoc-linus
[linux-2.6-microblaze.git] / arch / s390 / kernel / irq.c
index c0df406..234d085 100644 (file)
@@ -110,15 +110,17 @@ static int on_async_stack(void)
 {
        unsigned long frame = current_frame_address();
 
-       return !!!((S390_lowcore.async_stack - frame) >> (PAGE_SHIFT + THREAD_SIZE_ORDER));
+       return ((S390_lowcore.async_stack ^ frame) & ~(THREAD_SIZE - 1)) == 0;
 }
 
 static void do_irq_async(struct pt_regs *regs, int irq)
 {
-       if (on_async_stack())
+       if (on_async_stack()) {
                do_IRQ(regs, irq);
-       else
-               CALL_ON_STACK(do_IRQ, S390_lowcore.async_stack, 2, regs, irq);
+       } else {
+               call_on_stack(2, S390_lowcore.async_stack, void, do_IRQ,
+                             struct pt_regs *, regs, int, irq);
+       }
 }
 
 static int irq_pending(struct pt_regs *regs)
@@ -265,24 +267,6 @@ unsigned int arch_dynirq_lower_bound(unsigned int from)
        return from < NR_IRQS_BASE ? NR_IRQS_BASE : from;
 }
 
-/*
- * Switch to the asynchronous interrupt stack for softirq execution.
- */
-void do_softirq_own_stack(void)
-{
-       unsigned long old, new;
-
-       old = current_stack_pointer();
-       /* Check against async. stack address range. */
-       new = S390_lowcore.async_stack;
-       if (((new - old) >> (PAGE_SHIFT + THREAD_SIZE_ORDER)) != 0) {
-               CALL_ON_STACK(__do_softirq, new, 0);
-       } else {
-               /* We are already on the async stack. */
-               __do_softirq();
-       }
-}
-
 /*
  * ext_int_hash[index] is the list head for all external interrupts that hash
  * to this index.