diff options
author | Ursula Braun <ursula.braun@de.ibm.com> | 2010-07-22 23:15:05 +0000 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2010-07-23 12:36:23 -0700 |
commit | 9dc48ccc68b9dfc01c2beee2d4317fb3df3fdce9 (patch) | |
tree | 83d101e637385276ca40af1bb70ecc14ab24e33f /drivers/s390/net/qeth_core_sys.c | |
parent | 75e0de13631e115768a97131a2d7f5259217512d (diff) | |
download | lwn-9dc48ccc68b9dfc01c2beee2d4317fb3df3fdce9.tar.gz lwn-9dc48ccc68b9dfc01c2beee2d4317fb3df3fdce9.zip |
qeth: serialize sysfs-triggered device configurations
This patch serializes device removal and other sysfs-triggered
configurations by moving removal of sysfs-attributes to the beginning
of the remove functions. And it serializes online/offline setting
and discipline-switching (causing reestablishing of the net_device)
by making use of a new discipline mutex.
Signed-off-by: Ursula Braun <ursula.braun@de.ibm.com>
Signed-off-by: Frank Blaschka <frank.blaschka@de.ibm.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/s390/net/qeth_core_sys.c')
-rw-r--r-- | drivers/s390/net/qeth_core_sys.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/s390/net/qeth_core_sys.c b/drivers/s390/net/qeth_core_sys.c index 6b7fd88e8e4d..42fa783a70c8 100644 --- a/drivers/s390/net/qeth_core_sys.c +++ b/drivers/s390/net/qeth_core_sys.c @@ -411,7 +411,7 @@ static ssize_t qeth_dev_layer2_store(struct device *dev, if (!card) return -EINVAL; - mutex_lock(&card->conf_mutex); + mutex_lock(&card->discipline_mutex); if (card->state != CARD_STATE_DOWN) { rc = -EPERM; goto out; @@ -446,7 +446,7 @@ static ssize_t qeth_dev_layer2_store(struct device *dev, rc = card->discipline.ccwgdriver->probe(card->gdev); out: - mutex_unlock(&card->conf_mutex); + mutex_unlock(&card->discipline_mutex); return rc ? rc : count; } |