1. 02 Sep, 2024 1 commit
    • Patrick Rudolph's avatar
      hwmon: pmbus: Implement generic bus access delay · 21d9e601
      Patrick Rudolph authored
      Some drivers, like the max15301 or zl6100, are intentionally delaying
      SMBus communications, to prevent transmission errors. As this is necessary
      on additional PMBus compatible devices, implement a generic delay mechanism
      in the pmbus core.
      
      Introduces two delay settings in the pmbus_driver_info struct, one applies
      to every SMBus transaction and the other is for write transaction only.
      Once set by the driver the SMBus traffic, using the generic pmbus access
      helpers, is automatically delayed when necessary.
      
      The two settings are:
      access_delay:
        - Unit in microseconds
        - Stores the accessed timestamp after every SMBus access
        - Delays when necessary before the next SMBus access
      
      write_delay:
        - Unit in microseconds
        - Stores the written timestamp after a write SMBus access
        - Delays when necessary before the next SMBus access
      
      This allows to drop the custom delay code from the drivers and easily
      introduce this feature in additional pmbus drivers.
      Signed-off-by: default avatarPatrick Rudolph <patrick.rudolph@9elements.com>
      Message-ID: <20240902075319.585656-1-patrick.rudolph@9elements.com>
      Signed-off-by: default avatarGuenter Roeck <linux@roeck-us.net>
      21d9e601
  2. 30 Aug, 2024 14 commits
  3. 29 Aug, 2024 1 commit
  4. 28 Aug, 2024 1 commit
    • Nathan Chancellor's avatar
      hwmon: (oxp-sensors) Add missing breaks to fix -Wimplicit-fallthrough with clang · 98845e77
      Nathan Chancellor authored
      clang warns (or errors due to CONFIG_WERROR):
      
        drivers/hwmon/oxp-sensors.c:481:3: error: unannotated fall-through between switch labels [-Werror,-Wimplicit-fallthrough]
        drivers/hwmon/oxp-sensors.c:553:3: error: unannotated fall-through between switch labels [-Werror,-Wimplicit-fallthrough]
        drivers/hwmon/oxp-sensors.c:556:2: error: unannotated fall-through between switch labels [-Werror,-Wimplicit-fallthrough]
        drivers/hwmon/oxp-sensors.c:607:3: error: unannotated fall-through between switch labels [-Werror,-Wimplicit-fallthrough]
      
      Clang is a little more pedantic than GCC, which does not warn when
      falling through to a case that is just break or return. Clang's version
      is more in line with the kernel's own stance in deprecated.rst, which
      states that all switch/case blocks must end in either break,
      fallthrough, continue, goto, or return. Add the missing breaks to
      silence the warnings.
      
      Fixes: b82b38a4 ("hwmon: (oxp-sensors) Add support for multiple new devices.")
      Signed-off-by: default avatarNathan Chancellor <nathan@kernel.org>
      Message-ID: <20240828-hwmon-oxp-sensors-fix-clang-implicit-fallthrough-v1-1-dc48496ac67a@kernel.org>
      Signed-off-by: default avatarGuenter Roeck <linux@roeck-us.net>
      98845e77
  5. 27 Aug, 2024 23 commits