History log of /drivers/s390/char/vmur.h
Revision Date Author Comments
a695f16729e00995fe72baf0e8bee4bf9c232ae0 17-Apr-2008 Frank Munzert <munzert@de.ibm.com> [S390] vmur: Use wait queue instead of mutex to serialize open

If user space opens a unit record device node then vmur is leaving the kernel
with lock open_mutex still held to prevent other processes from opening the
device simultaneously. This causes lockdep to complain about a lock held when
returning to user space.
Now the mutex is replaced by a wait queue to serialize device open.

Signed-off-by: Frank Munzert <munzert@de.ibm.com>
Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
Signed-off-by: Heiko Carstens <heiko.carstens@de.ibm.com>
8127a1f80a002d02a30909ddf6187faedf89e00a 22-Aug-2007 Michael Holzheu <holzheu@de.ibm.com> [S390] vmur: fix reference counting for vmur device structure

When a vmur device is removed due to a detach of the device, currently the
ur device structure is freed. Unfortunately it can happen, that there is
still a user of the device structure, when the character device is open
during the detach process. To fix this, reference counting for the vmur
structure is introduced.
In addition to that, the online, offline, probe and remove functions are
serialized now using a global mutex.

Signed-off-by: Michael Holzheu <holzheu@de.ibm.com>
Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
Signed-off-by: Heiko Carstens <heiko.carstens@de.ibm.com>
4eac34529bce2b4cca9be90a6903c965baa8193c 10-Aug-2007 Michael Holzheu <holzheu@de.ibm.com> [S390] vmur: add "top of queue" sanity check for reader open

If the z/VM reader is already open, it can happen that after opening the
Linux reader device, not the topmost file is processed. According the
semantics of the Linux z/VM unit record device driver, always the topmost
file has to be processed. With this fix an error is returned if that is
not the case.

Signed-off-by: Michael Holzheu <holzheu@de.ibm.com>
Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
f2405598e0678e9c93dd780f2a12fc562ece3d13 10-Aug-2007 Michael Holzheu <holzheu@de.ibm.com> [S390] vmur: reject open on z/VM reader files with status HOLD

If a reader file with HOLD status is at the top of the reader queue, currently
all read requests will return data of the second file in the queue. But the
semantics of vmur is that always the topmost file is read. With this fix
-EPERM is returned on open, if the topmost reader file is in HOLD status.

Signed-off-by: Michael Holzheu <holzheu@de.ibm.com>
Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
810cb5b32ded8f28880b502e984d807d03869d3b 17-Jul-2007 Frank Munzert <munzert@de.ibm.com> [S390] z/VM unit record device driver

z/VM Unit record character device driver to access VM reader, punch,
and printer.

Signed-off-by: Frank Munzert <munzert@de.ibm.com>
Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>