]> git.karo-electronics.de Git - karo-tx-linux.git/commit
s390/cio: Delay scan for newly available I/O devices
authorPeter Oberparleiter <oberpar@linux.vnet.ibm.com>
Tue, 26 Nov 2013 13:58:08 +0000 (14:58 +0100)
committerMartin Schwidefsky <schwidefsky@de.ibm.com>
Mon, 2 Dec 2013 17:15:48 +0000 (18:15 +0100)
commit643796dea8feb15b3be3d252f540c0b2b68bba43
tree7968b59d42212caf1cbd23c72680937c4442dc99
parentb642114ae187f1920598be190c116ec45286f368
s390/cio: Delay scan for newly available I/O devices

The CIO layer scans for newly available I/O devices by performing a scan
of available subchannels using the Store Subchannel (STSCH) instruction.
Performing too many STSCH instructions in a tight loop can cause high
Hypervisor overhead which can negatively impact the performance of the
virtual machine as a whole.

A subchannel scan is triggered for example during a hardware event that
indicates that a channel path has become available. It is also triggered
by the DASD device driver for each device that is set online.

This patch reduces the number of STSCH instructions being performed by
delaying the start of the actual subchannel scan by 1 second. Multiple
scan requests that are scheduled during this time will be merged into a
single scan loop.

The trade-off consists of a short delay that is introduced between
the time that the event is processed and a newly available device
becoming usable. This delay should be acceptable since it only
affects devices that have not been in use before.

Signed-off-by: Peter Oberparleiter <oberpar@linux.vnet.ibm.com>
Reviewed-by: Sebastian Ott <sebott@linux.vnet.ibm.com>
Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
drivers/s390/cio/blacklist.c
drivers/s390/cio/css.c
drivers/s390/cio/css.h