Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 56995
b: refs/heads/master
c: 1c1ee4c
h: refs/heads/master
i:
  56993: 9768f72
  56991: 06608c6
v: v3
  • Loading branch information
Linus Torvalds committed May 25, 2007
1 parent ebea8a9 commit cbe8df5
Show file tree
Hide file tree
Showing 27 changed files with 168 additions and 104 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: 14e50e57aedb2a89cf79b77782879769794cab7b
refs/heads/master: 1c1ee4c3e7e16d23166a624a132889df3c540a18
5 changes: 3 additions & 2 deletions trunk/Documentation/filesystems/directory-locking
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
Locking scheme used for directory operations is based on two
kinds of locks - per-inode (->i_sem) and per-filesystem (->s_vfs_rename_sem).
kinds of locks - per-inode (->i_mutex) and per-filesystem
(->s_vfs_rename_mutex).

For our purposes all operations fall in 5 classes:

Expand Down Expand Up @@ -63,7 +64,7 @@ objects - A < B iff A is an ancestor of B.
attempt to acquire some lock and already holds at least one lock. Let's
consider the set of contended locks. First of all, filesystem lock is
not contended, since any process blocked on it is not holding any locks.
Thus all processes are blocked on ->i_sem.
Thus all processes are blocked on ->i_mutex.

Non-directory objects are not contended due to (3). Thus link
creation can't be a part of deadlock - it can't be blocked on source
Expand Down
8 changes: 4 additions & 4 deletions trunk/Documentation/filesystems/porting
Original file line number Diff line number Diff line change
Expand Up @@ -107,7 +107,7 @@ free to drop it...
---
[informational]

->link() callers hold ->i_sem on the object we are linking to. Some of your
->link() callers hold ->i_mutex on the object we are linking to. Some of your
problems might be over...

---
Expand All @@ -130,9 +130,9 @@ went in - and hadn't been documented ;-/). Just remove it from fs_flags
---
[mandatory]

->setattr() is called without BKL now. Caller _always_ holds ->i_sem, so
watch for ->i_sem-grabbing code that might be used by your ->setattr().
Callers of notify_change() need ->i_sem now.
->setattr() is called without BKL now. Caller _always_ holds ->i_mutex, so
watch for ->i_mutex-grabbing code that might be used by your ->setattr().
Callers of notify_change() need ->i_mutex now.

---
[recommended]
Expand Down
2 changes: 1 addition & 1 deletion trunk/arch/ia64/kernel/acpi-processor.c
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ static void init_intel_pdc(struct acpi_processor *pr)

buf[0] = ACPI_PDC_REVISION_ID;
buf[1] = 1;
buf[2] |= ACPI_PDC_EST_CAPABILITY_SMP;
buf[2] = ACPI_PDC_EST_CAPABILITY_SMP;

obj->type = ACPI_TYPE_BUFFER;
obj->buffer.length = 12;
Expand Down
3 changes: 2 additions & 1 deletion trunk/arch/ia64/kernel/acpi.c
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,8 @@ EXPORT_SYMBOL(pm_power_off);
unsigned int acpi_cpei_override;
unsigned int acpi_cpei_phys_cpuid;

const char *acpi_get_sysname(void)
const char __init *
acpi_get_sysname(void)
{
#ifdef CONFIG_IA64_GENERIC
unsigned long rsdp_phys;
Expand Down
4 changes: 2 additions & 2 deletions trunk/arch/ia64/kernel/smpboot.c
Original file line number Diff line number Diff line change
Expand Up @@ -370,7 +370,7 @@ smp_setup_percpu_timer (void)
{
}

static void __devinit
static void __cpuinit
smp_callin (void)
{
int cpuid, phys_id, itc_master;
Expand Down Expand Up @@ -456,7 +456,7 @@ smp_callin (void)
/*
* Activate a secondary processor. head.S calls this.
*/
int __devinit
int __cpuinit
start_secondary (void *unused)
{
/* Early console may use I/O ports */
Expand Down
2 changes: 1 addition & 1 deletion trunk/arch/mips/sgi-ip32/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -3,5 +3,5 @@
# under Linux.
#

obj-y += ip32-berr.o ip32-irq.o ip32-setup.o ip32-reset.o \
obj-y += ip32-berr.o ip32-irq.o ip32-platform.o ip32-setup.o ip32-reset.o \
crime.o ip32-memory.o
20 changes: 20 additions & 0 deletions trunk/arch/mips/sgi-ip32/ip32-platform.c
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
#include <linux/init.h>
#include <linux/platform_device.h>

static __init int meth_devinit(void)
{
struct platform_device *pd;
int ret;

pd = platform_device_alloc("meth", -1);
if (!pd)
return -ENOMEM;

ret = platform_device_add(pd);
if (ret)
platform_device_put(pd);

return ret;
}

device_initcall(meth_devinit);
1 change: 1 addition & 0 deletions trunk/drivers/ata/ata_piix.c
Original file line number Diff line number Diff line change
Expand Up @@ -578,6 +578,7 @@ static const struct ich_laptop ich_laptop[] = {
{ 0x27DF, 0x0005, 0x0280 }, /* ICH7 on Acer 5602WLMi */
{ 0x27DF, 0x1025, 0x0110 }, /* ICH7 on Acer 3682WLMi */
{ 0x27DF, 0x1043, 0x1267 }, /* ICH7 on Asus W5F */
{ 0x24CA, 0x1025, 0x0061 }, /* ICH4 on ACER Aspire 2023WLMi */
/* end marker */
{ 0, }
};
Expand Down
4 changes: 2 additions & 2 deletions trunk/drivers/ata/libata-core.c
Original file line number Diff line number Diff line change
Expand Up @@ -3022,7 +3022,7 @@ int ata_wait_ready(struct ata_port *ap, unsigned long deadline)

if (!(status & ATA_BUSY))
return 0;
if (status == 0xff)
if (!ata_port_online(ap) && status == 0xff)
return -ENODEV;
if (time_after(now, deadline))
return -EBUSY;
Expand Down Expand Up @@ -3368,7 +3368,7 @@ int ata_std_prereset(struct ata_port *ap, unsigned long deadline)
*/
if (!(ap->flags & ATA_FLAG_SKIP_D2H_BSY) && !ata_port_offline(ap)) {
rc = ata_wait_ready(ap, deadline);
if (rc) {
if (rc && rc != -ENODEV) {
ata_port_printk(ap, KERN_WARNING, "device not ready "
"(errno=%d), forcing hardreset\n", rc);
ehc->i.action |= ATA_EH_HARDRESET;
Expand Down
4 changes: 2 additions & 2 deletions trunk/drivers/ata/pata_hpt3x2n.c
Original file line number Diff line number Diff line change
Expand Up @@ -521,8 +521,8 @@ static int hpt3x2n_init_one(struct pci_dev *dev, const struct pci_device_id *id)
/* 371N if rev > 1 */
break;
case PCI_DEVICE_ID_TTI_HPT372:
/* 372N if rev >= 1*/
if (class_rev == 0)
/* 372N if rev >= 2*/
if (class_rev < 2)
return -ENODEV;
break;
case PCI_DEVICE_ID_TTI_HPT302:
Expand Down
46 changes: 23 additions & 23 deletions trunk/drivers/ata/pata_sis.c
Original file line number Diff line number Diff line change
Expand Up @@ -73,14 +73,14 @@ static int sis_short_ata40(struct pci_dev *dev)
}

/**
* sis_port_base - return PCI configuration base for dev
* sis_old_port_base - return PCI configuration base for dev
* @adev: device
*
* Returns the base of the PCI configuration registers for this port
* number.
*/

static int sis_port_base(struct ata_device *adev)
static int sis_old_port_base(struct ata_device *adev)
{
return 0x40 + (4 * adev->ap->port_no) + (2 * adev->devno);
}
Expand Down Expand Up @@ -211,7 +211,7 @@ static void sis_set_fifo(struct ata_port *ap, struct ata_device *adev)
static void sis_old_set_piomode (struct ata_port *ap, struct ata_device *adev)
{
struct pci_dev *pdev = to_pci_dev(ap->host->dev);
int port = sis_port_base(adev);
int port = sis_old_port_base(adev);
u8 t1, t2;
int speed = adev->pio_mode - XFER_PIO_0;

Expand Down Expand Up @@ -248,7 +248,7 @@ static void sis_old_set_piomode (struct ata_port *ap, struct ata_device *adev)
static void sis_100_set_piomode (struct ata_port *ap, struct ata_device *adev)
{
struct pci_dev *pdev = to_pci_dev(ap->host->dev);
int port = sis_port_base(adev);
int port = sis_old_port_base(adev);
int speed = adev->pio_mode - XFER_PIO_0;

const u8 actrec[] = { 0x00, 0x67, 0x44, 0x33, 0x31 };
Expand Down Expand Up @@ -328,7 +328,7 @@ static void sis_old_set_dmamode (struct ata_port *ap, struct ata_device *adev)
{
struct pci_dev *pdev = to_pci_dev(ap->host->dev);
int speed = adev->dma_mode - XFER_MW_DMA_0;
int drive_pci = sis_port_base(adev);
int drive_pci = sis_old_port_base(adev);
u16 timing;

const u16 mwdma_bits[] = { 0x707, 0x202, 0x202 };
Expand Down Expand Up @@ -367,7 +367,7 @@ static void sis_66_set_dmamode (struct ata_port *ap, struct ata_device *adev)
{
struct pci_dev *pdev = to_pci_dev(ap->host->dev);
int speed = adev->dma_mode - XFER_MW_DMA_0;
int drive_pci = sis_port_base(adev);
int drive_pci = sis_old_port_base(adev);
u16 timing;

const u16 mwdma_bits[] = { 0x707, 0x202, 0x202 };
Expand All @@ -378,12 +378,12 @@ static void sis_66_set_dmamode (struct ata_port *ap, struct ata_device *adev)
if (adev->dma_mode < XFER_UDMA_0) {
/* bits 3-0 hold recovery timing bits 8-10 active timing and
the higer bits are dependant on the device, bit 15 udma */
timing &= ~ 0x870F;
timing &= ~0x870F;
timing |= mwdma_bits[speed];
} else {
/* Bit 15 is UDMA on/off, bit 12-14 are cycle time */
speed = adev->dma_mode - XFER_UDMA_0;
timing &= ~0x6000;
timing &= ~0xF000;
timing |= udma_bits[speed];
}
pci_write_config_word(pdev, drive_pci, timing);
Expand All @@ -405,22 +405,22 @@ static void sis_100_set_dmamode (struct ata_port *ap, struct ata_device *adev)
{
struct pci_dev *pdev = to_pci_dev(ap->host->dev);
int speed = adev->dma_mode - XFER_MW_DMA_0;
int drive_pci = sis_port_base(adev);
u16 timing;
int drive_pci = sis_old_port_base(adev);
u8 timing;

const u16 udma_bits[] = { 0x8B00, 0x8700, 0x8500, 0x8300, 0x8200, 0x8100};
const u8 udma_bits[] = { 0x8B, 0x87, 0x85, 0x83, 0x82, 0x81};

pci_read_config_word(pdev, drive_pci, &timing);
pci_read_config_byte(pdev, drive_pci + 1, &timing);

if (adev->dma_mode < XFER_UDMA_0) {
/* NOT SUPPORTED YET: NEED DATA SHEET. DITTO IN OLD DRIVER */
} else {
/* Bit 15 is UDMA on/off, bit 12-14 are cycle time */
/* Bit 7 is UDMA on/off, bit 0-3 are cycle time */
speed = adev->dma_mode - XFER_UDMA_0;
timing &= ~0x0F00;
timing &= ~0x8F;
timing |= udma_bits[speed];
}
pci_write_config_word(pdev, drive_pci, timing);
pci_write_config_byte(pdev, drive_pci + 1, timing);
}

/**
Expand All @@ -440,22 +440,22 @@ static void sis_133_early_set_dmamode (struct ata_port *ap, struct ata_device *a
{
struct pci_dev *pdev = to_pci_dev(ap->host->dev);
int speed = adev->dma_mode - XFER_MW_DMA_0;
int drive_pci = sis_port_base(adev);
u16 timing;

static const u16 udma_bits[] = { 0x8F00, 0x8A00, 0x8700, 0x8500, 0x8300, 0x8200, 0x8100};
int drive_pci = sis_old_port_base(adev);
u8 timing;
/* Low 4 bits are timing */
static const u8 udma_bits[] = { 0x8F, 0x8A, 0x87, 0x85, 0x83, 0x82, 0x81};

pci_read_config_word(pdev, drive_pci, &timing);
pci_read_config_byte(pdev, drive_pci + 1, &timing);

if (adev->dma_mode < XFER_UDMA_0) {
/* NOT SUPPORTED YET: NEED DATA SHEET. DITTO IN OLD DRIVER */
} else {
/* Bit 15 is UDMA on/off, bit 12-14 are cycle time */
/* Bit 7 is UDMA on/off, bit 0-3 are cycle time */
speed = adev->dma_mode - XFER_UDMA_0;
timing &= ~0x0F00;
timing &= ~0x8F;
timing |= udma_bits[speed];
}
pci_write_config_word(pdev, drive_pci, timing);
pci_write_config_byte(pdev, drive_pci + 1, timing);
}

/**
Expand Down
29 changes: 29 additions & 0 deletions trunk/drivers/ata/pata_via.c
Original file line number Diff line number Diff line change
Expand Up @@ -60,6 +60,7 @@
#include <linux/delay.h>
#include <scsi/scsi_host.h>
#include <linux/libata.h>
#include <linux/dmi.h>

#define DRV_NAME "pata_via"
#define DRV_VERSION "0.3.1"
Expand Down Expand Up @@ -122,6 +123,31 @@ static const struct via_isa_bridge {
{ NULL }
};


/*
* Cable special cases
*/

static struct dmi_system_id cable_dmi_table[] = {
{
.ident = "Acer Ferrari 3400",
.matches = {
DMI_MATCH(DMI_BOARD_VENDOR, "Acer,Inc."),
DMI_MATCH(DMI_BOARD_NAME, "Ferrari 3400"),
},
},
{ }
};

static int via_cable_override(struct pci_dev *pdev)
{
/* Systems by DMI */
if (dmi_check_system(cable_dmi_table))
return 1;
return 0;
}


/**
* via_cable_detect - cable detection
* @ap: ATA port
Expand All @@ -139,6 +165,9 @@ static int via_cable_detect(struct ata_port *ap) {
struct pci_dev *pdev = to_pci_dev(ap->host->dev);
u32 ata66;

if (via_cable_override(pdev))
return ATA_CBL_PATA40_SHORT;

/* Early chips are 40 wire */
if ((config->flags & VIA_UDMA) < VIA_UDMA_66)
return ATA_CBL_PATA40;
Expand Down
2 changes: 1 addition & 1 deletion trunk/drivers/net/Kconfig
Original file line number Diff line number Diff line change
Expand Up @@ -2218,7 +2218,7 @@ config SK98LIN

config VIA_VELOCITY
tristate "VIA Velocity support"
depends on NET_PCI && PCI
depends on PCI
select CRC32
select CRC_CCITT
select MII
Expand Down
2 changes: 1 addition & 1 deletion trunk/drivers/net/chelsio/suni1x10gexp_regs.h
Original file line number Diff line number Diff line change
Expand Up @@ -105,7 +105,7 @@
#define mSUNI1x10GEXP_REG_RXXG_EXACT_MATCH_ADDR_LOW(filterId) (0x204A + mSUNI1x10GEXP_MAC_FILTER_OFFSET(filterId))
#define mSUNI1x10GEXP_REG_RXXG_EXACT_MATCH_ADDR_MID(filterId) (0x204B + mSUNI1x10GEXP_MAC_FILTER_OFFSET(filterId))
#define mSUNI1x10GEXP_REG_RXXG_EXACT_MATCH_ADDR_HIGH(filterId)(0x204C + mSUNI1x10GEXP_MAC_FILTER_OFFSET(filterId))
#define mSUNI1x10GEXP_REG_RXXG_EXACT_MATCH_VID(filterId) (0x2062 + mSUNI1x10GEXP_MAC_VID_FILTER_OFFSET(filterId)
#define mSUNI1x10GEXP_REG_RXXG_EXACT_MATCH_VID(filterId) (0x2062 + mSUNI1x10GEXP_MAC_VID_FILTER_OFFSET(filterId))
#define SUNI1x10GEXP_REG_RXXG_EXACT_MATCH_ADDR_0_LOW 0x204A
#define SUNI1x10GEXP_REG_RXXG_EXACT_MATCH_ADDR_0_MID 0x204B
#define SUNI1x10GEXP_REG_RXXG_EXACT_MATCH_ADDR_0_HIGH 0x204C
Expand Down
2 changes: 1 addition & 1 deletion trunk/drivers/net/forcedeth.c
Original file line number Diff line number Diff line change
Expand Up @@ -195,7 +195,7 @@ enum {
#define NVREG_IRQ_TX_FORCED 0x0100
#define NVREG_IRQ_RECOVER_ERROR 0x8000
#define NVREG_IRQMASK_THROUGHPUT 0x00df
#define NVREG_IRQMASK_CPU 0x0040
#define NVREG_IRQMASK_CPU 0x0060
#define NVREG_IRQ_TX_ALL (NVREG_IRQ_TX_ERR|NVREG_IRQ_TX_OK|NVREG_IRQ_TX_FORCED)
#define NVREG_IRQ_RX_ALL (NVREG_IRQ_RX_ERROR|NVREG_IRQ_RX|NVREG_IRQ_RX_NOBUF|NVREG_IRQ_RX_FORCED)
#define NVREG_IRQ_OTHER (NVREG_IRQ_TIMER|NVREG_IRQ_LINK|NVREG_IRQ_RECOVER_ERROR)
Expand Down
Loading

0 comments on commit cbe8df5

Please sign in to comment.