Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 6735a197 authored by Linus Torvalds's avatar Linus Torvalds
Browse files

Merge tag 'platform-drivers-x86-v4.13-2' of git://git.infradead.org/linux-platform-drivers-x86

Pull more x86 platform driver updates from Darren Hart:
 "Add new platform matches for silead_dmi and ideapad-laptop. Several
  constify patches for attribute_group structures. Fixes for peaq-wmi
  and intel_telemetry.

  silead_dmi:
   - Add entry for Ployer Momo7w tablet touchscreen
   - Add touchscreen info for I.T.Works TW891 2-in-1

  toshiba_acpi:
   - constify attribute_group structures.

  asus-wmi:
   - constify attribute_group structures.

  panasonic-laptop:
   - constify attribute_group structures.

  alienware-wmi:
   - constify attribute_group structures.

  samsung-laptop:
   - constify attribute_group structures.

  compal-laptop:
   - constify attribute_group structures.

  fujitsu-laptop:
   - constify attribute_group structures.
   - add NULL check on devm_kzalloc() return value

  peaq-wmi:
   - Fix peaq_ignore_events_counter handling off by 1

  ideapad-laptop:
   - Fix indentation in DMI table
   - Add several models to no_hw_rfkill
   - Add IdeaPad V510-15IKB to no_hw_rfkill

  intel_telemetry:
   - Add debugfs entry for S0ix residency

  intel_telemetry_debugfs:
   - fix some error codes in init
   - fix oops when load/unload module"

* tag 'platform-drivers-x86-v4.13-2' of git://git.infradead.org/linux-platform-drivers-x86:
  platform/x86: silead_dmi: Add entry for Ployer Momo7w tablet touchscreen
  platform/x86: toshiba_acpi: constify attribute_group structures.
  platform/x86: asus-wmi: constify attribute_group structures.
  platform/x86: panasonic-laptop: constify attribute_group structures.
  platform/x86: alienware-wmi: constify attribute_group structures.
  platform/x86: samsung-laptop: constify attribute_group structures.
  platform/x86: compal-laptop: constify attribute_group structures.
  platform/x86: fujitsu-laptop: constify attribute_group structures.
  platform/x86: peaq-wmi: Fix peaq_ignore_events_counter handling off by 1
  platform/x86: fujitsu-laptop: add NULL check on devm_kzalloc() return value
  platform/x86: silead_dmi: Add touchscreen info for I.T.Works TW891 2-in-1
  platform/x86: ideapad-laptop: Fix indentation in DMI table
  platform/x86: ideapad-laptop: Add several models to no_hw_rfkill
  platform/x86: ideapad-laptop: Add IdeaPad V510-15IKB to no_hw_rfkill
  platform/x86: intel_telemetry: Add debugfs entry for S0ix residency
  platform/x86: intel_telemetry_debugfs: fix some error codes in init
  platform/x86: intel_telemetry_debugfs: fix oops when load/unload module
parents 8c6f5e73 c3a73ed8
Loading
Loading
Loading
Loading
+3 −3
Original line number Original line Diff line number Diff line
@@ -604,7 +604,7 @@ static struct attribute *hdmi_attrs[] = {
	NULL,
	NULL,
};
};


static struct attribute_group hdmi_attribute_group = {
static const struct attribute_group hdmi_attribute_group = {
	.name = "hdmi",
	.name = "hdmi",
	.attrs = hdmi_attrs,
	.attrs = hdmi_attrs,
};
};
@@ -660,7 +660,7 @@ static struct attribute *amplifier_attrs[] = {
	NULL,
	NULL,
};
};


static struct attribute_group amplifier_attribute_group = {
static const struct attribute_group amplifier_attribute_group = {
	.name = "amplifier",
	.name = "amplifier",
	.attrs = amplifier_attrs,
	.attrs = amplifier_attrs,
};
};
@@ -741,7 +741,7 @@ static struct attribute *deepsleep_attrs[] = {
	NULL,
	NULL,
};
};


static struct attribute_group deepsleep_attribute_group = {
static const struct attribute_group deepsleep_attribute_group = {
	.name = "deepsleep",
	.name = "deepsleep",
	.attrs = deepsleep_attrs,
	.attrs = deepsleep_attrs,
};
};
+2 −2
Original line number Original line Diff line number Diff line
@@ -1433,7 +1433,7 @@ static umode_t asus_hwmon_sysfs_is_visible(struct kobject *kobj,
	return ok ? attr->mode : 0;
	return ok ? attr->mode : 0;
}
}


static struct attribute_group hwmon_attribute_group = {
static const struct attribute_group hwmon_attribute_group = {
	.is_visible = asus_hwmon_sysfs_is_visible,
	.is_visible = asus_hwmon_sysfs_is_visible,
	.attrs = hwmon_attributes
	.attrs = hwmon_attributes
};
};
@@ -1821,7 +1821,7 @@ static umode_t asus_sysfs_is_visible(struct kobject *kobj,
	return ok ? attr->mode : 0;
	return ok ? attr->mode : 0;
}
}


static struct attribute_group platform_attribute_group = {
static const struct attribute_group platform_attribute_group = {
	.is_visible = asus_sysfs_is_visible,
	.is_visible = asus_sysfs_is_visible,
	.attrs = platform_attributes
	.attrs = platform_attributes
};
};
+1 −1
Original line number Original line Diff line number Diff line
@@ -718,7 +718,7 @@ static struct attribute *compal_platform_attrs[] = {
	&dev_attr_wake_up_mouse.attr,
	&dev_attr_wake_up_mouse.attr,
	NULL
	NULL
};
};
static struct attribute_group compal_platform_attr_group = {
static const struct attribute_group compal_platform_attr_group = {
	.attrs = compal_platform_attrs
	.attrs = compal_platform_attrs
};
};


+13 −1
Original line number Original line Diff line number Diff line
@@ -317,7 +317,7 @@ static struct attribute *fujitsu_pf_attributes[] = {
	NULL
	NULL
};
};


static struct attribute_group fujitsu_pf_attribute_group = {
static const struct attribute_group fujitsu_pf_attribute_group = {
	.attrs = fujitsu_pf_attributes
	.attrs = fujitsu_pf_attributes
};
};


@@ -695,6 +695,9 @@ static int acpi_fujitsu_laptop_leds_register(struct acpi_device *device)
	if (call_fext_func(device,
	if (call_fext_func(device,
			   FUNC_LEDS, 0x0, 0x0, 0x0) & LOGOLAMP_POWERON) {
			   FUNC_LEDS, 0x0, 0x0, 0x0) & LOGOLAMP_POWERON) {
		led = devm_kzalloc(&device->dev, sizeof(*led), GFP_KERNEL);
		led = devm_kzalloc(&device->dev, sizeof(*led), GFP_KERNEL);
		if (!led)
			return -ENOMEM;

		led->name = "fujitsu::logolamp";
		led->name = "fujitsu::logolamp";
		led->brightness_set_blocking = logolamp_set;
		led->brightness_set_blocking = logolamp_set;
		led->brightness_get = logolamp_get;
		led->brightness_get = logolamp_get;
@@ -707,6 +710,9 @@ static int acpi_fujitsu_laptop_leds_register(struct acpi_device *device)
			    FUNC_LEDS, 0x0, 0x0, 0x0) & KEYBOARD_LAMPS) &&
			    FUNC_LEDS, 0x0, 0x0, 0x0) & KEYBOARD_LAMPS) &&
	    (call_fext_func(device, FUNC_BUTTONS, 0x0, 0x0, 0x0) == 0x0)) {
	    (call_fext_func(device, FUNC_BUTTONS, 0x0, 0x0, 0x0) == 0x0)) {
		led = devm_kzalloc(&device->dev, sizeof(*led), GFP_KERNEL);
		led = devm_kzalloc(&device->dev, sizeof(*led), GFP_KERNEL);
		if (!led)
			return -ENOMEM;

		led->name = "fujitsu::kblamps";
		led->name = "fujitsu::kblamps";
		led->brightness_set_blocking = kblamps_set;
		led->brightness_set_blocking = kblamps_set;
		led->brightness_get = kblamps_get;
		led->brightness_get = kblamps_get;
@@ -723,6 +729,9 @@ static int acpi_fujitsu_laptop_leds_register(struct acpi_device *device)
	 */
	 */
	if (call_fext_func(device, FUNC_BUTTONS, 0x0, 0x0, 0x0) & BIT(24)) {
	if (call_fext_func(device, FUNC_BUTTONS, 0x0, 0x0, 0x0) & BIT(24)) {
		led = devm_kzalloc(&device->dev, sizeof(*led), GFP_KERNEL);
		led = devm_kzalloc(&device->dev, sizeof(*led), GFP_KERNEL);
		if (!led)
			return -ENOMEM;

		led->name = "fujitsu::radio_led";
		led->name = "fujitsu::radio_led";
		led->brightness_set_blocking = radio_led_set;
		led->brightness_set_blocking = radio_led_set;
		led->brightness_get = radio_led_get;
		led->brightness_get = radio_led_get;
@@ -741,6 +750,9 @@ static int acpi_fujitsu_laptop_leds_register(struct acpi_device *device)
	    (call_fext_func(device,
	    (call_fext_func(device,
			    FUNC_LEDS, 0x2, ECO_LED, 0x0) != UNSUPPORTED_CMD)) {
			    FUNC_LEDS, 0x2, ECO_LED, 0x0) != UNSUPPORTED_CMD)) {
		led = devm_kzalloc(&device->dev, sizeof(*led), GFP_KERNEL);
		led = devm_kzalloc(&device->dev, sizeof(*led), GFP_KERNEL);
		if (!led)
			return -ENOMEM;

		led->name = "fujitsu::eco_led";
		led->name = "fujitsu::eco_led";
		led->brightness_set_blocking = eco_led_set;
		led->brightness_set_blocking = eco_led_set;
		led->brightness_get = eco_led_get;
		led->brightness_get = eco_led_get;
+81 −4
Original line number Original line Diff line number Diff line
@@ -908,6 +908,27 @@ static const struct dmi_system_id no_hw_rfkill_list[] = {
			DMI_MATCH(DMI_PRODUCT_VERSION, "Lenovo G50-30"),
			DMI_MATCH(DMI_PRODUCT_VERSION, "Lenovo G50-30"),
		},
		},
	},
	},
	{
		.ident = "Lenovo V310-14IKB",
		.matches = {
			DMI_MATCH(DMI_SYS_VENDOR, "LENOVO"),
			DMI_MATCH(DMI_PRODUCT_VERSION, "Lenovo V310-14IKB"),
		},
	},
	{
		.ident = "Lenovo V310-14ISK",
		.matches = {
			DMI_MATCH(DMI_SYS_VENDOR, "LENOVO"),
			DMI_MATCH(DMI_PRODUCT_VERSION, "Lenovo V310-14ISK"),
		},
	},
	{
		.ident = "Lenovo V310-15IKB",
		.matches = {
			DMI_MATCH(DMI_SYS_VENDOR, "LENOVO"),
			DMI_MATCH(DMI_PRODUCT_VERSION, "Lenovo V310-15IKB"),
		},
	},
	{
	{
		.ident = "Lenovo V310-15ISK",
		.ident = "Lenovo V310-15ISK",
		.matches = {
		.matches = {
@@ -915,6 +936,48 @@ static const struct dmi_system_id no_hw_rfkill_list[] = {
			DMI_MATCH(DMI_PRODUCT_VERSION, "Lenovo V310-15ISK"),
			DMI_MATCH(DMI_PRODUCT_VERSION, "Lenovo V310-15ISK"),
		},
		},
	},
	},
	{
		.ident = "Lenovo V510-15IKB",
		.matches = {
			DMI_MATCH(DMI_SYS_VENDOR, "LENOVO"),
			DMI_MATCH(DMI_PRODUCT_VERSION, "Lenovo V510-15IKB"),
		},
	},
	{
		.ident = "Lenovo ideapad 300-15IBR",
		.matches = {
			DMI_MATCH(DMI_SYS_VENDOR, "LENOVO"),
			DMI_MATCH(DMI_PRODUCT_VERSION, "Lenovo ideapad 300-15IBR"),
		},
	},
	{
		.ident = "Lenovo ideapad 300-15IKB",
		.matches = {
			DMI_MATCH(DMI_SYS_VENDOR, "LENOVO"),
			DMI_MATCH(DMI_PRODUCT_VERSION, "Lenovo ideapad 300-15IKB"),
		},
	},
	{
		.ident = "Lenovo ideapad 300S-11IBR",
		.matches = {
			DMI_MATCH(DMI_SYS_VENDOR, "LENOVO"),
			DMI_MATCH(DMI_PRODUCT_VERSION, "Lenovo ideapad 300S-11BR"),
		},
	},
	{
		.ident = "Lenovo ideapad 310-15ABR",
		.matches = {
			DMI_MATCH(DMI_SYS_VENDOR, "LENOVO"),
			DMI_MATCH(DMI_PRODUCT_VERSION, "Lenovo ideapad 310-15ABR"),
		},
	},
	{
		.ident = "Lenovo ideapad 310-15IAP",
		.matches = {
			DMI_MATCH(DMI_SYS_VENDOR, "LENOVO"),
			DMI_MATCH(DMI_PRODUCT_VERSION, "Lenovo ideapad 310-15IAP"),
		},
	},
	{
	{
		.ident = "Lenovo ideapad 310-15IKB",
		.ident = "Lenovo ideapad 310-15IKB",
		.matches = {
		.matches = {
@@ -922,6 +985,20 @@ static const struct dmi_system_id no_hw_rfkill_list[] = {
			DMI_MATCH(DMI_PRODUCT_VERSION, "Lenovo ideapad 310-15IKB"),
			DMI_MATCH(DMI_PRODUCT_VERSION, "Lenovo ideapad 310-15IKB"),
		},
		},
	},
	},
	{
		.ident = "Lenovo ideapad 310-15ISK",
		.matches = {
			DMI_MATCH(DMI_SYS_VENDOR, "LENOVO"),
			DMI_MATCH(DMI_PRODUCT_VERSION, "Lenovo ideapad 310-15ISK"),
		},
	},
	{
		.ident = "Lenovo ideapad Y700-14ISK",
		.matches = {
			DMI_MATCH(DMI_SYS_VENDOR, "LENOVO"),
			DMI_MATCH(DMI_PRODUCT_VERSION, "Lenovo ideapad Y700-14ISK"),
		},
	},
	{
	{
		.ident = "Lenovo ideapad Y700-15ACZ",
		.ident = "Lenovo ideapad Y700-15ACZ",
		.matches = {
		.matches = {
Loading