mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-28 18:51:56 -04:00
st: allow debug output to be enabled or disabled via sysfs
Change st driver to allow enabling or disabling debug output via sysfs file /sys/bus/scsi/drivers/st/debug_flag. Previously the only way to enable debug output was: 1. loading the driver with the module parameter debug_flag=1 2. an ioctl call (this method was also the only way to dynamically disable debug output). To use the ioctl you need a second tape drive (if you are actively testing the first tape drive) since a second process cannot open the first tape drive if it is in use. The this change is only functional if the value of the macro DEBUG in st.c is a non-zero value (which it is by default). Signed-off-by: Shane Seymour <[email protected]> Reviewed-by: Laurence Oberman <[email protected]> Acked-by: Kai Mäkisara <[email protected]> Signed-off-by: James Bottomley <[email protected]>
This commit is contained in:
parent
c59ab4e5af
commit
d9b43a10f0
3 changed files with 45 additions and 1 deletions
|
|
@ -569,7 +569,9 @@ Debugging code is now compiled in by default but debugging is turned off
|
|||
with the kernel module parameter debug_flag defaulting to 0. Debugging
|
||||
can still be switched on and off with an ioctl. To enable debug at
|
||||
module load time add debug_flag=1 to the module load options, the
|
||||
debugging output is not voluminous.
|
||||
debugging output is not voluminous. Debugging can also be enabled
|
||||
and disabled by writing a '0' (disable) or '1' (enable) to the sysfs
|
||||
file /sys/bus/scsi/drivers/st/debug_flag.
|
||||
|
||||
If the tape seems to hang, I would be very interested to hear where
|
||||
the driver is waiting. With the command 'ps -l' you can see the state
|
||||
|
|
|
|||
Loading…
Reference in a new issue