projects
/
firefly-linux-kernel-4.4.55.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
video: rockchip: vop: 3399: cabc mode indicate whether cabc enable or not
[firefly-linux-kernel-4.4.55.git]
/
drivers
/
ata
/
libata-scsi.c
diff --git
a/drivers/ata/libata-scsi.c
b/drivers/ata/libata-scsi.c
index 8b3a7861fa44c205490788d4538e5da300270ffb..e417e1a1d02c568595fa465682ade483a9d0645a 100644
(file)
--- a/
drivers/ata/libata-scsi.c
+++ b/
drivers/ata/libata-scsi.c
@@
-675,19
+675,18
@@
static int ata_ioc32(struct ata_port *ap)
int ata_sas_scsi_ioctl(struct ata_port *ap, struct scsi_device *scsidev,
int cmd, void __user *arg)
{
int ata_sas_scsi_ioctl(struct ata_port *ap, struct scsi_device *scsidev,
int cmd, void __user *arg)
{
- int val = -EINVAL, rc = -EINVAL;
+ unsigned long val;
+ int rc = -EINVAL;
unsigned long flags;
switch (cmd) {
unsigned long flags;
switch (cmd) {
- case
ATA_IOC_GET_IO32
:
+ case
HDIO_GET_32BIT
:
spin_lock_irqsave(ap->lock, flags);
val = ata_ioc32(ap);
spin_unlock_irqrestore(ap->lock, flags);
spin_lock_irqsave(ap->lock, flags);
val = ata_ioc32(ap);
spin_unlock_irqrestore(ap->lock, flags);
- if (copy_to_user(arg, &val, 1))
- return -EFAULT;
- return 0;
+ return put_user(val, (unsigned long __user *)arg);
- case
ATA_IOC_SET_IO32
:
+ case
HDIO_SET_32BIT
:
val = (unsigned long) arg;
rc = 0;
spin_lock_irqsave(ap->lock, flags);
val = (unsigned long) arg;
rc = 0;
spin_lock_irqsave(ap->lock, flags);
@@
-3696,9
+3695,6
@@
int ata_scsi_add_hosts(struct ata_host *host, struct scsi_host_template *sht)
*/
shost->max_host_blocked = 1;
*/
shost->max_host_blocked = 1;
- if (scsi_init_shared_tag_map(shost, host->n_tags))
- goto err_add;
-
rc = scsi_add_host_with_dma(ap->scsi_host,
&ap->tdev, ap->host->dev);
if (rc)
rc = scsi_add_host_with_dma(ap->scsi_host,
&ap->tdev, ap->host->dev);
if (rc)