aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGreg Kroah-Hartman <gregkh@suse.de>2009-05-04 15:40:54 -0400
committerGreg Kroah-Hartman <gregkh@suse.de>2009-06-16 00:30:27 -0400
commit9de33df41f712712ccd3297c898e365b50fb91ef (patch)
tree5e739060a56c6487fef57c29dac3c9245600bbfb
parentf899c2ddd45f2515deb446e2b143e4a686a49aee (diff)
ipmi: remove driver_data direct access of struct device
In the near future, the driver core is going to not allow direct access to the driver_data pointer in struct device. Instead, the functions dev_get_drvdata() and dev_set_drvdata() should be used. These functions have been around since the beginning, so are backwards compatible with all older kernel versions. Cc: openipmi-developer@lists.sourceforge.net Acked-by: Corey Minyard <minyard@acm.org> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
-rw-r--r--drivers/char/ipmi/ipmi_si_intf.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/char/ipmi/ipmi_si_intf.c b/drivers/char/ipmi/ipmi_si_intf.c
index 259644646b82..d2e698096ace 100644
--- a/drivers/char/ipmi/ipmi_si_intf.c
+++ b/drivers/char/ipmi/ipmi_si_intf.c
@@ -2375,14 +2375,14 @@ static int __devinit ipmi_of_probe(struct of_device *dev,
2375 info->io.addr_data, info->io.regsize, info->io.regspacing, 2375 info->io.addr_data, info->io.regsize, info->io.regspacing,
2376 info->irq); 2376 info->irq);
2377 2377
2378 dev->dev.driver_data = (void *) info; 2378 dev_set_drvdata(&dev->dev, info);
2379 2379
2380 return try_smi_init(info); 2380 return try_smi_init(info);
2381} 2381}
2382 2382
2383static int __devexit ipmi_of_remove(struct of_device *dev) 2383static int __devexit ipmi_of_remove(struct of_device *dev)
2384{ 2384{
2385 cleanup_one_si(dev->dev.driver_data); 2385 cleanup_one_si(dev_get_drvdata(&dev->dev));
2386 return 0; 2386 return 0;
2387} 2387}
2388 2388