Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 75399
b: refs/heads/master
c: d1ec729
h: refs/heads/master
i:
  75397: cd70a2c
  75395: 69efeb9
  75391: 6e6905c
v: v3
  • Loading branch information
Zhao Yakui authored and Len Brown committed Jan 11, 2008
1 parent 5da7a79 commit 11bb03e
Show file tree
Hide file tree
Showing 21 changed files with 63 additions and 158 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: aa7f00741da5e2adeca3e03103d14b9141040e49
refs/heads/master: d1ec7298fcefd7e4d1ca612da402ce9e5d5e2c13
8 changes: 0 additions & 8 deletions trunk/Documentation/kernel-parameters.txt
Original file line number Diff line number Diff line change
Expand Up @@ -883,14 +883,6 @@ and is between 256 and 4096 characters. It is defined in the file
lapic_timer_c2_ok [X86-32,x86-64,APIC] trust the local apic timer in
C2 power state.

libata.dma= [LIBATA] DMA control
libata.dma=0 Disable all PATA and SATA DMA
libata.dma=1 PATA and SATA Disk DMA only
libata.dma=2 ATAPI (CDROM) DMA only
libata.dma=4 Compact Flash DMA only
Combinations also work, so libata.dma=3 enables DMA
for disks and CDROMs, but not CFs.

libata.noacpi [LIBATA] Disables use of ACPI in libata suspend/resume
when set.
Format: <int>
Expand Down
8 changes: 4 additions & 4 deletions trunk/drivers/acpi/events/evregion.c
Original file line number Diff line number Diff line change
Expand Up @@ -344,15 +344,15 @@ acpi_ev_address_space_dispatch(union acpi_operand_object *region_obj,
* setup will potentially execute control methods
* (e.g., _REG method for this region)
*/
acpi_ex_exit_interpreter();
acpi_ex_relinquish_interpreter();

status = region_setup(region_obj, ACPI_REGION_ACTIVATE,
handler_desc->address_space.context,
&region_context);

/* Re-enter the interpreter */

acpi_ex_enter_interpreter();
acpi_ex_reacquire_interpreter();

/* Check for failure of the Region Setup */

Expand Down Expand Up @@ -405,7 +405,7 @@ acpi_ev_address_space_dispatch(union acpi_operand_object *region_obj,
* exit the interpreter because the handler *might* block -- we don't
* know what it will do, so we can't hold the lock on the intepreter.
*/
acpi_ex_exit_interpreter();
acpi_ex_relinquish_interpreter();
}

/* Call the handler */
Expand All @@ -426,7 +426,7 @@ acpi_ev_address_space_dispatch(union acpi_operand_object *region_obj,
* We just returned from a non-default handler, we must re-enter the
* interpreter
*/
acpi_ex_enter_interpreter();
acpi_ex_reacquire_interpreter();
}

return_ACPI_STATUS(status);
Expand Down
9 changes: 0 additions & 9 deletions trunk/drivers/acpi/pci_irq.c
Original file line number Diff line number Diff line change
Expand Up @@ -429,15 +429,6 @@ int acpi_pci_irq_enable(struct pci_dev *dev)
&polarity, &link,
acpi_pci_allocate_irq);

if (irq < 0) {
/*
* IDE legacy mode controller IRQs are magic. Why do compat
* extensions always make such a nasty mess.
*/
if (dev->class >> 8 == PCI_CLASS_STORAGE_IDE &&
(dev->class & 0x05) == 0)
return 0;
}
/*
* No IRQ known to the ACPI subsystem - maybe the BIOS /
* driver reported one, then use it. Exit in any case.
Expand Down
24 changes: 8 additions & 16 deletions trunk/drivers/ata/libata-eh.c
Original file line number Diff line number Diff line change
Expand Up @@ -1733,15 +1733,11 @@ static void ata_eh_link_autopsy(struct ata_link *link)
ehc->i.action &= ~ATA_EH_PERDEV_MASK;
}

/* propagate timeout to host link */
if ((all_err_mask & AC_ERR_TIMEOUT) && !ata_is_host_link(link))
ap->link.eh_context.i.err_mask |= AC_ERR_TIMEOUT;

/* record error and consider speeding down */
/* consider speeding down */
dev = ehc->i.dev;
if (!dev && ((ata_link_max_devices(link) == 1 &&
ata_dev_enabled(link->device))))
dev = link->device;
if (!dev && ata_link_max_devices(link) == 1 &&
ata_dev_enabled(link->device))
dev = link->device;

if (dev)
ehc->i.action |= ata_eh_speed_down(dev, is_io, all_err_mask);
Expand All @@ -1763,14 +1759,8 @@ void ata_eh_autopsy(struct ata_port *ap)
{
struct ata_link *link;

ata_port_for_each_link(link, ap)
__ata_port_for_each_link(link, ap)
ata_eh_link_autopsy(link);

/* Autopsy of fanout ports can affect host link autopsy.
* Perform host link autopsy last.
*/
if (ap->nr_pmp_links)
ata_eh_link_autopsy(&ap->link);
}

/**
Expand Down Expand Up @@ -2167,11 +2157,13 @@ int ata_eh_reset(struct ata_link *link, int classify,
if (ata_link_offline(link))
continue;

/* apply class override */
/* apply class override and convert UNKNOWN to NONE */
if (lflags & ATA_LFLAG_ASSUME_ATA)
classes[dev->devno] = ATA_DEV_ATA;
else if (lflags & ATA_LFLAG_ASSUME_SEMB)
classes[dev->devno] = ATA_DEV_SEMB_UNSUP; /* not yet */
else if (classes[dev->devno] == ATA_DEV_UNKNOWN)
classes[dev->devno] = ATA_DEV_NONE;
}

/* record current link speed */
Expand Down
12 changes: 7 additions & 5 deletions trunk/drivers/ata/libata-pmp.c
Original file line number Diff line number Diff line change
Expand Up @@ -495,12 +495,14 @@ static void sata_pmp_quirks(struct ata_port *ap)
/* SError.N need a kick in the ass to get working */
link->flags |= ATA_LFLAG_HRST_TO_RESUME;

/* Class code report is unreliable and SRST
* times out under certain configurations.
* Config device can be at port 0 or 5 and
* locks up on SRST.
/* class code report is unreliable */
if (link->pmp < 5)
link->flags |= ATA_LFLAG_ASSUME_ATA;

/* The config device, which can be either at
* port 0 or 5, locks up on SRST.
*/
if (link->pmp <= 5)
if (link->pmp == 0 || link->pmp == 5)
link->flags |= ATA_LFLAG_NO_SRST |
ATA_LFLAG_ASSUME_ATA;

Expand Down
3 changes: 1 addition & 2 deletions trunk/drivers/ata/libata-scsi.c
Original file line number Diff line number Diff line change
Expand Up @@ -872,8 +872,7 @@ int ata_scsi_slave_config(struct scsi_device *sdev)

ata_scsi_sdev_config(sdev);

if (dev->class == ATA_DEV_ATA)
sdev->manage_start_stop = 1;
sdev->manage_start_stop = 1;

if (dev)
ata_scsi_dev_config(sdev, dev);
Expand Down
7 changes: 2 additions & 5 deletions trunk/drivers/ata/libata-sff.c
Original file line number Diff line number Diff line change
Expand Up @@ -806,18 +806,15 @@ int ata_pci_init_one(struct pci_dev *pdev,
if (rc)
goto err_out;

if (!legacy_mode && pdev->irq) {
/* We may have no IRQ assigned in which case we can poll. This
shouldn't happen on a sane system but robustness is cheap
in this case */
if (!legacy_mode) {
rc = devm_request_irq(dev, pdev->irq, pi->port_ops->irq_handler,
IRQF_SHARED, DRV_NAME, host);
if (rc)
goto err_out;

ata_port_desc(host->ports[0], "irq %d", pdev->irq);
ata_port_desc(host->ports[1], "irq %d", pdev->irq);
} else if (legacy_mode) {
} else {
if (!ata_port_is_dummy(host->ports[0])) {
rc = devm_request_irq(dev, ATA_PRIMARY_IRQ(pdev),
pi->port_ops->irq_handler,
Expand Down
3 changes: 1 addition & 2 deletions trunk/drivers/ata/pata_ixp4xx_cf.c
Original file line number Diff line number Diff line change
Expand Up @@ -130,11 +130,10 @@ static struct ata_port_operations ixp4xx_port_ops = {
.port_start = ata_port_start,
};

static void ixp4xx_setup_port(struct ata_port *ap,
static void ixp4xx_setup_port(struct ata_ioports *ioaddr,
struct ixp4xx_pata_data *data,
unsigned long raw_cs0, unsigned long raw_cs1)
{
struct ata_ioports *ioaddr = &ap->ioaddr;
unsigned long raw_cmd = raw_cs0;
unsigned long raw_ctl = raw_cs1 + 0x06;

Expand Down
15 changes: 2 additions & 13 deletions trunk/drivers/ata/pata_pdc202xx_old.c
Original file line number Diff line number Diff line change
Expand Up @@ -215,8 +215,8 @@ static void pdc2026x_bmdma_stop(struct ata_queued_cmd *qc)
/* Flip back to 33Mhz for PIO */
if (adev->dma_mode >= XFER_UDMA_2)
iowrite8(ioread8(clock) & ~sel66, clock);

ata_bmdma_stop(qc);
pdc202xx_set_piomode(ap, adev);
}

/**
Expand All @@ -233,17 +233,6 @@ static void pdc2026x_dev_config(struct ata_device *adev)
adev->max_sectors = 256;
}

static int pdc2026x_port_start(struct ata_port *ap)
{
void __iomem *bmdma = ap->ioaddr.bmdma_addr;
if (bmdma) {
/* Enable burst mode */
u8 burst = ioread8(bmdma + 0x1f);
iowrite8(burst | 0x01, bmdma + 0x1f);
}
return ata_sff_port_start(ap);
}

static struct scsi_host_template pdc202xx_sht = {
.module = THIS_MODULE,
.name = DRV_NAME,
Expand Down Expand Up @@ -324,7 +313,7 @@ static struct ata_port_operations pdc2026x_port_ops = {
.irq_clear = ata_bmdma_irq_clear,
.irq_on = ata_irq_on,

.port_start = pdc2026x_port_start,
.port_start = ata_sff_port_start,
};

static int pdc202xx_init_one(struct pci_dev *dev, const struct pci_device_id *id)
Expand Down
2 changes: 1 addition & 1 deletion trunk/drivers/ata/sata_qstor.c
Original file line number Diff line number Diff line change
Expand Up @@ -270,7 +270,7 @@ static int qs_scr_read(struct ata_port *ap, unsigned int sc_reg, u32 *val)
static void qs_error_handler(struct ata_port *ap)
{
qs_enter_reg_mode(ap);
ata_do_eh(ap, qs_prereset, NULL, sata_std_hardreset,
ata_do_eh(ap, qs_prereset, ata_std_softreset, NULL,
ata_std_postreset);
}

Expand Down
37 changes: 11 additions & 26 deletions trunk/drivers/ata/sata_sil24.c
Original file line number Diff line number Diff line change
Expand Up @@ -832,39 +832,24 @@ static int sil24_qc_defer(struct ata_queued_cmd *qc)
struct ata_link *link = qc->dev->link;
struct ata_port *ap = link->ap;
u8 prot = qc->tf.protocol;

/*
* There is a bug in the chip:
* Port LRAM Causes the PRB/SGT Data to be Corrupted
* If the host issues a read request for LRAM and SActive registers
* while active commands are available in the port, PRB/SGT data in
* the LRAM can become corrupted. This issue applies only when
* reading from, but not writing to, the LRAM.
*
* Therefore, reading LRAM when there is no particular error [and
* other commands may be outstanding] is prohibited.
*
* To avoid this bug there are two situations where a command must run
* exclusive of any other commands on the port:
*
* - ATAPI commands which check the sense data
* - Passthrough ATA commands which always have ATA_QCFLAG_RESULT_TF
* set.
*
*/
int is_excl = (prot == ATA_PROT_ATAPI ||
prot == ATA_PROT_ATAPI_NODATA ||
prot == ATA_PROT_ATAPI_DMA ||
(qc->flags & ATA_QCFLAG_RESULT_TF));

int is_atapi = (prot == ATA_PROT_ATAPI ||
prot == ATA_PROT_ATAPI_NODATA ||
prot == ATA_PROT_ATAPI_DMA);

/* ATAPI commands completing with CHECK_SENSE cause various
* weird problems if other commands are active. PMP DMA CS
* errata doesn't cover all and HSM violation occurs even with
* only one other device active. Always run an ATAPI command
* by itself.
*/
if (unlikely(ap->excl_link)) {
if (link == ap->excl_link) {
if (ap->nr_active_links)
return ATA_DEFER_PORT;
qc->flags |= ATA_QCFLAG_CLEAR_EXCL;
} else
return ATA_DEFER_PORT;
} else if (unlikely(is_excl)) {
} else if (unlikely(is_atapi)) {
ap->excl_link = link;
if (ap->nr_active_links)
return ATA_DEFER_PORT;
Expand Down
4 changes: 2 additions & 2 deletions trunk/drivers/crypto/padlock-aes.c
Original file line number Diff line number Diff line change
Expand Up @@ -429,8 +429,8 @@ static inline void padlock_xcrypt(const u8 *input, u8 *output, void *key,

static void aes_crypt_copy(const u8 *in, u8 *out, u32 *key, struct cword *cword)
{
u8 buf[AES_BLOCK_SIZE * 2 + PADLOCK_ALIGNMENT - 1];
u8 *tmp = PTR_ALIGN(&buf[0], PADLOCK_ALIGNMENT);
u8 tmp[AES_BLOCK_SIZE * 2]
__attribute__ ((__aligned__(PADLOCK_ALIGNMENT)));

memcpy(tmp, in, AES_BLOCK_SIZE);
padlock_xcrypt(tmp, out, key, cword);
Expand Down
36 changes: 1 addition & 35 deletions trunk/drivers/ide/ide-acpi.c
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,6 @@
#include <acpi/acpi.h>
#include <linux/ide.h>
#include <linux/pci.h>
#include <linux/dmi.h>

#include <acpi/acpi_bus.h>
#include <acpi/acnames.h>
Expand Down Expand Up @@ -66,37 +65,6 @@ extern int ide_noacpi;
extern int ide_noacpitfs;
extern int ide_noacpionboot;

static bool ide_noacpi_psx;
static int no_acpi_psx(const struct dmi_system_id *id)
{
ide_noacpi_psx = true;
printk(KERN_NOTICE"%s detected - disable ACPI _PSx.\n", id->ident);
return 0;
}

static const struct dmi_system_id ide_acpi_dmi_table[] = {
/* Bug 9673. */
/* We should check if this is because ACPI NVS isn't save/restored. */
{
.callback = no_acpi_psx,
.ident = "HP nx9005",
.matches = {
DMI_MATCH(DMI_BIOS_VENDOR, "Phoenix Technologies Ltd."),
DMI_MATCH(DMI_BIOS_VERSION, "KAM1.60")
},
},
};

static int ide_acpi_blacklist(void)
{
static int done;
if (done)
return 0;
done = 1;
dmi_check_system(ide_acpi_dmi_table);
return 0;
}

/**
* ide_get_dev_handle - finds acpi_handle and PCI device.function
* @dev: device to locate
Expand Down Expand Up @@ -655,7 +623,7 @@ void ide_acpi_set_state(ide_hwif_t *hwif, int on)
{
int unit;

if (ide_noacpi || ide_noacpi_psx)
if (ide_noacpi)
return;

DEBPRINT("ENTER:\n");
Expand Down Expand Up @@ -700,8 +668,6 @@ void ide_acpi_init(ide_hwif_t *hwif)
struct ide_acpi_drive_link *master;
struct ide_acpi_drive_link *slave;

ide_acpi_blacklist();

hwif->acpidata = kzalloc(sizeof(struct ide_acpi_hwif_link), GFP_KERNEL);
if (!hwif->acpidata)
return;
Expand Down
6 changes: 3 additions & 3 deletions trunk/drivers/ide/ide-iops.c
Original file line number Diff line number Diff line change
Expand Up @@ -612,12 +612,12 @@ u8 eighty_ninty_three (ide_drive_t *drive)
printk(KERN_DEBUG "%s: skipping word 93 validity check\n",
drive->name);

if (ide_dev_is_sata(id) && !ivb)
return 1;

if (hwif->cbl != ATA_CBL_PATA80 && !ivb)
goto no_80w;

if (ide_dev_is_sata(id))
return 1;

/*
* FIXME:
* - force bit13 (80c cable present) check also for !ivb devices
Expand Down
Loading

0 comments on commit 11bb03e

Please sign in to comment.