Skip to content

Commit

Permalink
Merge branch 'for-6.2/sensor' into for-linus
Browse files Browse the repository at this point in the history
- support for more than one hinge sensor in hid-sensor-custom (Yauhen Kharuzhy)
  • Loading branch information
Jiri Kosina committed Dec 13, 2022
2 parents 54dcc80 + 9d01391 commit 6cd132b
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions drivers/hid/hid-sensor-custom.c
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ struct hid_sensor_sample {
u32 raw_len;
} __packed;

static struct attribute hid_custom_attrs[] = {
static struct attribute hid_custom_attrs[HID_CUSTOM_TOTAL_ATTRS] = {
{.name = "name", .mode = S_IRUGO},
{.name = "units", .mode = S_IRUGO},
{.name = "unit-expo", .mode = S_IRUGO},
Expand Down Expand Up @@ -862,7 +862,7 @@ hid_sensor_register_platform_device(struct platform_device *pdev,
return ERR_PTR(-ENOMEM);

custom_pdev = platform_device_register_data(pdev->dev.parent, dev_name,
PLATFORM_DEVID_NONE, hsdev,
PLATFORM_DEVID_AUTO, hsdev,
sizeof(*hsdev));
kfree(dev_name);
return custom_pdev;
Expand Down

0 comments on commit 6cd132b

Please sign in to comment.