]> git.ipfire.org Git - thirdparty/kernel/stable-queue.git/commitdiff
fix up cris issue with 4.9 and 4.4 queues
authorGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Mon, 8 Jul 2019 13:57:12 +0000 (15:57 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Mon, 8 Jul 2019 13:57:12 +0000 (15:57 +0200)
queue-4.4/bug.h-work-around-gcc-pr82365-in-bug.patch
queue-4.4/swiotlb-make-linux-swiotlb.h-standalone-includible.patch
queue-4.9/bug.h-work-around-gcc-pr82365-in-bug.patch

index 8426d41f8bfdfb3035e5659e2c177b436e59d39d..2e310d84aea760f2ee631f29ddfa4765402e76c4 100644 (file)
@@ -91,22 +91,21 @@ Cc: Mark Rutland <mark.rutland@arm.com>
 Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
 Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
 Signed-off-by: Sasha Levin <sashal@kernel.org>
+[ removed cris changes - gregkh]
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
 ---
- arch/arc/include/asm/bug.h            |  3 ++-
- arch/cris/include/arch-v10/arch/bug.h | 11 +++++++++--
- arch/ia64/include/asm/bug.h           |  6 +++++-
- arch/m68k/include/asm/bug.h           |  3 +++
- arch/sparc/include/asm/bug.h          |  6 +++++-
- include/asm-generic/bug.h             |  1 +
- include/linux/compiler-gcc.h          | 15 ++++++++++++++-
- include/linux/compiler.h              |  5 +++++
- 8 files changed, 44 insertions(+), 6 deletions(-)
+ arch/arc/include/asm/bug.h   |    3 ++-
+ arch/ia64/include/asm/bug.h  |    6 +++++-
+ arch/m68k/include/asm/bug.h  |    3 +++
+ arch/sparc/include/asm/bug.h |    6 +++++-
+ include/asm-generic/bug.h    |    1 +
+ include/linux/compiler-gcc.h |   15 ++++++++++++++-
+ include/linux/compiler.h     |    5 +++++
+ 7 files changed, 35 insertions(+), 4 deletions(-)
 
-diff --git a/arch/arc/include/asm/bug.h b/arch/arc/include/asm/bug.h
-index ea022d47896c..21ec82466d62 100644
 --- a/arch/arc/include/asm/bug.h
 +++ b/arch/arc/include/asm/bug.h
-@@ -23,7 +23,8 @@ void die(const char *str, struct pt_regs *regs, unsigned long address);
+@@ -23,7 +23,8 @@ void die(const char *str, struct pt_regs
  
  #define BUG() do {                                                            \
        pr_warn("BUG: failure at %s:%d/%s()!\n", __FILE__, __LINE__, __func__); \
@@ -116,40 +115,6 @@ index ea022d47896c..21ec82466d62 100644
  } while (0)
  
  #define HAVE_ARCH_BUG
-diff --git a/arch/cris/include/arch-v10/arch/bug.h b/arch/cris/include/arch-v10/arch/bug.h
-index 3485d6b34bb0..06701ac0596f 100644
---- a/arch/cris/include/arch-v10/arch/bug.h
-+++ b/arch/cris/include/arch-v10/arch/bug.h
-@@ -43,18 +43,25 @@ struct bug_frame {
-  * not be used like this with newer versions of gcc.
-  */
- #define BUG()                                                         \
-+do {                                                                  \
-       __asm__ __volatile__ ("clear.d [" __stringify(BUG_MAGIC) "]\n\t"\
-                             "movu.w " __stringify(__LINE__) ",$r0\n\t"\
-                             "jump 0f\n\t"                             \
-                             ".section .rodata\n"                      \
-                             "0:\t.string \"" __FILE__ "\"\n\t"        \
--                            ".previous")
-+                            ".previous");                             \
-+      unreachable();                                                  \
-+} while (0)
- #endif
- #else
- /* This just causes an oops. */
--#define BUG() (*(int *)0 = 0)
-+#define BUG()                                                         \
-+do {                                                                  \
-+      barrier_before_unreachable();                                   \
-+      __builtin_trap();                                               \
-+} while (0)
- #endif
-diff --git a/arch/ia64/include/asm/bug.h b/arch/ia64/include/asm/bug.h
-index 823616b5020b..19067821249f 100644
 --- a/arch/ia64/include/asm/bug.h
 +++ b/arch/ia64/include/asm/bug.h
 @@ -3,7 +3,11 @@
@@ -165,8 +130,6 @@ index 823616b5020b..19067821249f 100644
  
  /* should this BUG be made generic? */
  #define HAVE_ARCH_BUG
-diff --git a/arch/m68k/include/asm/bug.h b/arch/m68k/include/asm/bug.h
-index ef9a2e47352f..21ddbf925e22 100644
 --- a/arch/m68k/include/asm/bug.h
 +++ b/arch/m68k/include/asm/bug.h
 @@ -7,16 +7,19 @@
@@ -189,8 +152,6 @@ index ef9a2e47352f..21ddbf925e22 100644
        __builtin_trap(); \
  } while (0)
  #endif
-diff --git a/arch/sparc/include/asm/bug.h b/arch/sparc/include/asm/bug.h
-index eaa8f8d38125..fa85cac0285c 100644
 --- a/arch/sparc/include/asm/bug.h
 +++ b/arch/sparc/include/asm/bug.h
 @@ -8,10 +8,14 @@
@@ -209,8 +170,6 @@ index eaa8f8d38125..fa85cac0285c 100644
  #endif
  
  #define HAVE_ARCH_BUG
-diff --git a/include/asm-generic/bug.h b/include/asm-generic/bug.h
-index 630dd2372238..09aa521a0085 100644
 --- a/include/asm-generic/bug.h
 +++ b/include/asm-generic/bug.h
 @@ -47,6 +47,7 @@ struct bug_entry {
@@ -221,15 +180,12 @@ index 630dd2372238..09aa521a0085 100644
        panic("BUG!"); \
  } while (0)
  #endif
-diff --git a/include/linux/compiler-gcc.h b/include/linux/compiler-gcc.h
-index 143d40e8a1ea..af8b4a879934 100644
 --- a/include/linux/compiler-gcc.h
 +++ b/include/linux/compiler-gcc.h
-@@ -206,6 +206,15 @@
- #endif /* GCC_VERSION >= 40300 */
+@@ -207,6 +207,15 @@
  
  #if GCC_VERSION >= 40500
-+/*
+ /*
 + * calling noreturn functions, __builtin_unreachable() and __builtin_trap()
 + * confuse the stack allocation in gcc, leading to overly large stack
 + * frames, see https://gcc.gnu.org/bugzilla/show_bug.cgi?id=82365
@@ -238,9 +194,10 @@ index 143d40e8a1ea..af8b4a879934 100644
 + */
 +#define barrier_before_unreachable() asm volatile("")
 +
- /*
++/*
   * Mark a position in code as unreachable.  This can be used to
   * suppress control flow warnings after asm blocks that transfer
+  * control elsewhere.
 @@ -215,7 +224,11 @@
   * this in the preprocessor, but we can live with this because they're
   * unreleased.  Really, we need to have autoconf for the kernel.
@@ -254,11 +211,9 @@ index 143d40e8a1ea..af8b4a879934 100644
  
  /* Mark a function definition as prohibited from being cloned. */
  #define __noclone     __attribute__((__noclone__, __optimize__("no-tracer")))
-diff --git a/include/linux/compiler.h b/include/linux/compiler.h
-index 0db1fa621d8a..ed772311ec1f 100644
 --- a/include/linux/compiler.h
 +++ b/include/linux/compiler.h
-@@ -175,6 +175,11 @@ void ftrace_likely_update(struct ftrace_branch_data *f, int val, int expect);
+@@ -175,6 +175,11 @@ void ftrace_likely_update(struct ftrace_
  # define barrier_data(ptr) barrier()
  #endif
  
@@ -270,6 +225,3 @@ index 0db1fa621d8a..ed772311ec1f 100644
  /* Unreachable code */
  #ifndef unreachable
  # define unreachable() do { } while (1)
--- 
-2.20.1
-
index b71175c1e2507a5aa53da089a2fc08bc25bd28a6..92943fe6795f608bfc4df69c546328d167405420 100644 (file)
@@ -17,11 +17,9 @@ Signed-off-by: Thierry Reding <treding@nvidia.com>
 Signed-off-by: Konrad Rzeszutek Wilk <konrad.wilk@oracle.com>
 Signed-off-by: Sasha Levin <sashal@kernel.org>
 ---
- include/linux/swiotlb.h | 3 +++
+ include/linux/swiotlb.h |    3 +++
  1 file changed, 3 insertions(+)
 
-diff --git a/include/linux/swiotlb.h b/include/linux/swiotlb.h
-index e7a018eaf3a2..017fced60242 100644
 --- a/include/linux/swiotlb.h
 +++ b/include/linux/swiotlb.h
 @@ -1,10 +1,13 @@
@@ -38,6 +36,3 @@ index e7a018eaf3a2..017fced60242 100644
  struct scatterlist;
  
  extern int swiotlb_force;
--- 
-2.20.1
-
index 44b63a02a856aa835fe2534432b00b0b8b8125d0..e5cc9892ef071d5813c5065e685a8e011931d3ca 100644 (file)
@@ -91,22 +91,21 @@ Cc: Mark Rutland <mark.rutland@arm.com>
 Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
 Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
 Signed-off-by: Sasha Levin <sashal@kernel.org>
+[removed cris chunks - gregkh]
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
 ---
- arch/arc/include/asm/bug.h            |  3 ++-
- arch/cris/include/arch-v10/arch/bug.h | 11 +++++++++--
- arch/ia64/include/asm/bug.h           |  6 +++++-
- arch/m68k/include/asm/bug.h           |  3 +++
- arch/sparc/include/asm/bug.h          |  6 +++++-
- include/asm-generic/bug.h             |  1 +
- include/linux/compiler-gcc.h          | 15 ++++++++++++++-
- include/linux/compiler.h              |  5 +++++
- 8 files changed, 44 insertions(+), 6 deletions(-)
+ arch/arc/include/asm/bug.h   |    3 ++-
+ arch/ia64/include/asm/bug.h  |    6 +++++-
+ arch/m68k/include/asm/bug.h  |    3 +++
+ arch/sparc/include/asm/bug.h |    6 +++++-
+ include/asm-generic/bug.h    |    1 +
+ include/linux/compiler-gcc.h |   15 ++++++++++++++-
+ include/linux/compiler.h     |    5 +++++
+ 7 files changed, 35 insertions(+), 4 deletions(-)
 
-diff --git a/arch/arc/include/asm/bug.h b/arch/arc/include/asm/bug.h
-index ea022d47896c..21ec82466d62 100644
 --- a/arch/arc/include/asm/bug.h
 +++ b/arch/arc/include/asm/bug.h
-@@ -23,7 +23,8 @@ void die(const char *str, struct pt_regs *regs, unsigned long address);
+@@ -23,7 +23,8 @@ void die(const char *str, struct pt_regs
  
  #define BUG() do {                                                            \
        pr_warn("BUG: failure at %s:%d/%s()!\n", __FILE__, __LINE__, __func__); \
@@ -116,40 +115,6 @@ index ea022d47896c..21ec82466d62 100644
  } while (0)
  
  #define HAVE_ARCH_BUG
-diff --git a/arch/cris/include/arch-v10/arch/bug.h b/arch/cris/include/arch-v10/arch/bug.h
-index 3485d6b34bb0..06701ac0596f 100644
---- a/arch/cris/include/arch-v10/arch/bug.h
-+++ b/arch/cris/include/arch-v10/arch/bug.h
-@@ -43,18 +43,25 @@ struct bug_frame {
-  * not be used like this with newer versions of gcc.
-  */
- #define BUG()                                                         \
-+do {                                                                  \
-       __asm__ __volatile__ ("clear.d [" __stringify(BUG_MAGIC) "]\n\t"\
-                             "movu.w " __stringify(__LINE__) ",$r0\n\t"\
-                             "jump 0f\n\t"                             \
-                             ".section .rodata\n"                      \
-                             "0:\t.string \"" __FILE__ "\"\n\t"        \
--                            ".previous")
-+                            ".previous");                             \
-+      unreachable();                                                  \
-+} while (0)
- #endif
- #else
- /* This just causes an oops. */
--#define BUG() (*(int *)0 = 0)
-+#define BUG()                                                         \
-+do {                                                                  \
-+      barrier_before_unreachable();                                   \
-+      __builtin_trap();                                               \
-+} while (0)
- #endif
-diff --git a/arch/ia64/include/asm/bug.h b/arch/ia64/include/asm/bug.h
-index 823616b5020b..19067821249f 100644
 --- a/arch/ia64/include/asm/bug.h
 +++ b/arch/ia64/include/asm/bug.h
 @@ -3,7 +3,11 @@
@@ -165,8 +130,6 @@ index 823616b5020b..19067821249f 100644
  
  /* should this BUG be made generic? */
  #define HAVE_ARCH_BUG
-diff --git a/arch/m68k/include/asm/bug.h b/arch/m68k/include/asm/bug.h
-index ef9a2e47352f..21ddbf925e22 100644
 --- a/arch/m68k/include/asm/bug.h
 +++ b/arch/m68k/include/asm/bug.h
 @@ -7,16 +7,19 @@
@@ -189,8 +152,6 @@ index ef9a2e47352f..21ddbf925e22 100644
        __builtin_trap(); \
  } while (0)
  #endif
-diff --git a/arch/sparc/include/asm/bug.h b/arch/sparc/include/asm/bug.h
-index eaa8f8d38125..fa85cac0285c 100644
 --- a/arch/sparc/include/asm/bug.h
 +++ b/arch/sparc/include/asm/bug.h
 @@ -8,10 +8,14 @@
@@ -209,8 +170,6 @@ index eaa8f8d38125..fa85cac0285c 100644
  #endif
  
  #define HAVE_ARCH_BUG
-diff --git a/include/asm-generic/bug.h b/include/asm-generic/bug.h
-index 6f96247226a4..89f079d6b41b 100644
 --- a/include/asm-generic/bug.h
 +++ b/include/asm-generic/bug.h
 @@ -47,6 +47,7 @@ struct bug_entry {
@@ -221,15 +180,12 @@ index 6f96247226a4..89f079d6b41b 100644
        panic("BUG!"); \
  } while (0)
  #endif
-diff --git a/include/linux/compiler-gcc.h b/include/linux/compiler-gcc.h
-index 8e9b0cb8db41..61650c1830d4 100644
 --- a/include/linux/compiler-gcc.h
 +++ b/include/linux/compiler-gcc.h
-@@ -233,6 +233,15 @@
- #define annotate_unreachable()
+@@ -234,6 +234,15 @@
  #endif
  
-+/*
+ /*
 + * calling noreturn functions, __builtin_unreachable() and __builtin_trap()
 + * confuse the stack allocation in gcc, leading to overly large stack
 + * frames, see https://gcc.gnu.org/bugzilla/show_bug.cgi?id=82365
@@ -238,9 +194,10 @@ index 8e9b0cb8db41..61650c1830d4 100644
 + */
 +#define barrier_before_unreachable() asm volatile("")
 +
- /*
++/*
   * Mark a position in code as unreachable.  This can be used to
   * suppress control flow warnings after asm blocks that transfer
+  * control elsewhere.
 @@ -243,7 +252,11 @@
   * unreleased.  Really, we need to have autoconf for the kernel.
   */
@@ -254,11 +211,9 @@ index 8e9b0cb8db41..61650c1830d4 100644
  
  /* Mark a function definition as prohibited from being cloned. */
  #define __noclone     __attribute__((__noclone__, __optimize__("no-tracer")))
-diff --git a/include/linux/compiler.h b/include/linux/compiler.h
-index 4f3dfabb680f..80a5bc623c47 100644
 --- a/include/linux/compiler.h
 +++ b/include/linux/compiler.h
-@@ -177,6 +177,11 @@ void ftrace_likely_update(struct ftrace_branch_data *f, int val, int expect);
+@@ -177,6 +177,11 @@ void ftrace_likely_update(struct ftrace_
  # define barrier_data(ptr) barrier()
  #endif
  
@@ -270,6 +225,3 @@ index 4f3dfabb680f..80a5bc623c47 100644
  /* Unreachable code */
  #ifndef unreachable
  # define unreachable() do { } while (1)
--- 
-2.20.1
-