summaryrefslogtreecommitdiffstats
path: root/drivers/s390/cio/cio.c
diff options
context:
space:
mode:
authorSebastian Ott <sebott@linux.vnet.ibm.com>2013-04-13 12:53:21 +0200
committerMartin Schwidefsky <schwidefsky@de.ibm.com>2013-04-17 14:07:30 +0200
commit188561a462d3b82451d6ba09e2e32c9ba2c9938c (patch)
treeced10861aad02cad5cac0e232c8c85964dd2dc1f /drivers/s390/cio/cio.c
parent91c15a951091a64a5f048ff93292057e3b590b6f (diff)
downloadop-kernel-dev-188561a462d3b82451d6ba09e2e32c9ba2c9938c.zip
op-kernel-dev-188561a462d3b82451d6ba09e2e32c9ba2c9938c.tar.gz
s390/cio: wait_cons_dev don't use static variable
wait_cons_dev is used to busy wait for an interrupt on the console ccw device. Stop using the static console_subchannel and add a parameter to this function to specify on which ccw device/subchannel we have to do the polling. While at it rename the function to ccw_device_wait_idle and move it to device.c Reviewed-by: Peter Oberparleiter <oberpar@linux.vnet.ibm.com> Signed-off-by: Sebastian Ott <sebott@linux.vnet.ibm.com> Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
Diffstat (limited to 'drivers/s390/cio/cio.c')
-rw-r--r--drivers/s390/cio/cio.c20
1 files changed, 2 insertions, 18 deletions
diff --git a/drivers/s390/cio/cio.c b/drivers/s390/cio/cio.c
index 986ef6a..2c1d53f 100644
--- a/drivers/s390/cio/cio.c
+++ b/drivers/s390/cio/cio.c
@@ -656,9 +656,9 @@ static int console_subchannel_in_use;
/*
* Use cio_tsch to update the subchannel status and call the interrupt handler
- * if status had been pending. Called with the console_subchannel lock.
+ * if status had been pending. Called with the subchannel's lock held.
*/
-static void cio_tsch(struct subchannel *sch)
+void cio_tsch(struct subchannel *sch)
{
struct irb *irb;
int irq_context;
@@ -690,22 +690,6 @@ void *cio_get_console_priv(void)
return &console_priv;
}
-/*
- * busy wait for the next interrupt on the console
- */
-void wait_cons_dev(void)
-{
- if (!console_subchannel_in_use)
- return;
-
- while (1) {
- cio_tsch(&console_subchannel);
- if (console_subchannel.schib.scsw.cmd.actl == 0)
- break;
- udelay_simple(100);
- }
-}
-
static int
cio_test_for_console(struct subchannel_id schid, void *data)
{
OpenPOWER on IntegriCloud