Commit 14188442 authored by Matthieu Castet's avatar Matthieu Castet Committed by Greg Kroah-Hartman

[PATCH] use of MODULE_DEVICE_TABLE in i2c busses driver

hello,
since you say your are interested of using MODULE_DEVICE_TABLE in
http://bugzilla.kernel.org/show_bug.cgi?id=3091 I did a patch (attach).

Also I notice that some pci_device_id are marked __devinitdata that seem a bug
if I read Linux 2.6.0-test3 changelog.
To find them do a "grep pci_device_id  /usr/src/linux/drivers/i2c/busses/* |
grep __devinitdata"
Signed-off-by: default avatarGreg Kroah-Hartman <greg@kroah.com>
parent f1d1dffe
......@@ -496,6 +496,8 @@ static struct pci_device_id ali1535_ids[] = {
{ },
};
MODULE_DEVICE_TABLE (pci, ali1535_ids);
static int __devinit ali1535_probe(struct pci_dev *dev, const struct pci_device_id *id)
{
if (ali1535_setup(dev)) {
......
......@@ -394,6 +394,8 @@ static struct pci_device_id __devinitdata ali1563_id_table[] = {
{},
};
MODULE_DEVICE_TABLE (pci, ali1563_id_table);
static struct pci_driver ali1563_pci_driver = {
.name = "ali1563_i2c",
.id_table = ali1563_id_table,
......
......@@ -486,6 +486,8 @@ static struct pci_device_id ali15x3_ids[] = {
{ 0, }
};
MODULE_DEVICE_TABLE (pci, ali15x3_ids);
static int __devinit ali15x3_probe(struct pci_dev *dev, const struct pci_device_id *id)
{
if (ali15x3_setup(dev)) {
......
......@@ -320,6 +320,8 @@ static struct pci_device_id amd756_ids[] = {
{ 0, }
};
MODULE_DEVICE_TABLE (pci, amd756_ids);
static int __devinit amd756_probe(struct pci_dev *pdev,
const struct pci_device_id *id)
{
......
......@@ -336,6 +336,8 @@ static struct pci_device_id amd8111_ids[] = {
{ 0, }
};
MODULE_DEVICE_TABLE (pci, amd8111_ids);
static int __devinit amd8111_probe(struct pci_dev *dev, const struct pci_device_id *id)
{
struct amd_smbus *smbus;
......
......@@ -120,6 +120,8 @@ static struct pci_device_id hydra_ids[] = {
{ 0, }
};
MODULE_DEVICE_TABLE (pci, hydra_ids);
static int __devinit hydra_probe(struct pci_dev *dev,
const struct pci_device_id *id)
{
......
......@@ -599,6 +599,8 @@ static struct pci_device_id i801_ids[] = {
{ 0, }
};
MODULE_DEVICE_TABLE (pci, i801_ids);
static int __devinit i801_probe(struct pci_dev *dev, const struct pci_device_id *id)
{
......
......@@ -201,6 +201,8 @@ static struct pci_device_id i810_ids[] __devinitdata = {
{ 0, },
};
MODULE_DEVICE_TABLE (pci, i810_ids);
static int __devinit i810_probe(struct pci_dev *dev, const struct pci_device_id *id)
{
int retval;
......
......@@ -298,6 +298,9 @@ static struct pci_device_id nforce2_ids[] = {
};
MODULE_DEVICE_TABLE (pci, nforce2_ids);
static int __devinit nforce2_probe_smb (struct pci_dev *dev, int reg,
struct nforce2_smbus *smbus, char *name)
{
......
......@@ -459,6 +459,8 @@ static struct pci_device_id piix4_ids[] = {
{ 0, }
};
MODULE_DEVICE_TABLE (pci, piix4_ids);
static int __devinit piix4_probe(struct pci_dev *dev,
const struct pci_device_id *id)
{
......
......@@ -313,6 +313,8 @@ static struct pci_device_id prosavage_pci_tbl[] = {
{ 0, },
};
MODULE_DEVICE_TABLE (pci, prosavage_pci_tbl);
static struct pci_driver prosavage_driver = {
.name = "prosavage_smbus",
.id_table = prosavage_pci_tbl,
......
......@@ -157,6 +157,8 @@ static struct pci_device_id savage4_ids[] __devinitdata = {
{ 0, }
};
MODULE_DEVICE_TABLE (pci, savage4_ids);
static int __devinit savage4_probe(struct pci_dev *dev, const struct pci_device_id *id)
{
int retval;
......
......@@ -371,6 +371,8 @@ static struct pci_device_id sis5595_ids[] __devinitdata = {
{ 0, }
};
MODULE_DEVICE_TABLE (pci, sis5595_ids);
static int __devinit sis5595_probe(struct pci_dev *dev, const struct pci_device_id *id)
{
if (sis5595_setup(dev)) {
......
......@@ -468,6 +468,8 @@ static struct pci_device_id sis630_ids[] __devinitdata = {
{ 0, }
};
MODULE_DEVICE_TABLE (pci, sis630_ids);
static int __devinit sis630_probe(struct pci_dev *dev, const struct pci_device_id *id)
{
if (sis630_setup(dev)) {
......
......@@ -278,6 +278,8 @@ static struct pci_device_id sis96x_ids[] = {
{ 0, }
};
MODULE_DEVICE_TABLE (pci, sis96x_ids);
static int __devinit sis96x_probe(struct pci_dev *dev,
const struct pci_device_id *id)
{
......
......@@ -99,6 +99,8 @@ static struct pci_device_id vt586b_ids[] __devinitdata = {
{ 0, }
};
MODULE_DEVICE_TABLE (pci, vt586b_ids);
static int __devinit vt586b_probe(struct pci_dev *dev, const struct pci_device_id *id)
{
u16 base;
......
......@@ -454,6 +454,8 @@ static struct pci_device_id vt596_ids[] = {
{ 0, }
};
MODULE_DEVICE_TABLE (pci, vt596_ids);
static struct pci_driver vt596_driver = {
.name = "vt596_smbus",
.id_table = vt596_ids,
......
......@@ -195,6 +195,8 @@ static struct pci_device_id voodoo3_ids[] __devinitdata = {
{ 0, }
};
MODULE_DEVICE_TABLE (pci, voodoo3_ids);
static int __devinit voodoo3_probe(struct pci_dev *dev, const struct pci_device_id *id)
{
int retval;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment