aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/pci/hotplug/pciehp.h
diff options
context:
space:
mode:
authorKenji Kaneshige <kaneshige.kenji@jp.fujitsu.com>2007-05-31 12:43:34 -0400
committerGreg Kroah-Hartman <gregkh@suse.de>2007-07-11 19:02:08 -0400
commitf477836457730a2b925f625023ec4e5bf11015be (patch)
tree178c8e7efd7a3f8f0220d3da537d649f4cb1278f /drivers/pci/hotplug/pciehp.h
parentadf809d01043d8808e47db2d35fc07b53062884e (diff)
PCI: hotplug: pciehp: Fix possible race condition in writing slot
The slot control register is modified as follows: (1) Read the register value (2) Change the value (3) Write the value to the register Those must be done atomically, otherwise writing to control register would cause an unexpected result. Signed-off-by: Kenji Kaneshige <kaneshige.kenji@jp.fujitsu.com> Signed-off-by: Kristen Carlson Accardi <kristen.c.accardi@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'drivers/pci/hotplug/pciehp.h')
-rw-r--r--drivers/pci/hotplug/pciehp.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/pci/hotplug/pciehp.h b/drivers/pci/hotplug/pciehp.h
index ccc57627201e..7959c222dc24 100644
--- a/drivers/pci/hotplug/pciehp.h
+++ b/drivers/pci/hotplug/pciehp.h
@@ -103,6 +103,7 @@ struct controller {
103 u8 cap_base; 103 u8 cap_base;
104 struct timer_list poll_timer; 104 struct timer_list poll_timer;
105 volatile int cmd_busy; 105 volatile int cmd_busy;
106 spinlock_t lock;
106}; 107};
107 108
108#define INT_BUTTON_IGNORE 0 109#define INT_BUTTON_IGNORE 0