diff options
Diffstat (limited to 'drivers/scsi')
-rw-r--r-- | drivers/scsi/sg.c | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/drivers/scsi/sg.c b/drivers/scsi/sg.c index 17216b76efdc..aba28f335b88 100644 --- a/drivers/scsi/sg.c +++ b/drivers/scsi/sg.c | |||
@@ -48,6 +48,7 @@ static int sg_version_num = 30534; /* 2 digits for each component */ | |||
48 | #include <linux/blkdev.h> | 48 | #include <linux/blkdev.h> |
49 | #include <linux/delay.h> | 49 | #include <linux/delay.h> |
50 | #include <linux/scatterlist.h> | 50 | #include <linux/scatterlist.h> |
51 | #include <linux/blktrace_api.h> | ||
51 | 52 | ||
52 | #include "scsi.h" | 53 | #include "scsi.h" |
53 | #include <scsi/scsi_dbg.h> | 54 | #include <scsi/scsi_dbg.h> |
@@ -1067,6 +1068,17 @@ sg_ioctl(struct inode *inode, struct file *filp, | |||
1067 | case BLKSECTGET: | 1068 | case BLKSECTGET: |
1068 | return put_user(sdp->device->request_queue->max_sectors * 512, | 1069 | return put_user(sdp->device->request_queue->max_sectors * 512, |
1069 | ip); | 1070 | ip); |
1071 | case BLKTRACESETUP: | ||
1072 | return blk_trace_setup(sdp->device->request_queue, | ||
1073 | sdp->disk->disk_name, | ||
1074 | sdp->device->sdev_gendev.devt, | ||
1075 | (char *)arg); | ||
1076 | case BLKTRACESTART: | ||
1077 | return blk_trace_startstop(sdp->device->request_queue, 1); | ||
1078 | case BLKTRACESTOP: | ||
1079 | return blk_trace_startstop(sdp->device->request_queue, 0); | ||
1080 | case BLKTRACETEARDOWN: | ||
1081 | return blk_trace_remove(sdp->device->request_queue); | ||
1070 | default: | 1082 | default: |
1071 | if (read_only) | 1083 | if (read_only) |
1072 | return -EPERM; /* don't know so take safe approach */ | 1084 | return -EPERM; /* don't know so take safe approach */ |