some comments for "s390/zcrypt: AP bus support for alternate driver(s)"
A message that is not in the archive (sent off-list or not yet received): [email protected]
Quoted 2 lines · On Fri, 17 Aug 2018 10:39:47 +0200 Harald Freudenberger <[email protected]>…
I've sent a patch to Heiko/Martin for upstream integration which fixes some of the issues you mentioned:
And I am working on a patch which makes it possible to give ranges for the bitmap manipulations.
Sounds good!
Quoted 41 lines
regards
Harald FreudenbergerQuoted 1 line
Quoted 1 line
====================<<
From: Harald Freudenberger <[email protected]>
Date: Fri, 17 Aug 2018 09:01:09 +0200
Subject: [PATCH] s390/zcrypt: Fix returncode type, typo and block commentMinor cleanup patch which fixes 3 complains from upstream review:
- functionap_instructions_available()had returntype int but � in fact returned 1 for true and 0 for false. Changed returntype � to bool.
- Typo in static function name__ap_revice_reserved.
� revice -> revise for name and the code which called it.
- Extension on a block comment regarding how devices and drivers � with respect of the default flag are handled.Signed-off-by Harald Freudenberger <[email protected]>---
�arch/s390/include/asm/ap.h�� |� 6 +++---
�drivers/s390/crypto/ap_bus.c | 11 ++++++-----
�2 files changed, 9 insertions(+), 8 deletions(-)arch/s390/include/asm/ap.h +0
-0@@ -49,9 +49,9 @@ struct ap_queue_status {�/**
� *ap_intructions_available()- Test if AP instructions are available. � *
- * Returns 1 if the AP instructions are installed, otherwise 0.
+ * Returns true if the AP instructions are installed, otherwise false. � */arch/s390/include/asm/ap.h +1
-1-static inline int ap_instructions_available (void ) +static inline bool ap_instructions_available (void )�{
���� register unsigned long reg0 asm ("0") =AP_MKQID(0, 0); ���� register unsigned long reg1 asm ("1") = 0;
arch/s390/include/asm/ap.h static inline int ap_instructions_available(void) · line 68
Quoted 5 lines
arch/s390/include/asm/ap.h +1
-1@@ -65,7 +65,7 @@ static inline int ap_instructions_available(void) ���� ��� : "+d" (reg1), "+d" (reg2) ���� ��� : "d" (reg0) ���� ��� : "cc"); -��� return reg1; +��� return reg1 != 0;
That applies to the current features branch, right?
Quoted 31 lines
arch/s390/include/asm/ap.h +0
-0�}�
�/**drivers/s390/crypto/ap_bus.c +0
-0@@ -682,7 +682,7 @@ static struct bus_type ap_bus_type = { ���� .pm = &ap_bus_pm_ops, �};�
drivers/s390/crypto/ap_bus.c +1
-1-static int __ap_revice_reserved (struct device *dev,void *dummy) +static int __ap_revise_reserved (struct device *dev,void *dummy)�{
���� int rc, card, queue, devres, drvres;
�drivers/s390/crypto/ap_bus.c +0
-0@@ -707,7 +707,7 @@ static int __ap_revice_reserved(struct device *dev, void *dummy)�
�static voidap_bus_revise_bindings(void)
�{
-���bus_for_each_dev(&ap_bus_type, NULL, NULL, __ap_revice_reserved); +���bus_for_each_dev(&ap_bus_type, NULL, NULL, __ap_revise_reserved); �}
�
�intap_owned_by_def_drv(int card, int queue)drivers/s390/crypto/ap_bus.c +0
-0@@ -758,9 +758,10 @@ static int ap_device_probe(struct device *dev)�
���� if (is_queue_dev(dev)) {
���� ��� /*
-��� ��� �* For apqns marked as reserved/used by ap bus and -��� ��� �* default drivers only drivers with a default flag
Quoted 8 lines
-��� ��� �* will be called for probe this device.
+��� ��� �* If the apqn is marked as reserved/used by ap bus and +��� ��� �* default drivers, only probe with drivers with the default +��� ��� �* flag set. If it is not marked, only probe with drivers +��� ��� �* with the default flag not set.
���� ��� �*/
���� ��� card = AP_QID_CARD(to_ap_queue(dev)->qid);
���� ��� queue = AP_QID_QUEUE(to_ap_queue(dev)->qid);
These hunks don't, however; you probably want to merge them into your patch :)
Nevertheless, the changes look good to me.