mirror of
https://github.com/edk2-porting/linux-next.git
synced 2024-12-26 06:04:14 +08:00
drm/i2c/ch7006: Convert to dev_pm_ops
The I2C specific suspend and resume functions have been deprecated and printing a warning on boot for over a year, dev_pm_ops should be used instead so convert to that. Also remove the suspend function since all it does is log. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Acked-by: Francisco Jerez <currojerez@riseup.net> Signed-off-by: Dave Airlie <airlied@redhat.com>
This commit is contained in:
parent
df0b344300
commit
0227a7fdc2
@ -427,15 +427,10 @@ static int ch7006_remove(struct i2c_client *client)
|
||||
return 0;
|
||||
}
|
||||
|
||||
static int ch7006_suspend(struct i2c_client *client, pm_message_t mesg)
|
||||
static int ch7006_resume(struct device *dev)
|
||||
{
|
||||
ch7006_dbg(client, "\n");
|
||||
struct i2c_client *client = to_i2c_client(dev);
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
static int ch7006_resume(struct i2c_client *client)
|
||||
{
|
||||
ch7006_dbg(client, "\n");
|
||||
|
||||
ch7006_write(client, 0x3d, 0x0);
|
||||
@ -499,15 +494,18 @@ static struct i2c_device_id ch7006_ids[] = {
|
||||
};
|
||||
MODULE_DEVICE_TABLE(i2c, ch7006_ids);
|
||||
|
||||
static const struct dev_pm_ops ch7006_pm_ops = {
|
||||
.resume = ch7006_resume,
|
||||
};
|
||||
|
||||
static struct drm_i2c_encoder_driver ch7006_driver = {
|
||||
.i2c_driver = {
|
||||
.probe = ch7006_probe,
|
||||
.remove = ch7006_remove,
|
||||
.suspend = ch7006_suspend,
|
||||
.resume = ch7006_resume,
|
||||
|
||||
.driver = {
|
||||
.name = "ch7006",
|
||||
.pm = &ch7006_pm_ops,
|
||||
},
|
||||
|
||||
.id_table = ch7006_ids,
|
||||
|
Loading…
Reference in New Issue
Block a user