mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-29 11:11:45 -04:00
Merge branch 'master' into for-next
Conflicts: MAINTAINERS arch/arm/mach-omap2/pm24xx.c drivers/scsi/bfa/bfa_fcpim.c Needed to update to apply fixes for which the old branch was too outdated.
This commit is contained in:
commit
4b7bd36470
2029 changed files with 37852 additions and 20361 deletions
|
|
@ -2552,8 +2552,11 @@ static void atapi_qc_complete(struct ata_queued_cmd *qc)
|
|||
*
|
||||
* If door lock fails, always clear sdev->locked to
|
||||
* avoid this infinite loop.
|
||||
*
|
||||
* This may happen before SCSI scan is complete. Make
|
||||
* sure qc->dev->sdev isn't NULL before dereferencing.
|
||||
*/
|
||||
if (qc->cdb[0] == ALLOW_MEDIUM_REMOVAL)
|
||||
if (qc->cdb[0] == ALLOW_MEDIUM_REMOVAL && qc->dev->sdev)
|
||||
qc->dev->sdev->locked = 0;
|
||||
|
||||
qc->scsicmd->result = SAM_STAT_CHECK_CONDITION;
|
||||
|
|
@ -3163,8 +3166,8 @@ static inline int __ata_scsi_queuecmd(struct scsi_cmnd *scmd,
|
|||
|
||||
/**
|
||||
* ata_scsi_queuecmd - Issue SCSI cdb to libata-managed device
|
||||
* @shost: SCSI host of command to be sent
|
||||
* @cmd: SCSI command to be sent
|
||||
* @done: Completion function, called when command is complete
|
||||
*
|
||||
* In some cases, this function translates SCSI commands into
|
||||
* ATA taskfiles, and queues the taskfiles to be sent to
|
||||
|
|
@ -3174,37 +3177,36 @@ static inline int __ata_scsi_queuecmd(struct scsi_cmnd *scmd,
|
|||
* ATA and ATAPI devices appearing as SCSI devices.
|
||||
*
|
||||
* LOCKING:
|
||||
* Releases scsi-layer-held lock, and obtains host lock.
|
||||
* ATA host lock
|
||||
*
|
||||
* RETURNS:
|
||||
* Return value from __ata_scsi_queuecmd() if @cmd can be queued,
|
||||
* 0 otherwise.
|
||||
*/
|
||||
int ata_scsi_queuecmd(struct scsi_cmnd *cmd, void (*done)(struct scsi_cmnd *))
|
||||
int ata_scsi_queuecmd(struct Scsi_Host *shost, struct scsi_cmnd *cmd)
|
||||
{
|
||||
struct ata_port *ap;
|
||||
struct ata_device *dev;
|
||||
struct scsi_device *scsidev = cmd->device;
|
||||
struct Scsi_Host *shost = scsidev->host;
|
||||
int rc = 0;
|
||||
unsigned long irq_flags;
|
||||
|
||||
ap = ata_shost_to_port(shost);
|
||||
|
||||
spin_unlock(shost->host_lock);
|
||||
spin_lock(ap->lock);
|
||||
spin_lock_irqsave(ap->lock, irq_flags);
|
||||
|
||||
ata_scsi_dump_cdb(ap, cmd);
|
||||
|
||||
dev = ata_scsi_find_dev(ap, scsidev);
|
||||
if (likely(dev))
|
||||
rc = __ata_scsi_queuecmd(cmd, done, dev);
|
||||
rc = __ata_scsi_queuecmd(cmd, cmd->scsi_done, dev);
|
||||
else {
|
||||
cmd->result = (DID_BAD_TARGET << 16);
|
||||
done(cmd);
|
||||
cmd->scsi_done(cmd);
|
||||
}
|
||||
|
||||
spin_unlock(ap->lock);
|
||||
spin_lock(shost->host_lock);
|
||||
spin_unlock_irqrestore(ap->lock, irq_flags);
|
||||
|
||||
return rc;
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -142,7 +142,7 @@ static int autospeed; /* Chip present which snoops speed changes */
|
|||
static int pio_mask = ATA_PIO4; /* PIO range for autospeed devices */
|
||||
static int iordy_mask = 0xFFFFFFFF; /* Use iordy if available */
|
||||
|
||||
#ifdef PATA_WINBOND_VLB_MODULE
|
||||
#ifdef CONFIG_PATA_WINBOND_VLB_MODULE
|
||||
static int winbond = 1; /* Set to probe Winbond controllers,
|
||||
give I/O port if non standard */
|
||||
#else
|
||||
|
|
|
|||
|
|
@ -652,8 +652,6 @@ static irqreturn_t octeon_cf_interrupt(int irq, void *dev_instance)
|
|||
struct octeon_cf_data *ocd;
|
||||
|
||||
ap = host->ports[i];
|
||||
ocd = ap->dev->platform_data;
|
||||
|
||||
ocd = ap->dev->platform_data;
|
||||
cf_port = ap->private_data;
|
||||
dma_int.u64 =
|
||||
|
|
|
|||
|
|
@ -538,7 +538,7 @@ static int vt8251_prepare_host(struct pci_dev *pdev, struct ata_host **r_host)
|
|||
return 0;
|
||||
}
|
||||
|
||||
static void svia_configure(struct pci_dev *pdev)
|
||||
static void svia_configure(struct pci_dev *pdev, int board_id)
|
||||
{
|
||||
u8 tmp8;
|
||||
|
||||
|
|
@ -577,7 +577,7 @@ static void svia_configure(struct pci_dev *pdev)
|
|||
}
|
||||
|
||||
/*
|
||||
* vt6421 has problems talking to some drives. The following
|
||||
* vt6420/1 has problems talking to some drives. The following
|
||||
* is the fix from Joseph Chan <JosephChan@via.com.tw>.
|
||||
*
|
||||
* When host issues HOLD, device may send up to 20DW of data
|
||||
|
|
@ -596,8 +596,9 @@ static void svia_configure(struct pci_dev *pdev)
|
|||
*
|
||||
* https://bugzilla.kernel.org/show_bug.cgi?id=15173
|
||||
* http://article.gmane.org/gmane.linux.ide/46352
|
||||
* http://thread.gmane.org/gmane.linux.kernel/1062139
|
||||
*/
|
||||
if (pdev->device == 0x3249) {
|
||||
if (board_id == vt6420 || board_id == vt6421) {
|
||||
pci_read_config_byte(pdev, 0x52, &tmp8);
|
||||
tmp8 |= 1 << 2;
|
||||
pci_write_config_byte(pdev, 0x52, tmp8);
|
||||
|
|
@ -652,7 +653,7 @@ static int svia_init_one(struct pci_dev *pdev, const struct pci_device_id *ent)
|
|||
if (rc)
|
||||
return rc;
|
||||
|
||||
svia_configure(pdev);
|
||||
svia_configure(pdev, board_id);
|
||||
|
||||
pci_set_master(pdev);
|
||||
return ata_host_activate(host, pdev->irq, ata_bmdma_interrupt,
|
||||
|
|
|
|||
Loading…
Reference in a new issue