lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  PHC 
Open Source and information security mailing list archives
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Date:   Thu, 8 Apr 2021 19:02:09 +0700
From:   Quan Nguyen <>
To:     Guenter Roeck <>, Joel Stanley <>,
        Andrew Jeffery <>,
        Jean Delvare <>,
        Rob Herring <>,
        Lee Jones <>,
        Jonathan Corbet <>,,,,,,
Cc:     Open Source Submission <>,
        Phong Vo <>,
        "Thang Q . Nguyen" <>
Subject: Re: [PATCH v2 3/4] hwmon: smpro: Add Ampere's Altra smpro-hwmon

On 07/04/2021 19:11, Guenter Roeck wrote:
> On 4/7/21 12:41 AM, Quan Nguyen wrote:
> [ ... ]
>>> But then why don't you just use reg_ext to store SOC_VR_HOT_THRESHOLD_REG
>>> or MEM_HOT_THRESHOLD_REG ? It is already available, after all, and with it
>>> the code could be simplified to
>>>          ret = regmap_read(hwmon->regmap, temperature[channel].reg_ext, &value);
>>>          if (ret)
>>>              return ret;
>> Thank you for the comment.
>> Will change code follow this suggestion, will include in next version
>>> I don't have a datasheet, but I do wonder what is in bit 9..15. Any idea ?
>>> Main question is if there is a sign bit, as theoretic as it may be.
>> The original intention was to use this as 9-bit 2-complement value follow LM75, but the fact is that the operation temperature is 0-125 C degree, so we simply use it as-is.
> The operational temperature is not the question here. The question is if the
> chip _reports_ a sign. If it does, it should be handled, even if it is outside
> the operational range. The reported range is relevant here, not the operational
> range. After all, the chip won't really blow apart at -1 degrees C.

I think I've got it, will handle the sign bit in next version.


Powered by blists - more mailing lists