aboutsummaryrefslogtreecommitdiffstats
path: root/Documentation/powerpc
diff options
context:
space:
mode:
Diffstat (limited to 'Documentation/powerpc')
-rw-r--r--Documentation/powerpc/eeh-pci-error-recovery.txt31
1 files changed, 16 insertions, 15 deletions
diff --git a/Documentation/powerpc/eeh-pci-error-recovery.txt b/Documentation/powerpc/eeh-pci-error-recovery.txt
index e75d7474322c..67a11a36270c 100644
--- a/Documentation/powerpc/eeh-pci-error-recovery.txt
+++ b/Documentation/powerpc/eeh-pci-error-recovery.txt
@@ -115,7 +115,7 @@ Current PPC64 Linux EEH Implementation
115At this time, a generic EEH recovery mechanism has been implemented, 115At this time, a generic EEH recovery mechanism has been implemented,
116so that individual device drivers do not need to be modified to support 116so that individual device drivers do not need to be modified to support
117EEH recovery. This generic mechanism piggy-backs on the PCI hotplug 117EEH recovery. This generic mechanism piggy-backs on the PCI hotplug
118infrastructure, and percolates events up through the hotplug/udev 118infrastructure, and percolates events up through the userspace/udev
119infrastructure. Followiing is a detailed description of how this is 119infrastructure. Followiing is a detailed description of how this is
120accomplished. 120accomplished.
121 121
@@ -172,7 +172,7 @@ A handler for the EEH notifier_block events is implemented in
172drivers/pci/hotplug/pSeries_pci.c, called handle_eeh_events(). 172drivers/pci/hotplug/pSeries_pci.c, called handle_eeh_events().
173It saves the device BAR's and then calls rpaphp_unconfig_pci_adapter(). 173It saves the device BAR's and then calls rpaphp_unconfig_pci_adapter().
174This last call causes the device driver for the card to be stopped, 174This last call causes the device driver for the card to be stopped,
175which causes hotplug events to go out to user space. This triggers 175which causes uevents to go out to user space. This triggers
176user-space scripts that might issue commands such as "ifdown eth0" 176user-space scripts that might issue commands such as "ifdown eth0"
177for ethernet cards, and so on. This handler then sleeps for 5 seconds, 177for ethernet cards, and so on. This handler then sleeps for 5 seconds,
178hoping to give the user-space scripts enough time to complete. 178hoping to give the user-space scripts enough time to complete.
@@ -258,29 +258,30 @@ rpa_php_unconfig_pci_adapter() { // in rpaphp_pci.c
258 calls 258 calls
259 pci_destroy_dev (struct pci_dev *) { 259 pci_destroy_dev (struct pci_dev *) {
260 calls 260 calls
261 device_unregister (&dev->dev) { // in /drivers/base/core.c 261 device_unregister (&dev->dev) { // in /drivers/base/core.c
262 calls 262 calls
263 device_del(struct device * dev) { // in /drivers/base/core.c 263 device_del(struct device * dev) { // in /drivers/base/core.c
264 calls 264 calls
265 kobject_del() { //in /libs/kobject.c 265 kobject_del() { //in /libs/kobject.c
266 calls 266 calls
267 kobject_hotplug() { // in /libs/kobject.c 267 kobject_uevent() { // in /libs/kobject.c
268 calls 268 calls
269 kset_hotplug() { // in /lib/kobject.c 269 kset_uevent() { // in /lib/kobject.c
270 calls 270 calls
271 kset->hotplug_ops->hotplug() which is really just 271 kset->uevent_ops->uevent() // which is really just
272 a call to 272 a call to
273 dev_hotplug() { // in /drivers/base/core.c 273 dev_uevent() { // in /drivers/base/core.c
274 calls 274 calls
275 dev->bus->hotplug() which is really just a call to 275 dev->bus->uevent() which is really just a call to
276 pci_hotplug () { // in drivers/pci/hotplug.c 276 pci_uevent () { // in drivers/pci/hotplug.c
277 which prints device name, etc.... 277 which prints device name, etc....
278 } 278 }
279 } 279 }
280 then kset_hotplug() calls 280 then kobject_uevent() sends a netlink uevent to userspace
281 call_usermodehelper () with 281 --> userspace uevent
282 argv[0]=hotplug_path[] which is "/sbin/hotplug" 282 (during early boot, nobody listens to netlink events and
283 --> event to userspace, 283 kobject_uevent() executes uevent_helper[], which runs the
284 event process /sbin/hotplug)
284 } 285 }
285 } 286 }
286 kobject_del() then calls sysfs_remove_dir(), which would 287 kobject_del() then calls sysfs_remove_dir(), which would