Commit d79ff6eb authored by Harald Freudenberger's avatar Harald Freudenberger Committed by Khalid Elmously

UBUNTU: SAUCE: s390/zcrypt: CEX7 toleration support

BugLink: https://bugs.launchpad.net/bugs/1848173

With the new z15 machine also came a new crypto card CEX7
which is backward compatible to CEX6 and CEX5. The newer
kernel code covers this with a QACT instruction which
automatically enables 'unknown' new crypto cards when
QACT tells that these are backward compatible.

However, the older kernels need at least some lines
of code mapping the CEX7 crypto hardware type back
to a known and compatible type ('toleration'). And
this is done with the patch here.
Signed-off-by: default avatarHarald Freudenberger <freude@linux.ibm.com>
Signed-off-by: default avatarFrank Heimes <frank.heimes@canonical.com>
Acked-by: default avatarKhalid Elmously <khalid.elmously@canonical.com>
Acked-by: default avatarKleber Souza <kleber.souza@canonical.com>
Signed-off-by: default avatarKhalid Elmously <khalid.elmously@canonical.com>
parent 05cec3d4
...@@ -1651,8 +1651,9 @@ static void ap_scan_bus(struct work_struct *unused) ...@@ -1651,8 +1651,9 @@ static void ap_scan_bus(struct work_struct *unused)
ap_dev->queue_depth = queue_depth; ap_dev->queue_depth = queue_depth;
ap_dev->raw_hwtype = device_type; ap_dev->raw_hwtype = device_type;
ap_dev->device_type = device_type; ap_dev->device_type = device_type;
/* CEX6 toleration: map to CEX5 */ /* CEX6/CEX7 toleration: map to CEX5 */
if (device_type == AP_DEVICE_TYPE_CEX6) if (device_type == AP_DEVICE_TYPE_CEX6 ||
device_type == AP_DEVICE_TYPE_CEX7)
ap_dev->device_type = AP_DEVICE_TYPE_CEX5; ap_dev->device_type = AP_DEVICE_TYPE_CEX5;
ap_dev->functions = device_functions; ap_dev->functions = device_functions;
spin_lock_init(&ap_dev->lock); spin_lock_init(&ap_dev->lock);
......
...@@ -106,6 +106,7 @@ static inline int ap_test_bit(unsigned int *ptr, unsigned int nr) ...@@ -106,6 +106,7 @@ static inline int ap_test_bit(unsigned int *ptr, unsigned int nr)
#define AP_DEVICE_TYPE_CEX4 10 #define AP_DEVICE_TYPE_CEX4 10
#define AP_DEVICE_TYPE_CEX5 11 #define AP_DEVICE_TYPE_CEX5 11
#define AP_DEVICE_TYPE_CEX6 12 #define AP_DEVICE_TYPE_CEX6 12
#define AP_DEVICE_TYPE_CEX7 13
/* /*
* Known function facilities * Known function facilities
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment