<feed xmlns='http://www.w3.org/2005/Atom'>
<title>kernel/linux.git/drivers/hwmon, branch v4.19.39</title>
<subtitle>Linux kernel stable tree (mirror)</subtitle>
<id>https://git.radix-linux.su/kernel/linux.git/atom?h=v4.19.39</id>
<link rel='self' href='https://git.radix-linux.su/kernel/linux.git/atom?h=v4.19.39'/>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/'/>
<updated>2019-04-17T06:38:47+00:00</updated>
<entry>
<title>hwmon: (w83773g) Select REGMAP_I2C to fix build error</title>
<updated>2019-04-17T06:38:47+00:00</updated>
<author>
<name>Axel Lin</name>
<email>axel.lin@ingics.com</email>
</author>
<published>2019-03-11T09:57:30+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=370004024aec354bcab509bb506b939cf43b4265'/>
<id>urn:sha1:370004024aec354bcab509bb506b939cf43b4265</id>
<content type='text'>
commit a165dcc923ada2ffdee1d4f41f12f81b66d04c55 upstream.

Select REGMAP_I2C to avoid below build error:
ERROR: "__devm_regmap_init_i2c" [drivers/hwmon/w83773g.ko] undefined!

Fixes: ee249f271524 ("hwmon: Add W83773G driver")
Cc: stable@vger.kernel.org
Signed-off-by: Axel Lin &lt;axel.lin@ingics.com&gt;
Signed-off-by: Guenter Roeck &lt;linux@roeck-us.net&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;

</content>
</entry>
<entry>
<title>hwmon: (tmp421) Correct the misspelling of the tmp442 compatible attribute in OF device ID table</title>
<updated>2019-02-27T09:08:57+00:00</updated>
<author>
<name>Cheng-Min Ao</name>
<email>tony_ao@wiwynn.com</email>
</author>
<published>2019-01-07T06:29:32+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=ddb8d7c9d46041954256eec953d07b15023b5be2'/>
<id>urn:sha1:ddb8d7c9d46041954256eec953d07b15023b5be2</id>
<content type='text'>
[ Upstream commit f422449b58548a41e98fc97b259a283718e527db ]

Correct a typo in OF device ID table
The last one should be 'ti,tmp442'

Signed-off-by: Cheng-Min Ao &lt;tony_ao@wiwynn.com&gt;
Signed-off-by: Yu-Hsiang Chen &lt;matt_chen@wiwynn.com&gt;
Signed-off-by: Guenter Roeck &lt;linux@roeck-us.net&gt;
Signed-off-by: Sasha Levin &lt;sashal@kernel.org&gt;
</content>
</entry>
<entry>
<title>hwmon: (lm80) Fix missing unlock on error in set_fan_div()</title>
<updated>2019-02-23T08:07:26+00:00</updated>
<author>
<name>Wei Yongjun</name>
<email>weiyongjun1@huawei.com</email>
</author>
<published>2018-12-26T11:28:24+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=82f39f0219441075bdba1aa3e14b5d4b1fa0b481'/>
<id>urn:sha1:82f39f0219441075bdba1aa3e14b5d4b1fa0b481</id>
<content type='text'>
commit 07bd14ccc3049f9c0147a91a4227a571f981601a upstream.

Add the missing unlock before return from function set_fan_div()
in the error handling case.

Fixes: c9c63915519b ("hwmon: (lm80) fix a missing check of the status of SMBus read")
Signed-off-by: Wei Yongjun &lt;weiyongjun1@huawei.com&gt;
Signed-off-by: Guenter Roeck &lt;linux@roeck-us.net&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;

</content>
</entry>
<entry>
<title>hwmon: (lm80) fix a missing check of bus read in lm80 probe</title>
<updated>2019-02-12T18:47:16+00:00</updated>
<author>
<name>Kangjie Lu</name>
<email>kjlu@umn.edu</email>
</author>
<published>2018-12-21T19:10:39+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=040f76976ec5cb332ccdcc734d1c485d87e803a4'/>
<id>urn:sha1:040f76976ec5cb332ccdcc734d1c485d87e803a4</id>
<content type='text'>
[ Upstream commit 9aa3aa15f4c2f74f47afd6c5db4b420fadf3f315 ]

In lm80_probe(), if lm80_read_value() fails, it returns a negative
error number which is stored to data-&gt;fan[f_min] and will be further
used. We should avoid using the data if the read fails.

The fix checks if lm80_read_value() fails, and if so, returns with the
error number.

Signed-off-by: Kangjie Lu &lt;kjlu@umn.edu&gt;
Signed-off-by: Guenter Roeck &lt;linux@roeck-us.net&gt;
Signed-off-by: Sasha Levin &lt;sashal@kernel.org&gt;
</content>
</entry>
<entry>
<title>hwmon: (lm80) fix a missing check of the status of SMBus read</title>
<updated>2019-02-12T18:47:16+00:00</updated>
<author>
<name>Kangjie Lu</name>
<email>kjlu@umn.edu</email>
</author>
<published>2018-12-21T19:01:33+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=8dcf84789e311cedeb9782ff361e08808e5b2e8d'/>
<id>urn:sha1:8dcf84789e311cedeb9782ff361e08808e5b2e8d</id>
<content type='text'>
[ Upstream commit c9c63915519b1def7043b184680f33c24cd49d7b ]

If lm80_read_value() fails, it returns a negative number instead of the
correct read data. Therefore, we should avoid using the data if it
fails.

The fix checks if lm80_read_value() fails, and if so, returns with the
error number.

Signed-off-by: Kangjie Lu &lt;kjlu@umn.edu&gt;
[groeck: One variable for return values is enough]
Signed-off-by: Guenter Roeck &lt;linux@roeck-us.net&gt;
Signed-off-by: Sasha Levin &lt;sashal@kernel.org&gt;
</content>
</entry>
<entry>
<title>hwmon: (w83795) temp4_type has writable permission</title>
<updated>2018-12-17T08:24:33+00:00</updated>
<author>
<name>Huacai Chen</name>
<email>chenhc@lemote.com</email>
</author>
<published>2018-11-15T02:44:57+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=f3ff2ac4169ec3aa5777a3c1dbb03fb63080cb4a'/>
<id>urn:sha1:f3ff2ac4169ec3aa5777a3c1dbb03fb63080cb4a</id>
<content type='text'>
[ Upstream commit 09aaf6813cfca4c18034fda7a43e68763f34abb1 ]

Both datasheet and comments of store_temp_mode() tell us that temp1~4_type
is writable, so fix it.

Signed-off-by: Yao Wang &lt;wangyao@lemote.com&gt;
Signed-off-by: Huacai Chen &lt;chenhc@lemote.com&gt;
Fixes: 39deb6993e7c (" hwmon: (w83795) Simplify temperature sensor type handling")
Signed-off-by: Guenter Roeck &lt;linux@roeck-us.net&gt;
Signed-off-by: Sasha Levin &lt;sashal@kernel.org&gt;
</content>
</entry>
<entry>
<title>hwmon: (mlxreg-fan) Fix macros for tacho fault reading</title>
<updated>2018-12-17T08:24:32+00:00</updated>
<author>
<name>Vadim Pasternak</name>
<email>vadimp@mellanox.com</email>
</author>
<published>2018-11-16T13:47:11+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=0d4ff09997f32ea375b3e1bc512cd1c48c421756'/>
<id>urn:sha1:0d4ff09997f32ea375b3e1bc512cd1c48c421756</id>
<content type='text'>
[ Upstream commit 243cfe3fb8978c7eec24511aba7dac98819ed896 ]

Fix macros for tacometer fault reading.
This fix is relevant for three Mellanox systems MQMB7, MSN37, MSN34,
which are about to be released to the customers.
At the moment, none of them is at customers sites.

Fixes: 65afb4c8e7e4 ("hwmon: (mlxreg-fan) Add support for Mellanox FAN driver")
Signed-off-by: Vadim Pasternak &lt;vadimp@mellanox.com&gt;
Signed-off-by: Guenter Roeck &lt;linux@roeck-us.net&gt;
Signed-off-by: Sasha Levin &lt;sashal@kernel.org&gt;
</content>
</entry>
<entry>
<title>hwmon: (ina2xx) Fix current value calculation</title>
<updated>2018-12-17T08:24:32+00:00</updated>
<author>
<name>Nicolin Chen</name>
<email>nicoleotsuka@gmail.com</email>
</author>
<published>2018-11-14T03:48:54+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=3ef0d19cd8156fe122041cb47b3f9fc50ad743b5'/>
<id>urn:sha1:3ef0d19cd8156fe122041cb47b3f9fc50ad743b5</id>
<content type='text'>
[ Upstream commit 38cd989ee38c16388cde89db5b734f9d55b905f9 ]

The current register (04h) has a sign bit at MSB. The comments
for this calculation also mention that it's a signed register.

However, the regval is unsigned type so result of calculation
turns out to be an incorrect value when current is negative.

This patch simply fixes this by adding a casting to s16.

Fixes: 5d389b125186c ("hwmon: (ina2xx) Make calibration register value fixed")
Signed-off-by: Nicolin Chen &lt;nicoleotsuka@gmail.com&gt;
Signed-off-by: Guenter Roeck &lt;linux@roeck-us.net&gt;
Signed-off-by: Sasha Levin &lt;sashal@kernel.org&gt;
</content>
</entry>
<entry>
<title>hwmon: (raspberrypi) Fix initial notify</title>
<updated>2018-12-17T08:24:31+00:00</updated>
<author>
<name>Stefan Wahren</name>
<email>stefan.wahren@i2se.com</email>
</author>
<published>2018-11-11T12:01:11+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=dbc62bd3b05b772989de64421573f25552f5aead'/>
<id>urn:sha1:dbc62bd3b05b772989de64421573f25552f5aead</id>
<content type='text'>
[ Upstream commit 35fdc3902179366489a12cae4cb3ccc3b95f0afe ]

In case an under-voltage happens before probing the driver wont
write the critical warning into the kernel log. So don't init
of last_throttled during probe and fix this issue.

Fixes: 74d1e007915f ("hwmon: Add support for RPi voltage sensor")
Reported-by: "Noralf Trønnes" &lt;noralf@tronnes.org&gt;
Signed-off-by: Stefan Wahren &lt;stefan.wahren@i2se.com&gt;
Signed-off-by: Guenter Roeck &lt;linux@roeck-us.net&gt;
Signed-off-by: Sasha Levin &lt;sashal@kernel.org&gt;
</content>
</entry>
<entry>
<title>hwmon (ina2xx) Fix NULL id pointer in probe()</title>
<updated>2018-12-17T08:24:31+00:00</updated>
<author>
<name>Nicolin Chen</name>
<email>nicoleotsuka@gmail.com</email>
</author>
<published>2018-11-10T00:42:14+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=08cff35113e5ca6378b394a3566a4c7c86737bf2'/>
<id>urn:sha1:08cff35113e5ca6378b394a3566a4c7c86737bf2</id>
<content type='text'>
[ Upstream commit 70df9ebbd82c794ddfbb49d45b337f18d5588dc2 ]

When using DT configurations, the id pointer might turn out to
be NULL. Then the driver encounters NULL pointer access:

  Unable to handle kernel read from unreadable memory at vaddr 00000018
  [...]
  PC is at ina2xx_probe+0x114/0x200
  LR is at ina2xx_probe+0x10c/0x200
  [...]
  Kernel panic - not syncing: Attempted to kill init! exitcode=0x0000000b

The reason is that i2c core returns the id pointer by matching
id_table with client-&gt;name, while the client-&gt;name is actually
using the name from the first string in the DT compatible list,
not the best one. So i2c core would fail to match the id_table
if the best matched compatible string isn't the first one, and
then would return a NULL id pointer.

This probably should be fixed in i2c core. But it doesn't hurt
to make the driver robust. So this patch fixes it by using the
"chip" that's added to unify both DT and non-DT configurations.

Additionally, since id pointer could be null, so as id-&gt;name:
  ina2xx 10-0047: power monitor (null) (Rshunt = 1000 uOhm)
  ina2xx 10-0048: power monitor (null) (Rshunt = 10000 uOhm)

So this patch also fixes NULL name pointer, using client-&gt;name
to play safe and to align with hwmon-&gt;name.

Fixes: bd0ddd4d0883 ("hwmon: (ina2xx) Add OF device ID table")
Signed-off-by: Nicolin Chen &lt;nicoleotsuka@gmail.com&gt;
Signed-off-by: Guenter Roeck &lt;linux@roeck-us.net&gt;
Signed-off-by: Sasha Levin &lt;sashal@kernel.org&gt;
</content>
</entry>
</feed>
