diff options
author | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2014-01-13 22:55:05 +0100 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2014-01-13 22:55:05 +0100 |
commit | ff483d55ba6fb50a8d6f99e808da35218533b1ef (patch) | |
tree | 4e5f33a15074af298e1c5aff6c5491e374a1717f /arch | |
parent | Revert "sysfs, driver-core: remove unused {sysfs|device}_schedule_callback_ow... (diff) | |
download | linux-ff483d55ba6fb50a8d6f99e808da35218533b1ef.tar.xz linux-ff483d55ba6fb50a8d6f99e808da35218533b1ef.zip |
Revert "s390: use device_remove_file_self() instead of device_schedule_callback()"
This reverts commit bdbb0a1376635d80e096f6433595a38984cf5408.
Tejun writes:
I'm sorry but can you please revert the whole series?
get_active() waiting while a node is deactivated has potential
to lead to deadlock and that deactivate/reactivate interface is
something fundamentally flawed and that cgroup will have to work
with the remove_self() like everybody else. IOW, I think the
first posting was correct.
Cc: Tejun Heo <tj@kernel.org>
Cc: Martin Schwidefsky <schwidefsky@de.ibm.com>
Cc: Heiko Carstens <heiko.carstens@de.ibm.com>
Cc: linux390@de.ibm.com
Cc: linux-s390@vger.kernel.org
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'arch')
-rw-r--r-- | arch/s390/include/asm/ccwgroup.h | 1 | ||||
-rw-r--r-- | arch/s390/pci/pci_sysfs.c | 18 |
2 files changed, 10 insertions, 9 deletions
diff --git a/arch/s390/include/asm/ccwgroup.h b/arch/s390/include/asm/ccwgroup.h index 6e670f88d125..23723ce5ca7a 100644 --- a/arch/s390/include/asm/ccwgroup.h +++ b/arch/s390/include/asm/ccwgroup.h @@ -23,7 +23,6 @@ struct ccwgroup_device { unsigned int count; struct device dev; struct ccw_device *cdev[0]; - struct work_struct ungroup_work; }; /** diff --git a/arch/s390/pci/pci_sysfs.c b/arch/s390/pci/pci_sysfs.c index ab4a91393005..cf8a12ff733b 100644 --- a/arch/s390/pci/pci_sysfs.c +++ b/arch/s390/pci/pci_sysfs.c @@ -48,27 +48,29 @@ static ssize_t show_pfgid(struct device *dev, struct device_attribute *attr, } static DEVICE_ATTR(pfgid, S_IRUGO, show_pfgid, NULL); -static ssize_t store_recover(struct device *dev, struct device_attribute *attr, - const char *buf, size_t count) +static void recover_callback(struct device *dev) { struct pci_dev *pdev = to_pci_dev(dev); struct zpci_dev *zdev = get_zdev(pdev); int ret; - if (!device_remove_file_self(dev, attr)) - return count; - pci_stop_and_remove_bus_device(pdev); ret = zpci_disable_device(zdev); if (ret) - return ret; + return; ret = zpci_enable_device(zdev); if (ret) - return ret; + return; pci_rescan_bus(zdev->bus); - return count; +} + +static ssize_t store_recover(struct device *dev, struct device_attribute *attr, + const char *buf, size_t count) +{ + int rc = device_schedule_callback(dev, recover_callback); + return rc ? rc : count; } static DEVICE_ATTR(recover, S_IWUSR, NULL, store_recover); |