summaryrefslogtreecommitdiffstats
path: root/drivers/s390/cio
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@linux-foundation.org>2023-11-03 21:17:22 +0100
committerLinus Torvalds <torvalds@linux-foundation.org>2023-11-03 21:17:22 +0100
commite392ea4d4d00880bf94550151b1ace4f88a4b17a (patch)
tree89ecc1045aea4f49961d5abc2a625ffd6126ca2a /drivers/s390/cio
parentMerge tag 'powerpc-6.7-1' of git://git.kernel.org/pub/scm/linux/kernel/git/po... (diff)
parents390/cio: replace deprecated strncpy with strscpy (diff)
downloadlinux-e392ea4d4d00880bf94550151b1ace4f88a4b17a.tar.xz
linux-e392ea4d4d00880bf94550151b1ace4f88a4b17a.zip
Merge tag 's390-6.7-1' of git://git.kernel.org/pub/scm/linux/kernel/git/s390/linux
Pull s390 updates from Vasily Gorbik: - Get rid of private VM_FAULT flags - Add word-at-a-time implementation - Add DCACHE_WORD_ACCESS support - Cleanup control register handling - Disallow CPU hotplug of CPU 0 to simplify its handling complexity, following a similar restriction in x86 - Optimize pai crypto map allocation - Update the list of crypto express EP11 coprocessor operation modes - Fixes and improvements for secure guests AP pass-through - Several fixes to address incorrect page marking for address translation with the "cmma no-dat" feature, preventing potential incorrect guest TLB flushes - Fix early IPI handling - Several virtual vs physical address confusion fixes - Various small fixes and improvements all over the code * tag 's390-6.7-1' of git://git.kernel.org/pub/scm/linux/kernel/git/s390/linux: (74 commits) s390/cio: replace deprecated strncpy with strscpy s390/sclp: replace deprecated strncpy with strtomem s390/cio: fix virtual vs physical address confusion s390/cio: export CMG value as decimal s390: delete the unused store_prefix() function s390/cmma: fix handling of swapper_pg_dir and invalid_pg_dir s390/cmma: fix detection of DAT pages s390/sclp: handle default case in sclp memory notifier s390/pai_crypto: remove per-cpu variable assignement in event initialization s390/pai: initialize event count once at initialization s390/pai_crypto: use PERF_ATTACH_TASK define for per task detection s390/mm: add missing arch_set_page_dat() call to gmap allocations s390/mm: add missing arch_set_page_dat() call to vmem_crst_alloc() s390/cmma: fix initial kernel address space page table walk s390/diag: add missing virt_to_phys() translation to diag224() s390/mm,fault: move VM_FAULT_ERROR handling to do_exception() s390/mm,fault: remove VM_FAULT_BADMAP and VM_FAULT_BADACCESS s390/mm,fault: remove VM_FAULT_SIGNAL s390/mm,fault: remove VM_FAULT_BADCONTEXT s390/mm,fault: simplify kfence fault handling ...
Diffstat (limited to 'drivers/s390/cio')
-rw-r--r--drivers/s390/cio/chp.c2
-rw-r--r--drivers/s390/cio/chsc.c8
-rw-r--r--drivers/s390/cio/crw.c4
-rw-r--r--drivers/s390/cio/isc.c4
4 files changed, 9 insertions, 9 deletions
diff --git a/drivers/s390/cio/chp.c b/drivers/s390/cio/chp.c
index 5440f285f349..675d7ed82356 100644
--- a/drivers/s390/cio/chp.c
+++ b/drivers/s390/cio/chp.c
@@ -334,7 +334,7 @@ static ssize_t chp_cmg_show(struct device *dev, struct device_attribute *attr,
return 0;
if (chp->cmg == -1) /* channel measurements not available */
return sprintf(buf, "unknown\n");
- return sprintf(buf, "%x\n", chp->cmg);
+ return sprintf(buf, "%d\n", chp->cmg);
}
static DEVICE_ATTR(cmg, 0444, chp_cmg_show, NULL);
diff --git a/drivers/s390/cio/chsc.c b/drivers/s390/cio/chsc.c
index 0abd77f4b664..f8b04ce61556 100644
--- a/drivers/s390/cio/chsc.c
+++ b/drivers/s390/cio/chsc.c
@@ -393,8 +393,8 @@ static void format_node_data(char *params, char *id, struct node_descriptor *nd)
memset(id, 0, NODEID_LEN);
if (nd->validity != ND_VALIDITY_VALID) {
- strncpy(params, "n/a", PARAMS_LEN - 1);
- strncpy(id, "n/a", NODEID_LEN - 1);
+ strscpy(params, "n/a", PARAMS_LEN);
+ strscpy(id, "n/a", NODEID_LEN);
return;
}
@@ -881,8 +881,8 @@ int __chsc_do_secm(struct channel_subsystem *css, int enable)
secm_area->request.code = 0x0016;
secm_area->key = PAGE_DEFAULT_KEY >> 4;
- secm_area->cub_addr1 = (u64)(unsigned long)css->cub_addr1;
- secm_area->cub_addr2 = (u64)(unsigned long)css->cub_addr2;
+ secm_area->cub_addr1 = virt_to_phys(css->cub_addr1);
+ secm_area->cub_addr2 = virt_to_phys(css->cub_addr2);
secm_area->operation_code = enable ? 0 : 1;
diff --git a/drivers/s390/cio/crw.c b/drivers/s390/cio/crw.c
index 7b02a6349c4d..4916dd0a7eb1 100644
--- a/drivers/s390/cio/crw.c
+++ b/drivers/s390/cio/crw.c
@@ -12,8 +12,8 @@
#include <linux/kthread.h>
#include <linux/init.h>
#include <linux/wait.h>
+#include <asm/ctlreg.h>
#include <asm/crw.h>
-#include <asm/ctl_reg.h>
#include "ioasm.h"
static DEFINE_MUTEX(crw_handler_mutex);
@@ -156,7 +156,7 @@ static int __init crw_machine_check_init(void)
task = kthread_run(crw_collect_info, NULL, "kmcheck");
if (IS_ERR(task))
return PTR_ERR(task);
- ctl_set_bit(14, 28); /* enable channel report MCH */
+ system_ctl_set_bit(14, CR14_CHANNEL_REPORT_SUBMASK_BIT);
return 0;
}
device_initcall(crw_machine_check_init);
diff --git a/drivers/s390/cio/isc.c b/drivers/s390/cio/isc.c
index 77fde9f5ea8b..dbc2ac7711e5 100644
--- a/drivers/s390/cio/isc.c
+++ b/drivers/s390/cio/isc.c
@@ -33,7 +33,7 @@ void isc_register(unsigned int isc)
spin_lock(&isc_ref_lock);
if (isc_refs[isc] == 0)
- ctl_set_bit(6, 31 - isc);
+ system_ctl_set_bit(6, 31 - isc);
isc_refs[isc]++;
spin_unlock(&isc_ref_lock);
}
@@ -61,7 +61,7 @@ void isc_unregister(unsigned int isc)
goto out_unlock;
}
if (isc_refs[isc] == 1)
- ctl_clear_bit(6, 31 - isc);
+ system_ctl_clear_bit(6, 31 - isc);
isc_refs[isc]--;
out_unlock:
spin_unlock(&isc_ref_lock);