summaryrefslogtreecommitdiffstats
path: root/drivers/s390/crypto
diff options
context:
space:
mode:
authorHolger Dengler <hd@linux.vnet.ibm.com>2011-05-23 10:24:30 +0200
committerMartin Schwidefsky <schwidefsky@de.ibm.com>2011-05-23 10:24:29 +0200
commitcf2d007bd43bc254d5254fe9d30af3e73ed5b98a (patch)
treef2aebec990dbfcd105380cde3ef81db8aafcdbcd /drivers/s390/crypto
parent89db4df160948d005b5efce82ef10f25ab5aac8b (diff)
downloadop-kernel-dev-cf2d007bd43bc254d5254fe9d30af3e73ed5b98a.zip
op-kernel-dev-cf2d007bd43bc254d5254fe9d30af3e73ed5b98a.tar.gz
[S390] ap: skip device registration on type probe failure
The registration of an ap device will be skipped, if the device type probing fails. Add names of current crypto adapters to the Kconfig help. Signed-off-by: Holger Dengler <hd@linux.vnet.ibm.com> Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
Diffstat (limited to 'drivers/s390/crypto')
-rw-r--r--drivers/s390/crypto/ap_bus.c8
1 files changed, 6 insertions, 2 deletions
diff --git a/drivers/s390/crypto/ap_bus.c b/drivers/s390/crypto/ap_bus.c
index 67302b9..16e4a25 100644
--- a/drivers/s390/crypto/ap_bus.c
+++ b/drivers/s390/crypto/ap_bus.c
@@ -1183,8 +1183,12 @@ static void ap_scan_bus(struct work_struct *unused)
INIT_LIST_HEAD(&ap_dev->list);
setup_timer(&ap_dev->timeout, ap_request_timeout,
(unsigned long) ap_dev);
- if (device_type == 0)
- ap_probe_device_type(ap_dev);
+ if (device_type == 0) {
+ if (ap_probe_device_type(ap_dev)) {
+ kfree(ap_dev);
+ continue;
+ }
+ }
else
ap_dev->device_type = device_type;
OpenPOWER on IntegriCloud