Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 53349
b: refs/heads/master
c: 6589121
h: refs/heads/master
i:
  53347: c70de8c
v: v3
  • Loading branch information
Michael Ellerman authored and Greg Kroah-Hartman committed May 3, 2007
1 parent 9fe725f commit d3b6a95
Show file tree
Hide file tree
Showing 3 changed files with 18 additions and 1 deletion.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: c9953a73e92df11edd812d863ff741877ea9e58c
refs/heads/master: 65891215e6b822c368fb3f36abf129ed48af8be0
15 changes: 15 additions & 0 deletions trunk/drivers/pci/probe.c
Original file line number Diff line number Diff line change
Expand Up @@ -846,6 +846,21 @@ static void pci_release_bus_bridge_dev(struct device *dev)
kfree(dev);
}

struct pci_dev *alloc_pci_dev(void)
{
struct pci_dev *dev;

dev = kzalloc(sizeof(struct pci_dev), GFP_KERNEL);
if (!dev)
return NULL;

INIT_LIST_HEAD(&dev->global_list);
INIT_LIST_HEAD(&dev->bus_list);

return dev;
}
EXPORT_SYMBOL(alloc_pci_dev);

/*
* Read the config data for a PCI device, sanity-check it
* and fill in the dev structure...
Expand Down
2 changes: 2 additions & 0 deletions trunk/include/linux/pci.h
Original file line number Diff line number Diff line change
Expand Up @@ -193,6 +193,8 @@ struct pci_dev {
#endif
};

extern struct pci_dev *alloc_pci_dev(void);

#define pci_dev_g(n) list_entry(n, struct pci_dev, global_list)
#define pci_dev_b(n) list_entry(n, struct pci_dev, bus_list)
#define to_pci_dev(n) container_of(n, struct pci_dev, dev)
Expand Down

0 comments on commit d3b6a95

Please sign in to comment.