aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/platform/surface/surface_platform_profile.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/platform/surface/surface_platform_profile.c')
-rw-r--r--drivers/platform/surface/surface_platform_profile.c8
1 files changed, 6 insertions, 2 deletions
diff --git a/drivers/platform/surface/surface_platform_profile.c b/drivers/platform/surface/surface_platform_profile.c
index 26c1230e75df..76967bfeeef8 100644
--- a/drivers/platform/surface/surface_platform_profile.c
+++ b/drivers/platform/surface/surface_platform_profile.c
@@ -201,6 +201,11 @@ static int ssam_platform_profile_set(struct device *dev,
return tp;
}
+static const struct platform_profile_ops ssam_platform_profile_ops = {
+ .profile_get = ssam_platform_profile_get,
+ .profile_set = ssam_platform_profile_set,
+};
+
static int surface_platform_profile_probe(struct ssam_device *sdev)
{
struct ssam_platform_profile_device *tpd;
@@ -214,8 +219,7 @@ static int surface_platform_profile_probe(struct ssam_device *sdev)
tpd->handler.name = "Surface Platform Profile";
tpd->handler.dev = &sdev->dev;
- tpd->handler.profile_get = ssam_platform_profile_get;
- tpd->handler.profile_set = ssam_platform_profile_set;
+ tpd->handler.ops = &ssam_platform_profile_ops;
tpd->has_fan = device_property_read_bool(&sdev->dev, "has_fan");