eisa: 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. Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
This commit is contained in:
@@ -78,12 +78,12 @@ static inline void eisa_driver_unregister (struct eisa_driver *edrv) { }
|
||||
/* Mimics pci.h... */
|
||||
static inline void *eisa_get_drvdata (struct eisa_device *edev)
|
||||
{
|
||||
return edev->dev.driver_data;
|
||||
return dev_get_drvdata(&edev->dev);
|
||||
}
|
||||
|
||||
static inline void eisa_set_drvdata (struct eisa_device *edev, void *data)
|
||||
{
|
||||
edev->dev.driver_data = data;
|
||||
dev_set_drvdata(&edev->dev, data);
|
||||
}
|
||||
|
||||
/* The EISA root device. There's rumours about machines with multiple
|
||||
|
Reference in New Issue
Block a user