]> git.baikalelectronics.ru Git - kernel.git/commit
s390/zcrypt: rework ap scan bus code
authorHarald Freudenberger <freude@linux.ibm.com>
Thu, 29 Nov 2018 10:50:16 +0000 (11:50 +0100)
committerMartin Schwidefsky <schwidefsky@de.ibm.com>
Thu, 13 Dec 2018 09:42:27 +0000 (10:42 +0100)
commitc48212b84154b02767432a19d24a64eda4f9159a
tree80e949b49d809d4d07866bc56a45d68eb9dea6a1
parent6ad2980284de0a18a4d29d18f5f717602f3fd708
s390/zcrypt: rework ap scan bus code

Rework of the AP bus scan code. The ap_scan_bus() function
is large, so this patch splits the code by introducing a new
new function _ap_scan_bus_adapter() which deals with just
one adapter and thus reduces the scan function code complexity.

Now the AP bus scan can handle a type change of an crypto
adapter on the fly (e.g. from CEX5 to CEX6). This may be
the case with newer versions of zVM where the card may
be pure virtual and a type change is just one click.
However a type or function change requires to unregister
all queue devices and the card device and re-register them.

Comments around the AP bus scan code have been added and/or
improved to provide some hopefully useful hints about what
the code is actually doing.

Signed-off-by: Harald Freudenberger <freude@linux.ibm.com>
Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
drivers/s390/crypto/ap_bus.c