Commit 990f2273 authored by Linus Torvalds's avatar Linus Torvalds
Browse files
Pull more s390 updates from Heiko Carstens:

 - Allow s390 debug feature to handle finally more than 256 CPU numbers,
   instead of truncating the most significant bits.

 - Improve THP splitting required by qemu processes by making use of
   walk_page_vma() instead of calling follow_page() for every single
   page within each vma.

 - Add missing ZCRYPT dependency to VFIO_AP to fix potential compile
   problems.

 - Remove not required select CLOCKSOURCE_VALIDATE_LAST_CYCLE again.

 - Set node distance to LOCAL_DISTANCE instead of 0, since e.g. libnuma
   translates a node distance of 0 to "no NUMA support available".

 - Couple of other minor fixes and improvements.

* tag 's390-5.9-2' of git://git.kernel.org/pub/scm/linux/kernel/git/s390/linux:
  s390/numa: move code to arch/s390/kernel
  s390/time: remove select CLOCKSOURCE_VALIDATE_LAST_CYCLE again
  s390/debug: debug feature version 3
  s390/Kconfig: add missing ZCRYPT dependency to VFIO_AP
  s390/numa: set node distance to LOCAL_DISTANCE
  s390/pkey: remove redundant variable initialization
  s390/test_unwind: fix possible memleak in test_unwind()
  s390/gmap: improve THP splitting
  s390/atomic: circumvent gcc 10 build regression
parents 23c2c8c6 b450eeb0
Loading
Loading
Loading
Loading
+0 −1
Original line number Diff line number Diff line
@@ -7,5 +7,4 @@ obj-$(CONFIG_S390_HYPFS_FS) += hypfs/
obj-$(CONFIG_APPLDATA_BASE)	+= appldata/
obj-y				+= net/
obj-$(CONFIG_PCI)		+= pci/
obj-$(CONFIG_NUMA)		+= numa/
obj-$(CONFIG_ARCH_HAS_KEXEC_PURGATORY) += purgatory/
+1 −1
Original line number Diff line number Diff line
@@ -126,7 +126,6 @@ config S390
	select HAVE_ARCH_JUMP_LABEL_RELATIVE
	select HAVE_ARCH_KASAN
	select HAVE_ARCH_KASAN_VMALLOC
	select CLOCKSOURCE_VALIDATE_LAST_CYCLE
	select CPU_NO_EFFICIENT_FFS if !HAVE_MARCH_Z9_109_FEATURES
	select HAVE_ARCH_SECCOMP_FILTER
	select HAVE_ARCH_SOFT_DIRTY
@@ -766,6 +765,7 @@ config VFIO_AP
	def_tristate n
	prompt "VFIO support for AP devices"
	depends on S390_AP_IOMMU && VFIO_MDEV_DEVICE && KVM
	depends on ZCRYPT
	help
		This driver grants access to Adjunct Processor (AP) devices
		via the VFIO mediated device interface.
+10 −2
Original line number Diff line number Diff line
@@ -45,7 +45,11 @@ static inline int atomic_fetch_add(int i, atomic_t *v)
static inline void atomic_add(int i, atomic_t *v)
{
#ifdef CONFIG_HAVE_MARCH_Z196_FEATURES
	if (__builtin_constant_p(i) && (i > -129) && (i < 128)) {
	/*
	 * Order of conditions is important to circumvent gcc 10 bug:
	 * https://gcc.gnu.org/pipermail/gcc-patches/2020-July/549318.html
	 */
	if ((i > -129) && (i < 128) && __builtin_constant_p(i)) {
		__atomic_add_const(i, &v->counter);
		return;
	}
@@ -112,7 +116,11 @@ static inline s64 atomic64_fetch_add(s64 i, atomic64_t *v)
static inline void atomic64_add(s64 i, atomic64_t *v)
{
#ifdef CONFIG_HAVE_MARCH_Z196_FEATURES
	if (__builtin_constant_p(i) && (i > -129) && (i < 128)) {
	/*
	 * Order of conditions is important to circumvent gcc 10 bug:
	 * https://gcc.gnu.org/pipermail/gcc-patches/2020-July/549318.html
	 */
	if ((i > -129) && (i < 128) && __builtin_constant_p(i)) {
		__atomic64_add_const(i, (long *)&v->counter);
		return;
	}
+6 −11
Original line number Diff line number Diff line
@@ -2,7 +2,7 @@
/*
 *   S/390 debug facility
 *
 *    Copyright IBM Corp. 1999, 2000
 *    Copyright IBM Corp. 1999, 2020
 */
#ifndef DEBUG_H
#define DEBUG_H
@@ -26,19 +26,14 @@
#define DEBUG_DATA(entry) (char *)(entry + 1) /* data is stored behind */
					      /* the entry information */

#define __DEBUG_FEATURE_VERSION	   2  /* version of debug feature */
#define __DEBUG_FEATURE_VERSION	   3  /* version of debug feature */

struct __debug_entry {
	union {
		struct {
			unsigned long clock	: 52;
	unsigned long clock	: 60;
	unsigned long exception	:  1;
	unsigned long level	:  3;
			unsigned long cpuid	:  8;
		} fields;
		unsigned long stck;
	} id;
	void *caller;
	unsigned short cpu;
} __packed;

typedef struct __debug_entry debug_entry_t;
+0 −6
Original line number Diff line number Diff line
@@ -86,12 +86,6 @@ static inline const struct cpumask *cpumask_of_node(int node)

#define pcibus_to_node(bus) __pcibus_to_node(bus)

#define node_distance(a, b) __node_distance(a, b)
static inline int __node_distance(int a, int b)
{
	return 0;
}

#else /* !CONFIG_NUMA */

#define numa_node_id numa_node_id
Loading