Skip to content

Commit

Permalink
[IA64-SGI] Hotplug driver related fix in the SN ia64 code.
Browse files Browse the repository at this point in the history
Remove an erroneous kfree, and unlink the pcidev_info struct from the
pcidev_info list prior to free'ing the pcidev_info struct.

Signed-off-by: Prarit Bhargava <prarit@sgi.com>
Signed-off-by: Tony Luck <tony.luck@intel.com>
  • Loading branch information
Prarit Bhargava authored and Tony Luck committed Feb 9, 2006
1 parent 0bdd340 commit 8b34ff4
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
2 changes: 2 additions & 0 deletions arch/ia64/sn/kernel/io_init.c
Original file line number Diff line number Diff line change
Expand Up @@ -623,6 +623,8 @@ void sn_bus_free_sysdata(void)
list_for_each(list, &sn_sysdata_list) {
element = list_entry(list, struct sysdata_el, entry);
list_del(&element->entry);
list_del(&(((struct pcidev_info *)
(element->sysdata))->pdi_list));
kfree(element->sysdata);
kfree(element);
goto sn_sysdata_free_start;
Expand Down
4 changes: 3 additions & 1 deletion arch/ia64/sn/kernel/irq.c
Original file line number Diff line number Diff line change
Expand Up @@ -299,7 +299,9 @@ void sn_irq_unfixup(struct pci_dev *pci_dev)
return;

sn_irq_info = SN_PCIDEV_INFO(pci_dev)->pdi_sn_irq_info;
if (!sn_irq_info || !sn_irq_info->irq_irq) {
if (!sn_irq_info)
return;
if (!sn_irq_info->irq_irq) {
kfree(sn_irq_info);
return;
}
Expand Down

0 comments on commit 8b34ff4

Please sign in to comment.