Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 56962
b: refs/heads/master
c: 824cf33
h: refs/heads/master
v: v3
  • Loading branch information
Alan Cox authored and Jeff Garzik committed May 25, 2007
1 parent 8ec02e9 commit 9898fe9
Show file tree
Hide file tree
Showing 23 changed files with 79 additions and 113 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: 9059b454248a060ab39346c5d079f56089ab3868
refs/heads/master: 824cf333db97954d6144230b5e28f4e65e67d312
5 changes: 2 additions & 3 deletions trunk/Documentation/filesystems/directory-locking
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
Locking scheme used for directory operations is based on two
kinds of locks - per-inode (->i_mutex) and per-filesystem
(->s_vfs_rename_mutex).
kinds of locks - per-inode (->i_sem) and per-filesystem (->s_vfs_rename_sem).

For our purposes all operations fall in 5 classes:

Expand Down Expand Up @@ -64,7 +63,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_mutex.
Thus all processes are blocked on ->i_sem.

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_mutex on the object we are linking to. Some of your
->link() callers hold ->i_sem 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_mutex, so
watch for ->i_mutex-grabbing code that might be used by your ->setattr().
Callers of notify_change() need ->i_mutex now.
->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.

---
[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: 1 addition & 2 deletions trunk/arch/ia64/kernel/acpi.c
Original file line number Diff line number Diff line change
Expand Up @@ -67,8 +67,7 @@ EXPORT_SYMBOL(pm_power_off);
unsigned int acpi_cpei_override;
unsigned int acpi_cpei_phys_cpuid;

const char __init *
acpi_get_sysname(void)
const char *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 __cpuinit
static void __devinit
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 __cpuinit
int __devinit
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-platform.o ip32-setup.o ip32-reset.o \
obj-y += ip32-berr.o ip32-irq.o ip32-setup.o ip32-reset.o \
crime.o ip32-memory.o
20 changes: 0 additions & 20 deletions trunk/arch/mips/sgi-ip32/ip32-platform.c

This file was deleted.

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
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 PCI
depends on NET_PCI && 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 0x0060
#define NVREG_IRQMASK_CPU 0x0040
#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
68 changes: 23 additions & 45 deletions trunk/drivers/net/meth.c
Original file line number Diff line number Diff line change
Expand Up @@ -8,16 +8,15 @@
* as published by the Free Software Foundation; either version
* 2 of the License, or (at your option) any later version.
*/
#include <linux/delay.h>
#include <linux/dma-mapping.h>
#include <linux/init.h>
#include <linux/kernel.h>
#include <linux/module.h>
#include <linux/platform_device.h>
#include <linux/init.h>

#include <linux/kernel.h> /* printk() */
#include <linux/delay.h>
#include <linux/slab.h>
#include <linux/errno.h>
#include <linux/types.h>
#include <linux/interrupt.h>
#include <linux/errno.h> /* error codes */
#include <linux/types.h> /* size_t */
#include <linux/interrupt.h> /* mark_bh */

#include <linux/in.h>
#include <linux/in6.h>
Expand All @@ -34,6 +33,7 @@

#include <asm/io.h>
#include <asm/scatterlist.h>
#include <linux/dma-mapping.h>

#include "meth.h"

Expand All @@ -51,6 +51,8 @@


static const char *meth_str="SGI O2 Fast Ethernet";
MODULE_AUTHOR("Ilya Volynets <ilya@theIlya.com>");
MODULE_DESCRIPTION("SGI O2 Builtin Fast Ethernet driver");

#define HAVE_TX_TIMEOUT
/* The maximum time waited (in jiffies) before assuming a Tx failed. (400ms) */
Expand Down Expand Up @@ -782,15 +784,15 @@ static struct net_device_stats *meth_stats(struct net_device *dev)
/*
* The init function.
*/
static int __init meth_probe(struct platform_device *pdev)
static struct net_device *meth_init(void)
{
struct net_device *dev;
struct meth_private *priv;
int err;
int ret;

dev = alloc_etherdev(sizeof(struct meth_private));
if (!dev)
return -ENOMEM;
return ERR_PTR(-ENOMEM);

dev->open = meth_open;
dev->stop = meth_release;
Expand All @@ -806,57 +808,33 @@ static int __init meth_probe(struct platform_device *pdev)

priv = netdev_priv(dev);
spin_lock_init(&priv->meth_lock);
SET_NETDEV_DEV(dev, &pdev->dev);

err = register_netdev(dev);
if (err) {
ret = register_netdev(dev);
if (ret) {
free_netdev(dev);
return err;
return ERR_PTR(ret);
}

printk(KERN_INFO "%s: SGI MACE Ethernet rev. %d\n",
dev->name, (unsigned int)(mace->eth.mac_ctrl >> 29));
return 0;
}

static int __exit meth_remove(struct platform_device *pdev)
{
struct net_device *dev = platform_get_drvdata(pdev);

unregister_netdev(dev);
free_netdev(dev);
platform_set_drvdata(pdev, NULL);

return 0;
}

static struct platform_driver meth_driver = {
.probe = meth_probe,
.remove = __devexit_p(meth_remove),
.driver = {
.name = "meth",
}
};
static struct net_device *meth_dev;

static int __init meth_init_module(void)
{
int err;

err = platform_driver_register(&meth_driver);
if (err)
printk(KERN_ERR "Driver registration failed\n");

return err;
meth_dev = meth_init();
if (IS_ERR(meth_dev))
return PTR_ERR(meth_dev);
return 0;
}

static void __exit meth_exit_module(void)
{
platform_driver_unregister(&meth_driver);
unregister_netdev(meth_dev);
free_netdev(meth_dev);
}

module_init(meth_init_module);
module_exit(meth_exit_module);

MODULE_AUTHOR("Ilya Volynets <ilya@theIlya.com>");
MODULE_DESCRIPTION("SGI O2 Builtin Fast Ethernet driver");
MODULE_LICENSE("GPL");
4 changes: 0 additions & 4 deletions trunk/drivers/net/phy/fixed.c
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,6 @@ EXPORT_SYMBOL(fixed_mdio_set_link_update);
/*-----------------------------------------------------------------------------
* This is used for updating internal mii regs from the status
*-----------------------------------------------------------------------------*/
#if defined(CONFIG_FIXED_MII_100_FDX) || defined(CONFIG_FIXED_MII_10_FDX)
static int fixed_mdio_update_regs(struct fixed_info *fixed)
{
u16 *regs = fixed->regs;
Expand Down Expand Up @@ -166,7 +165,6 @@ static int fixed_mii_reset(struct mii_bus *bus)
/*nothing here - no way/need to reset it*/
return 0;
}
#endif

static int fixed_config_aneg(struct phy_device *phydev)
{
Expand Down Expand Up @@ -196,7 +194,6 @@ static struct phy_driver fixed_mdio_driver = {
* number is used to create multiple fixed PHYs, so that several devices can
* utilize them simultaneously.
*-----------------------------------------------------------------------------*/
#if defined(CONFIG_FIXED_MII_100_FDX) || defined(CONFIG_FIXED_MII_10_FDX)
static int fixed_mdio_register_device(int number, int speed, int duplex)
{
struct mii_bus *new_bus;
Expand Down Expand Up @@ -304,7 +301,6 @@ static int fixed_mdio_register_device(int number, int speed, int duplex)

return err;
}
#endif


MODULE_DESCRIPTION("Fixed PHY device & driver for PAL");
Expand Down
6 changes: 3 additions & 3 deletions trunk/drivers/net/spider_net.c
Original file line number Diff line number Diff line change
Expand Up @@ -1014,12 +1014,12 @@ spider_net_pass_skb_up(struct spider_net_descr *descr,
*/
}

/* pass skb up to stack */
netif_receive_skb(skb);

/* update netdevice statistics */
card->netdev_stats.rx_packets++;
card->netdev_stats.rx_bytes += skb->len;

/* pass skb up to stack */
netif_receive_skb(skb);
}

#ifdef DEBUG
Expand Down
3 changes: 3 additions & 0 deletions trunk/drivers/net/ucc_geth.c
Original file line number Diff line number Diff line change
Expand Up @@ -23,8 +23,11 @@
#include <linux/skbuff.h>
#include <linux/spinlock.h>
#include <linux/mm.h>
#include <linux/ethtool.h>
#include <linux/delay.h>
#include <linux/dma-mapping.h>
#include <linux/fsl_devices.h>
#include <linux/ethtool.h>
#include <linux/mii.h>
#include <linux/phy.h>
#include <linux/workqueue.h>
Expand Down
2 changes: 2 additions & 0 deletions trunk/drivers/net/ucc_geth_mii.c
Original file line number Diff line number Diff line change
Expand Up @@ -260,6 +260,8 @@ static struct of_device_id uec_mdio_match[] = {
{},
};

MODULE_DEVICE_TABLE(of, uec_mdio_match);

static struct of_platform_driver uec_mdio_driver = {
.name = DRV_NAME,
.probe = uec_mdio_probe,
Expand Down
4 changes: 0 additions & 4 deletions trunk/drivers/net/usb/asix.c
Original file line number Diff line number Diff line change
Expand Up @@ -1458,10 +1458,6 @@ static const struct usb_device_id products [] = {
// IO-DATA ETG-US2
USB_DEVICE (0x04bb, 0x0930),
.driver_info = (unsigned long) &ax88178_info,
}, {
// Belkin F5D5055
USB_DEVICE(0x050d, 0x5055),
.driver_info = (unsigned long) &ax88178_info,
},
{ }, // END
};
Expand Down
2 changes: 1 addition & 1 deletion trunk/drivers/net/wireless/libertas/decl.h
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ u32 libertas_index_to_data_rate(u8 index);
u8 libertas_data_rate_to_index(u32 rate);
void libertas_get_fwversion(wlan_adapter * adapter, char *fwversion, int maxlen);

void libertas_upload_rx_packet(wlan_private * priv, struct sk_buff *skb);
int libertas_upload_rx_packet(wlan_private * priv, struct sk_buff *skb);

/** The proc fs interface */
int libertas_process_rx_command(wlan_private * priv);
Expand Down
14 changes: 5 additions & 9 deletions trunk/drivers/net/wireless/libertas/fw.c
Original file line number Diff line number Diff line change
Expand Up @@ -333,22 +333,18 @@ static void command_timer_fn(unsigned long data)
unsigned long flags;

ptempnode = adapter->cur_cmd;
if (ptempnode == NULL) {
lbs_pr_debug(1, "PTempnode Empty\n");
return;
}

cmd = (struct cmd_ds_command *)ptempnode->bufvirtualaddr;
if (!cmd) {
lbs_pr_debug(1, "cmd is NULL\n");
return;
}

lbs_pr_info("command_timer_fn fired (%x)\n", cmd->command);

if (!adapter->fw_ready)
return;

if (ptempnode == NULL) {
lbs_pr_debug(1, "PTempnode Empty\n");
return;
}

spin_lock_irqsave(&adapter->driver_lock, flags);
adapter->cur_cmd = NULL;
spin_unlock_irqrestore(&adapter->driver_lock, flags);
Expand Down
Loading

0 comments on commit 9898fe9

Please sign in to comment.