aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/s390/crypto/ap_bus.h
diff options
context:
space:
mode:
authorIngo Tuchscherer <ingo.tuchscherer@linux.vnet.ibm.com>2016-10-14 14:34:51 +0200
committerMartin Schwidefsky <schwidefsky@de.ibm.com>2016-12-14 16:33:39 +0100
commite47de21dd35bad6d1e71482a66699cd04e83ea40 (patch)
tree1089dd285e8cde50690b546db76285efa198b8cc /drivers/s390/crypto/ap_bus.h
parents390/zcrypt: Introduce new zcrypt device status API (diff)
downloadlinux-dev-e47de21dd35bad6d1e71482a66699cd04e83ea40.tar.xz
linux-dev-e47de21dd35bad6d1e71482a66699cd04e83ea40.zip
s390/zcrypt: Fixed attrition of AP adapters and domains
Currently the first eligible AP adapter respectively domain will be selected to service requests. In case of sequential workload, the very same adapter/domain will be used. The adapter/domain selection algorithm now considers the completed transactions per adaper/domain and therefore ensures a homogeneous utilization. Signed-off-by: Ingo Tuchscherer <ingo.tuchscherer@linux.vnet.ibm.com> Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
Diffstat (limited to 'drivers/s390/crypto/ap_bus.h')
-rw-r--r--drivers/s390/crypto/ap_bus.h3
1 files changed, 2 insertions, 1 deletions
diff --git a/drivers/s390/crypto/ap_bus.h b/drivers/s390/crypto/ap_bus.h
index 54b17e142792..4dc7c88fb054 100644
--- a/drivers/s390/crypto/ap_bus.h
+++ b/drivers/s390/crypto/ap_bus.h
@@ -195,6 +195,7 @@ struct ap_card {
unsigned int functions; /* AP device function bitfield. */
int queue_depth; /* AP queue depth.*/
int id; /* AP card number. */
+ atomic_t total_request_count; /* # requests ever for this AP device.*/
};
#define to_ap_card(x) container_of((x), struct ap_card, ap_dev.device)
@@ -211,7 +212,7 @@ struct ap_queue {
enum ap_state state; /* State of the AP device. */
int pendingq_count; /* # requests on pendingq list. */
int requestq_count; /* # requests on requestq list. */
- int total_request_count; /* # requests ever for this AP device. */
+ int total_request_count; /* # requests ever for this AP device.*/
int request_timeout; /* Request timout in jiffies. */
struct timer_list timeout; /* Timer for request timeouts. */
struct list_head pendingq; /* List of message sent to AP queue. */