mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-28 02:32:09 -04:00
Merge branch 'for-linus' of git://git390.osdl.marist.edu/pub/scm/linux-2.6
* 'for-linus' of git://git390.osdl.marist.edu/pub/scm/linux-2.6: [S390] s390: Fix build for !CONFIG_S390_GUEST + CONFIG_VIRTIO_CONSOLE [S390] No more 4kb stacks. [S390] Change default IPL method to IPL_VM. [S390] tape: disable interrupts in tape_open and tape_release [S390] appldata: unsigned ops->size cannot be negative [S390] tape block: complete request with correct locking [S390] Fix sysdev class file creation. [S390] pgtables: Fix race in enable_sie vs. page table ops [S390] qdio: remove incorrect memset [S390] qdio: prevent double qdio shutdown in case of I/O errors
This commit is contained in:
commit
b30fc14c5c
13 changed files with 62 additions and 67 deletions
|
|
@ -76,7 +76,7 @@ tapeblock_trigger_requeue(struct tape_device *device)
|
|||
static void
|
||||
tapeblock_end_request(struct request *req, int error)
|
||||
{
|
||||
if (__blk_end_request(req, error, blk_rq_bytes(req)))
|
||||
if (blk_end_request(req, error, blk_rq_bytes(req)))
|
||||
BUG();
|
||||
}
|
||||
|
||||
|
|
@ -166,7 +166,7 @@ tapeblock_requeue(struct work_struct *work) {
|
|||
nr_queued++;
|
||||
spin_unlock(get_ccwdev_lock(device->cdev));
|
||||
|
||||
spin_lock(&device->blk_data.request_queue_lock);
|
||||
spin_lock_irq(&device->blk_data.request_queue_lock);
|
||||
while (
|
||||
!blk_queue_plugged(queue) &&
|
||||
elv_next_request(queue) &&
|
||||
|
|
@ -176,7 +176,9 @@ tapeblock_requeue(struct work_struct *work) {
|
|||
if (rq_data_dir(req) == WRITE) {
|
||||
DBF_EVENT(1, "TBLOCK: Rejecting write request\n");
|
||||
blkdev_dequeue_request(req);
|
||||
spin_unlock_irq(&device->blk_data.request_queue_lock);
|
||||
tapeblock_end_request(req, -EIO);
|
||||
spin_lock_irq(&device->blk_data.request_queue_lock);
|
||||
continue;
|
||||
}
|
||||
blkdev_dequeue_request(req);
|
||||
|
|
|
|||
|
|
@ -1200,7 +1200,7 @@ tape_open(struct tape_device *device)
|
|||
{
|
||||
int rc;
|
||||
|
||||
spin_lock(get_ccwdev_lock(device->cdev));
|
||||
spin_lock_irq(get_ccwdev_lock(device->cdev));
|
||||
if (device->tape_state == TS_NOT_OPER) {
|
||||
DBF_EVENT(6, "TAPE:nodev\n");
|
||||
rc = -ENODEV;
|
||||
|
|
@ -1218,7 +1218,7 @@ tape_open(struct tape_device *device)
|
|||
tape_state_set(device, TS_IN_USE);
|
||||
rc = 0;
|
||||
}
|
||||
spin_unlock(get_ccwdev_lock(device->cdev));
|
||||
spin_unlock_irq(get_ccwdev_lock(device->cdev));
|
||||
return rc;
|
||||
}
|
||||
|
||||
|
|
@ -1228,11 +1228,11 @@ tape_open(struct tape_device *device)
|
|||
int
|
||||
tape_release(struct tape_device *device)
|
||||
{
|
||||
spin_lock(get_ccwdev_lock(device->cdev));
|
||||
spin_lock_irq(get_ccwdev_lock(device->cdev));
|
||||
if (device->tape_state == TS_IN_USE)
|
||||
tape_state_set(device, TS_UNUSED);
|
||||
module_put(device->discipline->owner);
|
||||
spin_unlock(get_ccwdev_lock(device->cdev));
|
||||
spin_unlock_irq(get_ccwdev_lock(device->cdev));
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -20,6 +20,7 @@ static struct dentry *debugfs_root;
|
|||
#define MAX_DEBUGFS_QUEUES 32
|
||||
static struct dentry *debugfs_queues[MAX_DEBUGFS_QUEUES] = { NULL };
|
||||
static DEFINE_MUTEX(debugfs_mutex);
|
||||
#define QDIO_DEBUGFS_NAME_LEN 40
|
||||
|
||||
void qdio_allocate_do_dbf(struct qdio_initialize *init_data)
|
||||
{
|
||||
|
|
@ -152,17 +153,6 @@ static int qstat_seq_open(struct inode *inode, struct file *filp)
|
|||
filp->f_path.dentry->d_inode->i_private);
|
||||
}
|
||||
|
||||
static void get_queue_name(struct qdio_q *q, struct ccw_device *cdev, char *name)
|
||||
{
|
||||
memset(name, 0, sizeof(name));
|
||||
sprintf(name, "%s", dev_name(&cdev->dev));
|
||||
if (q->is_input_q)
|
||||
sprintf(name + strlen(name), "_input");
|
||||
else
|
||||
sprintf(name + strlen(name), "_output");
|
||||
sprintf(name + strlen(name), "_%d", q->nr);
|
||||
}
|
||||
|
||||
static void remove_debugfs_entry(struct qdio_q *q)
|
||||
{
|
||||
int i;
|
||||
|
|
@ -189,14 +179,17 @@ static struct file_operations debugfs_fops = {
|
|||
static void setup_debugfs_entry(struct qdio_q *q, struct ccw_device *cdev)
|
||||
{
|
||||
int i = 0;
|
||||
char name[40];
|
||||
char name[QDIO_DEBUGFS_NAME_LEN];
|
||||
|
||||
while (debugfs_queues[i] != NULL) {
|
||||
i++;
|
||||
if (i >= MAX_DEBUGFS_QUEUES)
|
||||
return;
|
||||
}
|
||||
get_queue_name(q, cdev, name);
|
||||
snprintf(name, QDIO_DEBUGFS_NAME_LEN, "%s_%s_%d",
|
||||
dev_name(&cdev->dev),
|
||||
q->is_input_q ? "input" : "output",
|
||||
q->nr);
|
||||
debugfs_queues[i] = debugfs_create_file(name, S_IFREG | S_IRUGO | S_IWUSR,
|
||||
debugfs_root, q, &debugfs_fops);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1083,7 +1083,6 @@ void qdio_int_handler(struct ccw_device *cdev, unsigned long intparm,
|
|||
case -EIO:
|
||||
sprintf(dbf_text, "ierr%4x", irq_ptr->schid.sch_no);
|
||||
QDIO_DBF_TEXT2(1, setup, dbf_text);
|
||||
qdio_int_error(cdev);
|
||||
return;
|
||||
case -ETIMEDOUT:
|
||||
sprintf(dbf_text, "qtoh%4x", irq_ptr->schid.sch_no);
|
||||
|
|
|
|||
Loading…
Reference in a new issue