diff options
author | Kenji Kaneshige <kaneshige.kenji@jp.fujitsu.com> | 2007-01-09 16:03:10 -0500 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@suse.de> | 2007-02-07 18:50:05 -0500 |
commit | 9f593e30b318719b0e3889c730cc3a2d0729a707 (patch) | |
tree | f3fae586a92afb2073dd0c00c7fffa7dd6024075 /drivers/pci/hotplug | |
parent | 1555b33da0b27f933fbe08679935ce9d83c0e9e9 (diff) |
shpchp: delete trailing whitespace
This patch deletes trailing white space in SHPCHP driver. This has no
functional change.
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')
-rw-r--r-- | drivers/pci/hotplug/shpchp.h | 4 | ||||
-rw-r--r-- | drivers/pci/hotplug/shpchp_ctrl.c | 20 | ||||
-rw-r--r-- | drivers/pci/hotplug/shpchp_hpc.c | 32 |
3 files changed, 28 insertions, 28 deletions
diff --git a/drivers/pci/hotplug/shpchp.h b/drivers/pci/hotplug/shpchp.h index 3ca6a4f574b3..01d31a1f697c 100644 --- a/drivers/pci/hotplug/shpchp.h +++ b/drivers/pci/hotplug/shpchp.h | |||
@@ -106,7 +106,7 @@ struct controller { | |||
106 | }; | 106 | }; |
107 | 107 | ||
108 | /* Define AMD SHPC ID */ | 108 | /* Define AMD SHPC ID */ |
109 | #define PCI_DEVICE_ID_AMD_GOLAM_7450 0x7450 | 109 | #define PCI_DEVICE_ID_AMD_GOLAM_7450 0x7450 |
110 | #define PCI_DEVICE_ID_AMD_POGO_7458 0x7458 | 110 | #define PCI_DEVICE_ID_AMD_POGO_7458 0x7458 |
111 | 111 | ||
112 | /* AMD PCIX bridge registers */ | 112 | /* AMD PCIX bridge registers */ |
@@ -221,7 +221,7 @@ enum ctrl_offsets { | |||
221 | }; | 221 | }; |
222 | 222 | ||
223 | static inline struct slot *get_slot(struct hotplug_slot *hotplug_slot) | 223 | static inline struct slot *get_slot(struct hotplug_slot *hotplug_slot) |
224 | { | 224 | { |
225 | return hotplug_slot->private; | 225 | return hotplug_slot->private; |
226 | } | 226 | } |
227 | 227 | ||
diff --git a/drivers/pci/hotplug/shpchp_ctrl.c b/drivers/pci/hotplug/shpchp_ctrl.c index 6bb84734cd6c..b746bd265bc6 100644 --- a/drivers/pci/hotplug/shpchp_ctrl.c +++ b/drivers/pci/hotplug/shpchp_ctrl.c | |||
@@ -64,7 +64,7 @@ u8 shpchp_handle_attention_button(u8 hp_slot, struct controller *ctrl) | |||
64 | 64 | ||
65 | /* Attention Button Change */ | 65 | /* Attention Button Change */ |
66 | dbg("shpchp: Attention button interrupt received.\n"); | 66 | dbg("shpchp: Attention button interrupt received.\n"); |
67 | 67 | ||
68 | p_slot = shpchp_find_slot(ctrl, hp_slot + ctrl->slot_device_offset); | 68 | p_slot = shpchp_find_slot(ctrl, hp_slot + ctrl->slot_device_offset); |
69 | p_slot->hpc_ops->get_adapter_status(p_slot, &(p_slot->presence_save)); | 69 | p_slot->hpc_ops->get_adapter_status(p_slot, &(p_slot->presence_save)); |
70 | 70 | ||
@@ -128,7 +128,7 @@ u8 shpchp_handle_presence_change(u8 hp_slot, struct controller *ctrl) | |||
128 | 128 | ||
129 | p_slot = shpchp_find_slot(ctrl, hp_slot + ctrl->slot_device_offset); | 129 | p_slot = shpchp_find_slot(ctrl, hp_slot + ctrl->slot_device_offset); |
130 | 130 | ||
131 | /* | 131 | /* |
132 | * Save the presence state | 132 | * Save the presence state |
133 | */ | 133 | */ |
134 | p_slot->hpc_ops->get_adapter_status(p_slot, &(p_slot->presence_save)); | 134 | p_slot->hpc_ops->get_adapter_status(p_slot, &(p_slot->presence_save)); |
@@ -184,12 +184,12 @@ u8 shpchp_handle_power_fault(u8 hp_slot, struct controller *ctrl) | |||
184 | return 1; | 184 | return 1; |
185 | } | 185 | } |
186 | 186 | ||
187 | /* The following routines constitute the bulk of the | 187 | /* The following routines constitute the bulk of the |
188 | hotplug controller logic | 188 | hotplug controller logic |
189 | */ | 189 | */ |
190 | static int change_bus_speed(struct controller *ctrl, struct slot *p_slot, | 190 | static int change_bus_speed(struct controller *ctrl, struct slot *p_slot, |
191 | enum pci_bus_speed speed) | 191 | enum pci_bus_speed speed) |
192 | { | 192 | { |
193 | int rc = 0; | 193 | int rc = 0; |
194 | 194 | ||
195 | dbg("%s: change to speed %d\n", __FUNCTION__, speed); | 195 | dbg("%s: change to speed %d\n", __FUNCTION__, speed); |
@@ -204,7 +204,7 @@ static int change_bus_speed(struct controller *ctrl, struct slot *p_slot, | |||
204 | static int fix_bus_speed(struct controller *ctrl, struct slot *pslot, | 204 | static int fix_bus_speed(struct controller *ctrl, struct slot *pslot, |
205 | u8 flag, enum pci_bus_speed asp, enum pci_bus_speed bsp, | 205 | u8 flag, enum pci_bus_speed asp, enum pci_bus_speed bsp, |
206 | enum pci_bus_speed msp) | 206 | enum pci_bus_speed msp) |
207 | { | 207 | { |
208 | int rc = 0; | 208 | int rc = 0; |
209 | 209 | ||
210 | /* | 210 | /* |
@@ -257,23 +257,23 @@ static int board_added(struct slot *p_slot) | |||
257 | err("%s: Failed to power on slot\n", __FUNCTION__); | 257 | err("%s: Failed to power on slot\n", __FUNCTION__); |
258 | return -1; | 258 | return -1; |
259 | } | 259 | } |
260 | 260 | ||
261 | if ((ctrl->pci_dev->vendor == 0x8086) && (ctrl->pci_dev->device == 0x0332)) { | 261 | if ((ctrl->pci_dev->vendor == 0x8086) && (ctrl->pci_dev->device == 0x0332)) { |
262 | if (slots_not_empty) | 262 | if (slots_not_empty) |
263 | return WRONG_BUS_FREQUENCY; | 263 | return WRONG_BUS_FREQUENCY; |
264 | 264 | ||
265 | if ((rc = p_slot->hpc_ops->set_bus_speed_mode(p_slot, PCI_SPEED_33MHz))) { | 265 | if ((rc = p_slot->hpc_ops->set_bus_speed_mode(p_slot, PCI_SPEED_33MHz))) { |
266 | err("%s: Issue of set bus speed mode command failed\n", __FUNCTION__); | 266 | err("%s: Issue of set bus speed mode command failed\n", __FUNCTION__); |
267 | return WRONG_BUS_FREQUENCY; | 267 | return WRONG_BUS_FREQUENCY; |
268 | } | 268 | } |
269 | 269 | ||
270 | /* turn on board, blink green LED, turn off Amber LED */ | 270 | /* turn on board, blink green LED, turn off Amber LED */ |
271 | if ((rc = p_slot->hpc_ops->slot_enable(p_slot))) { | 271 | if ((rc = p_slot->hpc_ops->slot_enable(p_slot))) { |
272 | err("%s: Issue of Slot Enable command failed\n", __FUNCTION__); | 272 | err("%s: Issue of Slot Enable command failed\n", __FUNCTION__); |
273 | return rc; | 273 | return rc; |
274 | } | 274 | } |
275 | } | 275 | } |
276 | 276 | ||
277 | rc = p_slot->hpc_ops->get_adapter_speed(p_slot, &asp); | 277 | rc = p_slot->hpc_ops->get_adapter_speed(p_slot, &asp); |
278 | if (rc) { | 278 | if (rc) { |
279 | err("%s: Can't get adapter speed or bus mode mismatch\n", | 279 | err("%s: Can't get adapter speed or bus mode mismatch\n", |
@@ -378,7 +378,7 @@ static int remove_board(struct slot *p_slot) | |||
378 | err("%s: Issue of Slot Disable command failed\n", __FUNCTION__); | 378 | err("%s: Issue of Slot Disable command failed\n", __FUNCTION__); |
379 | return rc; | 379 | return rc; |
380 | } | 380 | } |
381 | 381 | ||
382 | rc = p_slot->hpc_ops->set_attention_status(p_slot, 0); | 382 | rc = p_slot->hpc_ops->set_attention_status(p_slot, 0); |
383 | if (rc) { | 383 | if (rc) { |
384 | err("%s: Issue of Set Attention command failed\n", __FUNCTION__); | 384 | err("%s: Issue of Set Attention command failed\n", __FUNCTION__); |
diff --git a/drivers/pci/hotplug/shpchp_hpc.c b/drivers/pci/hotplug/shpchp_hpc.c index 7e9347eea5b1..5183a45d45b5 100644 --- a/drivers/pci/hotplug/shpchp_hpc.c +++ b/drivers/pci/hotplug/shpchp_hpc.c | |||
@@ -329,9 +329,9 @@ static int shpc_write_cmd(struct slot *slot, u8 t_slot, u8 cmd) | |||
329 | ++t_slot; | 329 | ++t_slot; |
330 | temp_word = (t_slot << 8) | (cmd & 0xFF); | 330 | temp_word = (t_slot << 8) | (cmd & 0xFF); |
331 | dbg("%s: t_slot %x cmd %x\n", __FUNCTION__, t_slot, cmd); | 331 | dbg("%s: t_slot %x cmd %x\n", __FUNCTION__, t_slot, cmd); |
332 | 332 | ||
333 | /* To make sure the Controller Busy bit is 0 before we send out the | 333 | /* To make sure the Controller Busy bit is 0 before we send out the |
334 | * command. | 334 | * command. |
335 | */ | 335 | */ |
336 | shpc_writew(ctrl, CMD, temp_word); | 336 | shpc_writew(ctrl, CMD, temp_word); |
337 | 337 | ||
@@ -357,7 +357,7 @@ static int hpc_check_cmd_status(struct controller *ctrl) | |||
357 | { | 357 | { |
358 | int retval = 0; | 358 | int retval = 0; |
359 | u16 cmd_status = shpc_readw(ctrl, CMD_STATUS) & 0x000F; | 359 | u16 cmd_status = shpc_readw(ctrl, CMD_STATUS) & 0x000F; |
360 | 360 | ||
361 | switch (cmd_status >> 1) { | 361 | switch (cmd_status >> 1) { |
362 | case 0: | 362 | case 0: |
363 | retval = 0; | 363 | retval = 0; |
@@ -544,7 +544,7 @@ static int hpc_set_attention_status(struct slot *slot, u8 value) | |||
544 | u8 slot_cmd = 0; | 544 | u8 slot_cmd = 0; |
545 | 545 | ||
546 | switch (value) { | 546 | switch (value) { |
547 | case 0 : | 547 | case 0 : |
548 | slot_cmd = SET_ATTN_OFF; /* OFF */ | 548 | slot_cmd = SET_ATTN_OFF; /* OFF */ |
549 | break; | 549 | break; |
550 | case 1: | 550 | case 1: |
@@ -735,7 +735,7 @@ static irqreturn_t shpc_isr(int irq, void *dev_id) | |||
735 | if (!intr_loc) | 735 | if (!intr_loc) |
736 | return IRQ_NONE; | 736 | return IRQ_NONE; |
737 | 737 | ||
738 | dbg("%s: intr_loc = %x\n",__FUNCTION__, intr_loc); | 738 | dbg("%s: intr_loc = %x\n",__FUNCTION__, intr_loc); |
739 | 739 | ||
740 | if(!shpchp_poll_mode) { | 740 | if(!shpchp_poll_mode) { |
741 | /* | 741 | /* |
@@ -748,12 +748,12 @@ static irqreturn_t shpc_isr(int irq, void *dev_id) | |||
748 | shpc_writel(ctrl, SERR_INTR_ENABLE, serr_int); | 748 | shpc_writel(ctrl, SERR_INTR_ENABLE, serr_int); |
749 | 749 | ||
750 | intr_loc2 = shpc_readl(ctrl, INTR_LOC); | 750 | intr_loc2 = shpc_readl(ctrl, INTR_LOC); |
751 | dbg("%s: intr_loc2 = %x\n",__FUNCTION__, intr_loc2); | 751 | dbg("%s: intr_loc2 = %x\n",__FUNCTION__, intr_loc2); |
752 | } | 752 | } |
753 | 753 | ||
754 | if (intr_loc & CMD_INTR_PENDING) { | 754 | if (intr_loc & CMD_INTR_PENDING) { |
755 | /* | 755 | /* |
756 | * Command Complete Interrupt Pending | 756 | * Command Complete Interrupt Pending |
757 | * RO only - clear by writing 1 to the Command Completion | 757 | * RO only - clear by writing 1 to the Command Completion |
758 | * Detect bit in Controller SERR-INT register | 758 | * Detect bit in Controller SERR-INT register |
759 | */ | 759 | */ |
@@ -767,7 +767,7 @@ static irqreturn_t shpc_isr(int irq, void *dev_id) | |||
767 | if (!(intr_loc & ~CMD_INTR_PENDING)) | 767 | if (!(intr_loc & ~CMD_INTR_PENDING)) |
768 | goto out; | 768 | goto out; |
769 | 769 | ||
770 | for (hp_slot = 0; hp_slot < ctrl->num_slots; hp_slot++) { | 770 | for (hp_slot = 0; hp_slot < ctrl->num_slots; hp_slot++) { |
771 | /* To find out which slot has interrupt pending */ | 771 | /* To find out which slot has interrupt pending */ |
772 | if (!(intr_loc & SLOT_INTR_PENDING(hp_slot))) | 772 | if (!(intr_loc & SLOT_INTR_PENDING(hp_slot))) |
773 | continue; | 773 | continue; |
@@ -799,7 +799,7 @@ static irqreturn_t shpc_isr(int irq, void *dev_id) | |||
799 | serr_int &= ~(GLOBAL_INTR_MASK | SERR_INTR_RSVDZ_MASK); | 799 | serr_int &= ~(GLOBAL_INTR_MASK | SERR_INTR_RSVDZ_MASK); |
800 | shpc_writel(ctrl, SERR_INTR_ENABLE, serr_int); | 800 | shpc_writel(ctrl, SERR_INTR_ENABLE, serr_int); |
801 | } | 801 | } |
802 | 802 | ||
803 | return IRQ_HANDLED; | 803 | return IRQ_HANDLED; |
804 | } | 804 | } |
805 | 805 | ||
@@ -919,7 +919,7 @@ static struct hpc_ops shpchp_hpc_ops = { | |||
919 | .power_on_slot = hpc_power_on_slot, | 919 | .power_on_slot = hpc_power_on_slot, |
920 | .slot_enable = hpc_slot_enable, | 920 | .slot_enable = hpc_slot_enable, |
921 | .slot_disable = hpc_slot_disable, | 921 | .slot_disable = hpc_slot_disable, |
922 | .set_bus_speed_mode = hpc_set_bus_speed_mode, | 922 | .set_bus_speed_mode = hpc_set_bus_speed_mode, |
923 | .set_attention_status = hpc_set_attention_status, | 923 | .set_attention_status = hpc_set_attention_status, |
924 | .get_power_status = hpc_get_power_status, | 924 | .get_power_status = hpc_get_power_status, |
925 | .get_attention_status = hpc_get_attention_status, | 925 | .get_attention_status = hpc_get_attention_status, |
@@ -936,7 +936,7 @@ static struct hpc_ops shpchp_hpc_ops = { | |||
936 | .green_led_on = hpc_set_green_led_on, | 936 | .green_led_on = hpc_set_green_led_on, |
937 | .green_led_off = hpc_set_green_led_off, | 937 | .green_led_off = hpc_set_green_led_off, |
938 | .green_led_blink = hpc_set_green_led_blink, | 938 | .green_led_blink = hpc_set_green_led_blink, |
939 | 939 | ||
940 | .release_ctlr = hpc_release_ctlr, | 940 | .release_ctlr = hpc_release_ctlr, |
941 | }; | 941 | }; |
942 | 942 | ||
@@ -993,9 +993,9 @@ int shpc_init(struct controller *ctrl, struct pci_dev *pdev) | |||
993 | ctrl->mmio_size = 0x24 + 0x4 * num_slots; | 993 | ctrl->mmio_size = 0x24 + 0x4 * num_slots; |
994 | } | 994 | } |
995 | 995 | ||
996 | info("HPC vendor_id %x device_id %x ss_vid %x ss_did %x\n", pdev->vendor, pdev->device, pdev->subsystem_vendor, | 996 | info("HPC vendor_id %x device_id %x ss_vid %x ss_did %x\n", pdev->vendor, pdev->device, pdev->subsystem_vendor, |
997 | pdev->subsystem_device); | 997 | pdev->subsystem_device); |
998 | 998 | ||
999 | rc = pci_enable_device(pdev); | 999 | rc = pci_enable_device(pdev); |
1000 | if (rc) { | 1000 | if (rc) { |
1001 | err("%s: pci_enable_device failed\n", __FUNCTION__); | 1001 | err("%s: pci_enable_device failed\n", __FUNCTION__); |
@@ -1057,7 +1057,7 @@ int shpc_init(struct controller *ctrl, struct pci_dev *pdev) | |||
1057 | slot_reg &= ~SLOT_REG_RSVDZ_MASK; | 1057 | slot_reg &= ~SLOT_REG_RSVDZ_MASK; |
1058 | shpc_writel(ctrl, SLOT_REG(hp_slot), slot_reg); | 1058 | shpc_writel(ctrl, SLOT_REG(hp_slot), slot_reg); |
1059 | } | 1059 | } |
1060 | 1060 | ||
1061 | if (shpchp_poll_mode) { | 1061 | if (shpchp_poll_mode) { |
1062 | /* Install interrupt polling timer. Start with 10 sec delay */ | 1062 | /* Install interrupt polling timer. Start with 10 sec delay */ |
1063 | init_timer(&ctrl->poll_timer); | 1063 | init_timer(&ctrl->poll_timer); |
@@ -1069,7 +1069,7 @@ int shpc_init(struct controller *ctrl, struct pci_dev *pdev) | |||
1069 | info("Can't get msi for the hotplug controller\n"); | 1069 | info("Can't get msi for the hotplug controller\n"); |
1070 | info("Use INTx for the hotplug controller\n"); | 1070 | info("Use INTx for the hotplug controller\n"); |
1071 | } | 1071 | } |
1072 | 1072 | ||
1073 | rc = request_irq(ctrl->pci_dev->irq, shpc_isr, IRQF_SHARED, | 1073 | rc = request_irq(ctrl->pci_dev->irq, shpc_isr, IRQF_SHARED, |
1074 | MY_NAME, (void *)ctrl); | 1074 | MY_NAME, (void *)ctrl); |
1075 | dbg("%s: request_irq %d for hpc%d (returns %d)\n", | 1075 | dbg("%s: request_irq %d for hpc%d (returns %d)\n", |