Re: [PATCH 3/3] w1: ds2438: adding support for accessing page1 registers

2021-03-23 Thread Greg KH
On Mon, Mar 22, 2021 at 11:44:10PM -0300, Luiz Sampaio wrote: > @@ -395,6 +483,8 @@ static BIN_ATTR_RO(vdd, 0/* real length varies */); > static struct bin_attribute *w1_ds2438_bin_attrs[] = { > _attr_iad, > _attr_page0, > + _attr_page1, > + _attr_offset, You are adding new

[PATCH 3/3] w1: ds2438: adding support for accessing page1 registers

2021-03-22 Thread Luiz Sampaio
The ds2438 has a register in page1 called offset, which dictates how the current measurement is done. If the offset register is not calibrated well, pulling zero current from a battery shows a non-zero current measurement. Gives write access to the offset register. This way, a user following the