linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* linux-next: manual merge of the drivers-x86 tree with the drivers-x86-fixes tree
@ 2022-06-29  3:34 Stephen Rothwell
  0 siblings, 0 replies; 3+ messages in thread
From: Stephen Rothwell @ 2022-06-29  3:34 UTC (permalink / raw)
  To: Hans de Goede, Mark Gross
  Cc: Linux Kernel Mailing List, Linux Next Mailing List,
	Mario Limonciello, Mark Pearson

[-- Attachment #1: Type: text/plain, Size: 905 bytes --]

Hi all,

Today's linux-next merge of the drivers-x86 tree got a conflict in:

  drivers/platform/x86/thinkpad_acpi.c

between commits:

  42504af77536 ("platform/x86: thinkpad-acpi: profile capabilities as integer")
  bce6243f767f ("platform/x86: thinkpad_acpi: do not use PSC mode on Intel platforms")

from the drivers-x86-fixes tree and commit:

  6fe391dd5d87 ("platform/x86: thinkpad-acpi: profile capabilities as integer")

from the drivers-x86 tree.

I fixed it up (I just used the former version) and can carry the fix as
necessary. This is now fixed as far as linux-next is concerned, but any
non trivial conflicts should be mentioned to your upstream maintainer
when your tree is submitted for merging.  You may also want to consider
cooperating with the maintainer of the conflicting tree to minimise any
particularly complex conflicts.

-- 
Cheers,
Stephen Rothwell

[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 488 bytes --]

^ permalink raw reply	[flat|nested] 3+ messages in thread

* linux-next: manual merge of the drivers-x86 tree with the drivers-x86-fixes tree
@ 2025-04-22  7:56 Stephen Rothwell
  0 siblings, 0 replies; 3+ messages in thread
From: Stephen Rothwell @ 2025-04-22  7:56 UTC (permalink / raw)
  To: Hans de Goede, Mark Gross
  Cc: Ilpo Järvinen, Kurt Borja, Linux Kernel Mailing List,
	Linux Next Mailing List

[-- Attachment #1: Type: text/plain, Size: 5757 bytes --]

Hi all,

Today's linux-next merge of the drivers-x86 tree got a conflict in:

  drivers/platform/x86/dell/alienware-wmi-wmax.c

between commit:

  4a8e04e2bdcb ("platform/x86: alienware-wmi-wmax: Fix uninitialized variable due to bad error handling")

from the drivers-x86-fixes tree and commit:

  32b6372ddd43 ("platform/x86: alienware-wmi-wmax: Improve platform profile probe")

from the drivers-x86 tree.

I fixed it up (see below) and can carry the fix as necessary. This
is now fixed as far as linux-next is concerned, but any non trivial
conflicts should be mentioned to your upstream maintainer when your tree
is submitted for merging.  You may also want to consider cooperating
with the maintainer of the conflicting tree to minimise any particularly
complex conflicts.

-- 
Cheers,
Stephen Rothwell

diff --cc drivers/platform/x86/dell/alienware-wmi-wmax.c
index 3f9e1e986ecf,faeddfe3b79e..000000000000
--- a/drivers/platform/x86/dell/alienware-wmi-wmax.c
+++ b/drivers/platform/x86/dell/alienware-wmi-wmax.c
@@@ -189,48 -174,61 +214,69 @@@ static const struct dmi_system_id awcc_
  		},
  		.driver_data = &g_series_quirks,
  	},
 +	{
 +		.ident = "Dell Inc. G5 5505",
 +		.matches = {
 +			DMI_MATCH(DMI_SYS_VENDOR, "Dell Inc."),
 +			DMI_MATCH(DMI_PRODUCT_NAME, "G5 5505"),
 +		},
 +		.driver_data = &g_series_quirks,
 +	},
  };
  
- enum WMAX_THERMAL_INFORMATION_OPERATIONS {
- 	WMAX_OPERATION_SYS_DESCRIPTION		= 0x02,
- 	WMAX_OPERATION_LIST_IDS			= 0x03,
- 	WMAX_OPERATION_CURRENT_PROFILE		= 0x0B,
+ enum AWCC_GET_FAN_SENSORS_OPERATIONS {
+ 	AWCC_OP_GET_TOTAL_FAN_TEMPS		= 0x01,
+ 	AWCC_OP_GET_FAN_TEMP_ID			= 0x02,
  };
  
- enum WMAX_THERMAL_CONTROL_OPERATIONS {
- 	WMAX_OPERATION_ACTIVATE_PROFILE		= 0x01,
+ enum AWCC_THERMAL_INFORMATION_OPERATIONS {
+ 	AWCC_OP_GET_SYSTEM_DESCRIPTION		= 0x02,
+ 	AWCC_OP_GET_RESOURCE_ID			= 0x03,
+ 	AWCC_OP_GET_TEMPERATURE			= 0x04,
+ 	AWCC_OP_GET_FAN_RPM			= 0x05,
+ 	AWCC_OP_GET_FAN_MIN_RPM			= 0x08,
+ 	AWCC_OP_GET_FAN_MAX_RPM			= 0x09,
+ 	AWCC_OP_GET_CURRENT_PROFILE		= 0x0B,
+ 	AWCC_OP_GET_FAN_BOOST			= 0x0C,
  };
  
- enum WMAX_GAME_SHIFT_STATUS_OPERATIONS {
- 	WMAX_OPERATION_TOGGLE_GAME_SHIFT	= 0x01,
- 	WMAX_OPERATION_GET_GAME_SHIFT_STATUS	= 0x02,
+ enum AWCC_THERMAL_CONTROL_OPERATIONS {
+ 	AWCC_OP_ACTIVATE_PROFILE		= 0x01,
+ 	AWCC_OP_SET_FAN_BOOST			= 0x02,
  };
  
- enum WMAX_THERMAL_TABLES {
- 	WMAX_THERMAL_TABLE_BASIC		= 0x90,
- 	WMAX_THERMAL_TABLE_USTT			= 0xA0,
+ enum AWCC_GAME_SHIFT_STATUS_OPERATIONS {
+ 	AWCC_OP_TOGGLE_GAME_SHIFT		= 0x01,
+ 	AWCC_OP_GET_GAME_SHIFT_STATUS		= 0x02,
  };
  
- enum wmax_thermal_mode {
- 	THERMAL_MODE_USTT_BALANCED,
- 	THERMAL_MODE_USTT_BALANCED_PERFORMANCE,
- 	THERMAL_MODE_USTT_COOL,
- 	THERMAL_MODE_USTT_QUIET,
- 	THERMAL_MODE_USTT_PERFORMANCE,
- 	THERMAL_MODE_USTT_LOW_POWER,
- 	THERMAL_MODE_BASIC_QUIET,
- 	THERMAL_MODE_BASIC_BALANCED,
- 	THERMAL_MODE_BASIC_BALANCED_PERFORMANCE,
- 	THERMAL_MODE_BASIC_PERFORMANCE,
- 	THERMAL_MODE_LAST,
+ enum AWCC_THERMAL_TABLES {
+ 	AWCC_THERMAL_TABLE_LEGACY		= 0x9,
+ 	AWCC_THERMAL_TABLE_USTT			= 0xA,
+ };
+ 
+ enum AWCC_SPECIAL_THERMAL_CODES {
+ 	AWCC_SPECIAL_PROFILE_CUSTOM		= 0x00,
+ 	AWCC_SPECIAL_PROFILE_GMODE		= 0xAB,
+ };
+ 
+ enum AWCC_TEMP_SENSOR_TYPES {
+ 	AWCC_TEMP_SENSOR_CPU			= 0x01,
+ 	AWCC_TEMP_SENSOR_GPU			= 0x06,
+ };
+ 
+ enum awcc_thermal_profile {
+ 	AWCC_PROFILE_USTT_BALANCED,
+ 	AWCC_PROFILE_USTT_BALANCED_PERFORMANCE,
+ 	AWCC_PROFILE_USTT_COOL,
+ 	AWCC_PROFILE_USTT_QUIET,
+ 	AWCC_PROFILE_USTT_PERFORMANCE,
+ 	AWCC_PROFILE_USTT_LOW_POWER,
+ 	AWCC_PROFILE_LEGACY_QUIET,
+ 	AWCC_PROFILE_LEGACY_BALANCED,
+ 	AWCC_PROFILE_LEGACY_BALANCED_PERFORMANCE,
+ 	AWCC_PROFILE_LEGACY_PERFORMANCE,
+ 	AWCC_PROFILE_LAST,
  };
  
  struct wmax_led_args {
@@@ -639,35 -1192,38 +1240,38 @@@ static int awcc_platform_profile_probe(
  {
  	enum platform_profile_option profile;
  	struct awcc_priv *priv = drvdata;
- 	enum wmax_thermal_mode mode;
- 	u8 sys_desc[4];
- 	u32 first_mode;
- 	u32 out_data;
+ 	enum awcc_thermal_profile mode;
+ 	u8 id, offset = 0;
  	int ret;
  
- 	ret = wmax_thermal_information(priv->wdev, WMAX_OPERATION_SYS_DESCRIPTION,
- 				       0, (u32 *) &sys_desc);
- 	if (ret < 0)
- 		return ret;
+ 	/*
+ 	 * Thermal profile IDs are listed last at offset
+ 	 *	fan_count + temp_count + unknown_count
+ 	 */
+ 	for (unsigned int i = 0; i < ARRAY_SIZE(priv->res_count) - 1; i++)
+ 		offset += priv->res_count[i];
  
- 	first_mode = sys_desc[0] + sys_desc[1];
- 
- 	for (u32 i = 0; i < sys_desc[3]; i++) {
- 		ret = wmax_thermal_information(priv->wdev, WMAX_OPERATION_LIST_IDS,
- 					       i + first_mode, &out_data);
+ 	for (unsigned int i = 0; i < priv->profile_count; i++) {
+ 		ret = awcc_op_get_resource_id(priv->wdev, i + offset, &id);
 -		if (ret == -EIO)
 -			return ret;
+ 		/*
+ 		 * Some devices report an incorrect number of thermal profiles
+ 		 * so the resource ID list may end prematurely
+ 		 */
  		if (ret == -EBADRQC)
  			break;
 +		if (ret)
 +			return ret;
  
- 		if (!is_wmax_thermal_code(out_data))
+ 		if (!is_awcc_thermal_profile_id(id)) {
+ 			dev_dbg(&priv->wdev->dev, "Unmapped thermal profile ID 0x%02x\n", id);
  			continue;
+ 		}
  
- 		mode = out_data & WMAX_THERMAL_MODE_MASK;
- 		profile = wmax_mode_to_platform_profile[mode];
- 		priv->supported_thermal_profiles[profile] = out_data;
+ 		mode = FIELD_GET(AWCC_THERMAL_MODE_MASK, id);
+ 		profile = awcc_mode_to_platform_profile[mode];
+ 		priv->supported_profiles[profile] = id;
  
- 		set_bit(profile, choices);
+ 		__set_bit(profile, choices);
  	}
  
  	if (bitmap_empty(choices, PLATFORM_PROFILE_LAST))

[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 488 bytes --]

^ permalink raw reply	[flat|nested] 3+ messages in thread

* linux-next: manual merge of the drivers-x86 tree with the drivers-x86-fixes tree
@ 2025-07-14  5:11 Stephen Rothwell
  0 siblings, 0 replies; 3+ messages in thread
From: Stephen Rothwell @ 2025-07-14  5:11 UTC (permalink / raw)
  To: Hans de Goede, Mark Gross
  Cc: Ilpo Järvinen, Linux Kernel Mailing List,
	Linux Next Mailing List, Mark Pearson, Torsten Hilbrich

[-- Attachment #1: Type: text/plain, Size: 1831 bytes --]

Hi all,

Today's linux-next merge of the drivers-x86 tree got a conflict in:

  drivers/platform/x86/Makefile

between commit:

  2bfe3ae1aa45 ("platform/x86: Fix initialization order for firmware_attributes_class")

from the drivers-x86-fixes tree and commit:

  651b57dd4087 ("platform/x86: Move Lenovo files into lenovo subdir")

from the drivers-x86 tree.

I fixed it up (see below) and can carry the fix as necessary. This
is now fixed as far as linux-next is concerned, but any non trivial
conflicts should be mentioned to your upstream maintainer when your tree
is submitted for merging.  You may also want to consider cooperating
with the maintainer of the conflicting tree to minimise any particularly
complex conflicts.

-- 
Cheers,
Stephen Rothwell

diff --cc drivers/platform/x86/Makefile
index bea87a85ae75,0530a224bebd..000000000000
--- a/drivers/platform/x86/Makefile
+++ b/drivers/platform/x86/Makefile
@@@ -58,19 -58,12 +58,14 @@@ obj-$(CONFIG_X86_PLATFORM_DRIVERS_HP)	+
  # Hewlett Packard Enterprise
  obj-$(CONFIG_UV_SYSFS)       += uv_sysfs.o
  
 +obj-$(CONFIG_FW_ATTR_CLASS)	+= firmware_attributes_class.o
 +
- # IBM Thinkpad and Lenovo
+ # IBM Thinkpad (before 2005)
  obj-$(CONFIG_IBM_RTL)		+= ibm_rtl.o
- obj-$(CONFIG_IDEAPAD_LAPTOP)	+= ideapad-laptop.o
- obj-$(CONFIG_LENOVO_WMI_HOTKEY_UTILITIES)	+= lenovo-wmi-hotkey-utilities.o
- obj-$(CONFIG_LENOVO_YMC)	+= lenovo-ymc.o
  obj-$(CONFIG_SENSORS_HDAPS)	+= hdaps.o
- obj-$(CONFIG_THINKPAD_ACPI)	+= thinkpad_acpi.o
- obj-$(CONFIG_THINKPAD_LMI)	+= think-lmi.o
- obj-$(CONFIG_YOGABOOK)		+= lenovo-yogabook.o
- obj-$(CONFIG_YT2_1380)		+= lenovo-yoga-tab2-pro-1380-fastcharger.o
- obj-$(CONFIG_LENOVO_WMI_CAMERA)	+= lenovo-wmi-camera.o
+ 
+ # Lenovo
+ obj-y				+= lenovo/
  
  # Intel
  obj-y				+= intel/

[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 488 bytes --]

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2025-07-14  5:12 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-07-14  5:11 linux-next: manual merge of the drivers-x86 tree with the drivers-x86-fixes tree Stephen Rothwell
  -- strict thread matches above, loose matches on Subject: below --
2025-04-22  7:56 Stephen Rothwell
2022-06-29  3:34 Stephen Rothwell

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).