mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* linux-next: manual merge of the hwmon-staging tree with the hwmon-fixes tree
@ 2026-05-08 11:13 Thierry Reding
  0 siblings, 0 replies; 2+ messages in thread
From: Thierry Reding @ 2026-05-08 11:13 UTC (permalink / raw)
  To: Guenter Roeck
  Cc: Linux Kernel Mailing List, Linux Next Mailing List, Markus Stockhausen

Hi all,

Today's linux-next merge of the hwmon-staging tree got a conflict in:

  drivers/hwmon/lm75.c

between commit:

  3607422cdeeb ("hwmon: (lm75) Fix AS6200 and TMP112 setup and alarm handling")

from the hwmon-fixes tree and commit:

  4ab59263fd78 ("hwmon: (lm75) Fix AS6200 setup and alarm handling")

from the hwmon-staging tree.

I fixed it up by using the version from hwmon-staging. There's a 50%
chance that I got it right. 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.

^ permalink raw reply	[flat|nested] 2+ messages in thread
* linux-next: manual merge of the hwmon-staging tree with the hwmon-fixes tree
@ 2026-09-28 12:48 Mark Brown
  0 siblings, 0 replies; 2+ messages in thread
From: Mark Brown @ 2026-09-28 12:48 UTC (permalink / raw)
  To: Guenter Roeck
  Cc: Alessandro Zini, Linux Kernel Mailing List,
	Linux Next Mailing List, Tom Verdonck

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

Hi all,

Today's linux-next merge of the hwmon-staging tree got a conflict in:

  drivers/hwmon/sht4x.c

between commit:

  61406e9cac695 ("hwmon: (sht4x) Fix jiffies wraparound in heater-ready check")

from the hwmon-fixes tree and commit:

  3a4bf85531c55 ("hwmon: (sht4x) Add support for Sensirion STS4x temperature sensors")

from the hwmon-staging 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.

diff --cc drivers/hwmon/sht4x.c
index da2b6130fca7e,fd1f950448f06..0000000000000
--- a/drivers/hwmon/sht4x.c
+++ b/drivers/hwmon/sht4x.c
@@@ -67,7 -74,8 +74,8 @@@ enum sht4x_chips 
   */
  struct sht4x_data {
  	struct i2c_client	*client;
+ 	enum sht4x_chips	chip_id;
 -	unsigned long		heating_complete;	/* in jiffies */
 +	u64			heating_complete;	/* in jiffies */
  	bool			data_pending;
  	u32			heater_power;	/* in milli-watts */
  	u32			heater_time;	/* in milli-seconds */
@@@ -92,14 -100,18 +100,19 @@@ static int sht4x_read_values(struct sht
  	u8 crc;
  	u8 cmd[SHT4X_CMD_LEN] = {SHT4X_CMD_MEASURE_HPM};
  	u8 raw_data[SHT4X_RESPONSE_LENGTH];
+ 	size_t response_length = data->chip_id == sts4x ?
+ 				 STS4X_RESPONSE_LENGTH : SHT4X_RESPONSE_LENGTH;
 -	unsigned long curr_jiffies;
 +	u64 curr_jiffies;
  
- 	curr_jiffies = get_jiffies_64();
- 	if (time_before64(curr_jiffies, data->heating_complete))
- 		msleep(jiffies_to_msecs(data->heating_complete - curr_jiffies));
+ 	if (data->chip_id != sts4x) {
 -		curr_jiffies = jiffies;
 -		if (time_before(curr_jiffies, data->heating_complete))
++		curr_jiffies = get_jiffies_64();
++		if (time_before64(curr_jiffies, data->heating_complete)) {
+ 			msleep(jiffies_to_msecs(data->heating_complete - curr_jiffies));
++		}
+ 	}
  
  	if (data->data_pending &&
 -	    time_before(jiffies, data->heating_complete + data->update_interval)) {
 +	    time_before64(get_jiffies_64(), data->heating_complete + data->update_interval)) {
  		data->data_pending = false;
  	} else {
  		next_update = data->last_updated +
@@@ -406,11 -428,15 +429,15 @@@ static int sht4x_probe(struct i2c_clien
  	if (!data)
  		return -ENOMEM;
  
+ 	data->chip_id = (uintptr_t)i2c_get_match_data(client);
  	data->update_interval = SHT4X_MIN_POLL_INTERVAL;
  	data->client = client;
- 	data->heater_power = 200;
- 	data->heater_time = 1000;
 -	data->heating_complete = jiffies;
 +	data->heating_complete = get_jiffies_64();
+ 	if (data->chip_id != sts4x) {
+ 		data->heater_power = 200;
+ 		data->heater_time = 1000;
+ 		groups = sht4x_groups;
+ 	}
  
  	crc8_populate_msb(sht4x_crc8_table, SHT4X_CRC8_POLYNOMIAL);
  

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

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

end of thread, other threads:[~2026-09-28 12:48 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2026-05-08 11:13 linux-next: manual merge of the hwmon-staging tree with the hwmon-fixes tree Thierry Reding
2026-09-28 12:48 Mark Brown

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®