29 Oct, 2018

5 commits


04 Oct, 2018

2 commits

  • [ Upstream commit f196dec6d50abb2e65fb54a0621b2f1b4d922995 ]

    The adt7475_read_word() function was meant to return negative error
    codes on failure.

    Signed-off-by: Dan Carpenter
    Reviewed-by: Tokunori Ikegami
    Signed-off-by: Guenter Roeck
    Signed-off-by: Sasha Levin
    Signed-off-by: Greg Kroah-Hartman

    Dan Carpenter
     
  • [ Upstream commit 3ad867001c91657c46dcf6656d52eb6080286fd5 ]

    fix the sysfs shunt resistor read access: return the shunt resistor
    value, not the calibration register contents.

    update email address

    Signed-off-by: Lothar Felten
    Signed-off-by: Guenter Roeck
    Signed-off-by: Sasha Levin
    Signed-off-by: Greg Kroah-Hartman

    Lothar Felten
     

05 Sep, 2018

1 commit

  • commit d49dbfade96d5b0863ca8a90122a805edd5ef50a upstream.

    val can be indirectly controlled by user-space, hence leading to
    a potential exploitation of the Spectre variant 1 vulnerability.

    This issue was detected with the help of Smatch:

    vers/hwmon/nct6775.c:2698 store_pwm_weight_temp_sel() warn: potential
    spectre issue 'data->temp_src' [r]

    Fix this by sanitizing val before using it to index data->temp_src

    Notice that given that speculation windows are large, the policy is
    to kill the speculation on the first load and not worry if it can be
    completed with a dependent load/store [1].

    [1] https://marc.info/?l=linux-kernel&m=152449131114778&w=2

    Cc: stable@vger.kernel.org
    Signed-off-by: Gustavo A. R. Silva
    Signed-off-by: Guenter Roeck
    Signed-off-by: Greg Kroah-Hartman

    Gustavo A. R. Silva
     

24 Aug, 2018

1 commit

  • [ Upstream commit 91bb8f45f73f19a0150c233c0f11cdeb6d71d1e9 ]

    Commit cc66b3038254 ("hwmon: (nct6775) Rework temperature source and label
    handling") changed a loop limit from "data->temp_label_num - 1" to "32",
    as part of moving from a string array to a bit mask. This results in the
    following error, reported by UBSAN.

    UBSAN: Undefined behaviour in drivers/hwmon/nct6775.c:4179:27
    shift exponent 32 is too large for 32-bit type 'long unsigned int'

    Similar to the original loop, the limit has to be one less than the
    number of bits.

    Fixes: cc66b3038254 ("hwmon: (nct6775) Rework temperature source and label handling")
    Reported-by: Paul Menzel
    Cc: Paul Menzel
    Tested-by: Paul Menzel
    Signed-off-by: Guenter Roeck
    Signed-off-by: Sasha Levin
    Signed-off-by: Greg Kroah-Hartman

    Guenter Roeck
     

30 May, 2018

3 commits

  • [ Upstream commit ecb29abd4cb0670c616fb563a078f25d777ce530 ]

    A negative page register value means that no page needs to be
    selected. This is used by status register read operations and needs
    to be accepted. The failure to do so so results in missed status
    and limit registers.

    Fixes: da8e48ab483e1 ("hwmon: (pmbus) Always call _pmbus_read_byte in core driver")
    Signed-off-by: Guenter Roeck
    Signed-off-by: Sasha Levin
    Signed-off-by: Greg Kroah-Hartman

    Guenter Roeck
     
  • [ Upstream commit a46f8cd696624ef757be0311eb28f119c36778e8 ]

    A negative page register value means that no page needs to be
    selected. This is used by status register evaluations and needs
    to be accepted.

    Fixes: da8e48ab483e1 ("hwmon: (pmbus) Always call _pmbus_read_byte in core driver")
    Signed-off-by: Guenter Roeck
    Signed-off-by: Sasha Levin
    Signed-off-by: Greg Kroah-Hartman

    Guenter Roeck
     
  • [ Upstream commit 415eb2a1aaa4881cf85bd86c683356fdd8094a23 ]

    pwmX_mode is defined in the ABI as 0=DC mode, 1=pwm mode. The chip
    register bit is set to 1 for DC mode. This got mixed up, and writing
    1 into pwmX_mode resulted in DC mode enabled. Fix it up by using
    the ABI definition throughout the driver for consistency.

    Fixes: 77eb5b3703d99 ("hwmon: (nct6775) Add support for pwm, pwm_mode, ... ")
    Signed-off-by: Guenter Roeck
    Signed-off-by: Sasha Levin
    Signed-off-by: Greg Kroah-Hartman

    Guenter Roeck
     

19 Apr, 2018

1 commit

  • commit 0c4c5860e9983eb3da7a3d73ca987643c3ed034b upstream.

    Initialize data->config_lock mutex before it is used by the driver code.

    This fixes following warning on Odroid XU3 boards:

    INFO: trying to register non-static key.
    the code is fine but needs lockdep annotation.
    turning off the locking correctness validator.
    CPU: 5 PID: 1 Comm: swapper/0 Not tainted 4.15.0-rc7-next-20180115-00001-gb75575dee3f2 #107
    Hardware name: SAMSUNG EXYNOS (Flattened Device Tree)
    [] (unwind_backtrace) from [] (show_stack+0x10/0x14)
    [] (show_stack) from [] (dump_stack+0x90/0xc8)
    [] (dump_stack) from [] (register_lock_class+0x1c0/0x59c)
    [] (register_lock_class) from [] (__lock_acquire+0x78/0x1850)
    [] (__lock_acquire) from [] (lock_acquire+0xc8/0x2b8)
    [] (lock_acquire) from [] (__mutex_lock+0x60/0xa0c)
    [] (__mutex_lock) from [] (mutex_lock_nested+0x1c/0x24)
    [] (mutex_lock_nested) from [] (ina2xx_set_shunt+0x70/0xb0)
    [] (ina2xx_set_shunt) from [] (ina2xx_probe+0x88/0x1b0)
    [] (ina2xx_probe) from [] (i2c_device_probe+0x1e0/0x2d0)
    [] (i2c_device_probe) from [] (driver_probe_device+0x2b8/0x4a0)
    [] (driver_probe_device) from [] (__driver_attach+0xfc/0x120)
    [] (__driver_attach) from [] (bus_for_each_dev+0x58/0x7c)
    [] (bus_for_each_dev) from [] (bus_add_driver+0x174/0x250)
    [] (bus_add_driver) from [] (driver_register+0x78/0xf4)
    [] (driver_register) from [] (i2c_register_driver+0x38/0xa8)
    [] (i2c_register_driver) from [] (do_one_initcall+0x48/0x18c)
    [] (do_one_initcall) from [] (kernel_init_freeable+0x110/0x1d4)
    [] (kernel_init_freeable) from [] (kernel_init+0x8/0x114)
    [] (kernel_init) from [] (ret_from_fork+0x14/0x20)

    Fixes: 5d389b125186 ("hwmon: (ina2xx) Make calibration register value fixed")
    Signed-off-by: Marek Szyprowski
    Signed-off-by: Guenter Roeck
    Signed-off-by: Greg Kroah-Hartman

    Marek Szyprowski
     

12 Apr, 2018

1 commit

  • [ Upstream commit 5d389b125186cf254ad5b8015763ac07c151aea4 ]

    Calibration register is used for calculating current register in
    hardware according to datasheet:
    current = shunt_volt * calib_register / 2048 (ina 226)
    current = shunt_volt * calib_register / 4096 (ina 219)

    Fix calib_register value to 2048 for ina226 and 4096 for ina 219 in
    order to avoid truncation error and provide best precision allowed
    by shunt_voltage measurement. Make current scale value follow changes
    of shunt_resistor from sysfs as calib_register value is now fixed.

    Power_lsb value should also follow shunt_resistor changes as stated in
    datasheet:
    power_lsb = 25 * current_lsb (ina 226)
    power_lsb = 20 * current_lsb (ina 219)

    Signed-off-by: Maciej Purski
    Signed-off-by: Guenter Roeck
    Signed-off-by: Sasha Levin
    Signed-off-by: Greg Kroah-Hartman

    Maciej Purski
     

22 Feb, 2018

1 commit

  • commit b399151cb48db30ad1e0e93dd40d68c6d007b637 upstream.

    x86_mask is a confusing name which is hard to associate with the
    processor's stepping.

    Additionally, correct an indent issue in lib/cpu.c.

    Signed-off-by: Jia Zhang
    [ Updated it to more recent kernels. ]
    Cc: Linus Torvalds
    Cc: Peter Zijlstra
    Cc: Thomas Gleixner
    Cc: bp@alien8.de
    Cc: tony.luck@intel.com
    Link: http://lkml.kernel.org/r/1514771530-70829-1-git-send-email-qianyue.zj@alibaba-inc.com
    Signed-off-by: Ingo Molnar
    Signed-off-by: Greg Kroah-Hartman

    Jia Zhang
     

04 Feb, 2018

1 commit

  • [ Upstream commit bd467e4eababe4c04272c1e646f066db02734c79 ]

    Power values in the 100s of watt range can easily blow past
    32bit math limits when processing everything in microwatts.

    Use 64bit math instead to avoid these issues on common 32bit ARM
    BMC platforms.

    Fixes: 442aba78728e ("hwmon: PMBus device driver")
    Signed-off-by: Robert Lippert
    Signed-off-by: Guenter Roeck
    Signed-off-by: Sasha Levin
    Signed-off-by: Greg Kroah-Hartman

    Robert Lippert
     

10 Dec, 2017

1 commit

  • [ Upstream commit 6dcf2fb5e8db3704f50af1f198256cb4e2453f8b ]

    The pmbus core may call read/write word data functions with a page value
    of -1, intending to perform the operation without setting the page.
    However, the read/write word data functions accept only unsigned 8-bit
    page numbers, and therefore cannot check for negative page number to
    avoid setting the page. This results in setting the page number to 0xFF.
    This may result in errors or undefined behavior of some devices
    (specifically the ir35221, which allows the page to be set to 0xFF,
    but some subsequent operations to read registers may fail).

    Switch the pmbus_set_page page parameter to an integer and perform the
    check for negative page there. Make read/write functions consistent in
    accepting an integer page number parameter.

    Signed-off-by: Edward A. James
    Fixes: cbcdec6202c9 ("hwmon: (pmbus): Access word data for STATUS_WORD")
    Signed-off-by: Guenter Roeck
    Signed-off-by: Sasha Levin
    Signed-off-by: Greg Kroah-Hartman

    Edward A. James
     

05 Dec, 2017

1 commit

  • commit 68615eb01f82256c19e41967bfb3eef902f77033 upstream.

    With a nxp,se97 chip on an atmel sama5d31 board, the I2C adapter driver
    is not always capable of avoiding the 25-35 ms timeout as specified by
    the SMBUS protocol. This may cause silent corruption of the last bit of
    any transfer, e.g. a one is read instead of a zero if the sensor chip
    times out. This also affects the eeprom half of the nxp-se97 chip, where
    this silent corruption was originally noticed. Other I2C adapters probably
    suffer similar issues, e.g. bit-banging comes to mind as risky...

    The SMBUS register in the nxp chip is not a standard Jedec register, but
    it is not special to the nxp chips either, at least the atmel chips
    have the same mechanism. Therefore, do not special case this on the
    manufacturer, it is opt-in via the device property anyway.

    Signed-off-by: Peter Rosin
    Acked-by: Rob Herring
    Signed-off-by: Guenter Roeck
    Signed-off-by: Greg Kroah-Hartman

    Peter Rosin
     

03 Nov, 2017

1 commit

  • …el/git/gregkh/driver-core

    Pull initial SPDX identifiers from Greg KH:
    "License cleanup: add SPDX license identifiers to some files

    Many source files in the tree are missing licensing information, which
    makes it harder for compliance tools to determine the correct license.

    By default all files without license information are under the default
    license of the kernel, which is GPL version 2.

    Update the files which contain no license information with the
    'GPL-2.0' SPDX license identifier. The SPDX identifier is a legally
    binding shorthand, which can be used instead of the full boiler plate
    text.

    This patch is based on work done by Thomas Gleixner and Kate Stewart
    and Philippe Ombredanne.

    How this work was done:

    Patches were generated and checked against linux-4.14-rc6 for a subset
    of the use cases:

    - file had no licensing information it it.

    - file was a */uapi/* one with no licensing information in it,

    - file was a */uapi/* one with existing licensing information,

    Further patches will be generated in subsequent months to fix up cases
    where non-standard license headers were used, and references to
    license had to be inferred by heuristics based on keywords.

    The analysis to determine which SPDX License Identifier to be applied
    to a file was done in a spreadsheet of side by side results from of
    the output of two independent scanners (ScanCode & Windriver)
    producing SPDX tag:value files created by Philippe Ombredanne.
    Philippe prepared the base worksheet, and did an initial spot review
    of a few 1000 files.

    The 4.13 kernel was the starting point of the analysis with 60,537
    files assessed. Kate Stewart did a file by file comparison of the
    scanner results in the spreadsheet to determine which SPDX license
    identifier(s) to be applied to the file. She confirmed any
    determination that was not immediately clear with lawyers working with
    the Linux Foundation.

    Criteria used to select files for SPDX license identifier tagging was:

    - Files considered eligible had to be source code files.

    - Make and config files were included as candidates if they contained
    >5 lines of source

    - File already had some variant of a license header in it (even if <5
    lines).

    All documentation files were explicitly excluded.

    The following heuristics were used to determine which SPDX license
    identifiers to apply.

    - when both scanners couldn't find any license traces, file was
    considered to have no license information in it, and the top level
    COPYING file license applied.

    For non */uapi/* files that summary was:

    SPDX license identifier # files
    ---------------------------------------------------|-------
    GPL-2.0 11139

    and resulted in the first patch in this series.

    If that file was a */uapi/* path one, it was "GPL-2.0 WITH
    Linux-syscall-note" otherwise it was "GPL-2.0". Results of that
    was:

    SPDX license identifier # files
    ---------------------------------------------------|-------
    GPL-2.0 WITH Linux-syscall-note 930

    and resulted in the second patch in this series.

    - if a file had some form of licensing information in it, and was one
    of the */uapi/* ones, it was denoted with the Linux-syscall-note if
    any GPL family license was found in the file or had no licensing in
    it (per prior point). Results summary:

    SPDX license identifier # files
    ---------------------------------------------------|------
    GPL-2.0 WITH Linux-syscall-note 270
    GPL-2.0+ WITH Linux-syscall-note 169
    ((GPL-2.0 WITH Linux-syscall-note) OR BSD-2-Clause) 21
    ((GPL-2.0 WITH Linux-syscall-note) OR BSD-3-Clause) 17
    LGPL-2.1+ WITH Linux-syscall-note 15
    GPL-1.0+ WITH Linux-syscall-note 14
    ((GPL-2.0+ WITH Linux-syscall-note) OR BSD-3-Clause) 5
    LGPL-2.0+ WITH Linux-syscall-note 4
    LGPL-2.1 WITH Linux-syscall-note 3
    ((GPL-2.0 WITH Linux-syscall-note) OR MIT) 3
    ((GPL-2.0 WITH Linux-syscall-note) AND MIT) 1

    and that resulted in the third patch in this series.

    - when the two scanners agreed on the detected license(s), that
    became the concluded license(s).

    - when there was disagreement between the two scanners (one detected
    a license but the other didn't, or they both detected different
    licenses) a manual inspection of the file occurred.

    - In most cases a manual inspection of the information in the file
    resulted in a clear resolution of the license that should apply
    (and which scanner probably needed to revisit its heuristics).

    - When it was not immediately clear, the license identifier was
    confirmed with lawyers working with the Linux Foundation.

    - If there was any question as to the appropriate license identifier,
    the file was flagged for further research and to be revisited later
    in time.

    In total, over 70 hours of logged manual review was done on the
    spreadsheet to determine the SPDX license identifiers to apply to the
    source files by Kate, Philippe, Thomas and, in some cases,
    confirmation by lawyers working with the Linux Foundation.

    Kate also obtained a third independent scan of the 4.13 code base from
    FOSSology, and compared selected files where the other two scanners
    disagreed against that SPDX file, to see if there was new insights.
    The Windriver scanner is based on an older version of FOSSology in
    part, so they are related.

    Thomas did random spot checks in about 500 files from the spreadsheets
    for the uapi headers and agreed with SPDX license identifier in the
    files he inspected. For the non-uapi files Thomas did random spot
    checks in about 15000 files.

    In initial set of patches against 4.14-rc6, 3 files were found to have
    copy/paste license identifier errors, and have been fixed to reflect
    the correct identifier.

    Additionally Philippe spent 10 hours this week doing a detailed manual
    inspection and review of the 12,461 patched files from the initial
    patch version early this week with:

    - a full scancode scan run, collecting the matched texts, detected
    license ids and scores

    - reviewing anything where there was a license detected (about 500+
    files) to ensure that the applied SPDX license was correct

    - reviewing anything where there was no detection but the patch
    license was not GPL-2.0 WITH Linux-syscall-note to ensure that the
    applied SPDX license was correct

    This produced a worksheet with 20 files needing minor correction. This
    worksheet was then exported into 3 different .csv files for the
    different types of files to be modified.

    These .csv files were then reviewed by Greg. Thomas wrote a script to
    parse the csv files and add the proper SPDX tag to the file, in the
    format that the file expected. This script was further refined by Greg
    based on the output to detect more types of files automatically and to
    distinguish between header and source .c files (which need different
    comment types.) Finally Greg ran the script using the .csv files to
    generate the patches.

    Reviewed-by: Kate Stewart <kstewart@linuxfoundation.org>
    Reviewed-by: Philippe Ombredanne <pombredanne@nexb.com>
    Reviewed-by: Thomas Gleixner <tglx@linutronix.de>
    Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>"

    * tag 'spdx_identifiers-4.14-rc8' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/driver-core:
    License cleanup: add SPDX license identifier to uapi header files with a license
    License cleanup: add SPDX license identifier to uapi header files with no license
    License cleanup: add SPDX GPL-2.0 license identifier to files with no license

    Linus Torvalds
     

02 Nov, 2017

1 commit

  • Many source files in the tree are missing licensing information, which
    makes it harder for compliance tools to determine the correct license.

    By default all files without license information are under the default
    license of the kernel, which is GPL version 2.

    Update the files which contain no license information with the 'GPL-2.0'
    SPDX license identifier. The SPDX identifier is a legally binding
    shorthand, which can be used instead of the full boiler plate text.

    This patch is based on work done by Thomas Gleixner and Kate Stewart and
    Philippe Ombredanne.

    How this work was done:

    Patches were generated and checked against linux-4.14-rc6 for a subset of
    the use cases:
    - file had no licensing information it it.
    - file was a */uapi/* one with no licensing information in it,
    - file was a */uapi/* one with existing licensing information,

    Further patches will be generated in subsequent months to fix up cases
    where non-standard license headers were used, and references to license
    had to be inferred by heuristics based on keywords.

    The analysis to determine which SPDX License Identifier to be applied to
    a file was done in a spreadsheet of side by side results from of the
    output of two independent scanners (ScanCode & Windriver) producing SPDX
    tag:value files created by Philippe Ombredanne. Philippe prepared the
    base worksheet, and did an initial spot review of a few 1000 files.

    The 4.13 kernel was the starting point of the analysis with 60,537 files
    assessed. Kate Stewart did a file by file comparison of the scanner
    results in the spreadsheet to determine which SPDX license identifier(s)
    to be applied to the file. She confirmed any determination that was not
    immediately clear with lawyers working with the Linux Foundation.

    Criteria used to select files for SPDX license identifier tagging was:
    - Files considered eligible had to be source code files.
    - Make and config files were included as candidates if they contained >5
    lines of source
    - File already had some variant of a license header in it (even if
    Reviewed-by: Philippe Ombredanne
    Reviewed-by: Thomas Gleixner
    Signed-off-by: Greg Kroah-Hartman

    Greg Kroah-Hartman
     

24 Oct, 2017

1 commit

  • Commit 3d8f7a89a197 ("hwmon: (tmp102) Improve handling of initial read
    delay") reduced the initial temperature read delay and made it dependent
    on the chip's shutdown mode. If the chip was not in shutdown mode at probe,
    the read delay no longer applies.

    This ignores the fact that the chip initialization changes the temperature
    sensor resolution, and that the temperature register values change when
    the resolution is changed. As a result, the reported temperature is twice
    as high as the real temperature until the first temperature conversion
    after the configuration change is complete. This can result in unexpected
    behavior and, worst case, in a system shutdown. To fix the problem,
    let's just always wait for a conversion to complete before reporting
    a temperature.

    Fixes: 3d8f7a89a197 ("hwmon: (tmp102) Improve handling of initial read delay")
    Link: https://bugzilla.kernel.org/show_bug.cgi?id=197167
    Reported-by: Ralf Goebel
    Cc: Ralf Goebel
    Reviewed-by: Jean Delvare
    Signed-off-by: Guenter Roeck

    Guenter Roeck
     

22 Oct, 2017

1 commit

  • The TSI channel, which is usually used for touchscreen support, but can
    be used as 4 general purpose ADCs. When used as a touchscreen interface
    the touchscreen driver switches the device into 1ms sampling mode (rather
    than the default 10ms economy mode) as recommended by the manufacturer.
    When using the TSI channels as a general purpose ADC we are currently not
    doing this and testing suggests that this can result in ADC timeouts:

    [ 5827.198289] da9052 spi2.0: timeout waiting for ADC conversion interrupt
    [ 5827.728293] da9052 spi2.0: timeout waiting for ADC conversion interrupt
    [ 5993.808335] da9052 spi2.0: timeout waiting for ADC conversion interrupt
    [ 5994.328441] da9052 spi2.0: timeout waiting for ADC conversion interrupt
    [ 5994.848291] da9052 spi2.0: timeout waiting for ADC conversion interrupt

    Switching to the 1ms timing resolves this issue.

    Fixes: 4f16cab19a3d5 ("hwmon: da9052: Add support for TSI channel")
    Signed-off-by: Martyn Welch
    Acked-by: Steve Twiss
    Signed-off-by: Guenter Roeck

    Martyn Welch
     

01 Oct, 2017

1 commit

  • Commit 2ca492e22cb7 has moved the call to 'kfifo_alloc()' from after the
    main 'if' statement to before it.
    But it has not updated the error handling paths accordingly.

    Fix all that:
    - if 'kfifo_alloc()' fails we can return directly
    - direct returns after 'kfifo_alloc()' must now go to 'out_mbox_free'
    - 'goto out_mbox_free' must be replaced by 'goto out', otherwise the
    '[pcc_]mbox_free_channel()' call will be missed.

    Fixes: 2ca492e22cb7 ("hwmon: (xgene) Fix crash when alarm occurs before driver probe")
    Signed-off-by: Christophe JAILLET
    Signed-off-by: Guenter Roeck

    Christophe Jaillet
     

14 Sep, 2017

1 commit


01 Sep, 2017

1 commit


31 Aug, 2017

1 commit


30 Aug, 2017

7 commits


22 Aug, 2017

2 commits


15 Aug, 2017

2 commits

  • With CONFIG_THERMAL=m, a built-in aspeed pwm tacho driver causes
    a link error:

    drivers/hwmon/aspeed-pwm-tacho.o: In function `aspeed_pwm_tacho_probe':
    aspeed-pwm-tacho.c:(.text+0x7f0): undefined reference to `thermal_of_cooling_device_register'

    This adds a dependency similar to what other hwmon drivers use,
    ensuring that the aspeed driver cannot be built-in in this
    case but has to be a module. With THERMAL=n, we still allow building it.

    Fixes: 2d7a548a3eff ("drivers: hwmon: Support for ASPEED PWM/Fan tach")
    Signed-off-by: Arnd Bergmann
    Signed-off-by: Guenter Roeck

    Arnd Bergmann
     
  • Export all the available status registers through debugfs. This is
    useful for hardware diagnostics, especially on multi-page pmbus devices,
    as user-space access of the i2c space could corrupt the pmbus page
    accounting.

    Signed-off-by: Edward A. James
    Signed-off-by: Guenter Roeck

    Edward A. James
     

13 Aug, 2017

3 commits

  • Add support in aspeed-pwm-tacho driver for cooling device creation.
    This cooling device could be bound to a thermal zone
    for the thermal control. Device will appear in /sys/class/thermal
    folder as cooling_deviceX. Then it could be bound to particular
    thermal zones. Allow specification of the cooling levels
    vector - PWM duty cycle values in a range from 0 to 255
    which correspond to thermal cooling states.

    Signed-off-by: Mykola Kostenok
    Reviewed-by: Joel Stanley
    Signed-off-by: Guenter Roeck

    Mykola Kostenok
     
  • Add PB_STATUS_INPUT as the generic alarm bit for iin and pin. We also
    need to redo the status register checking before setting up the boolean
    attribute, since it won't necessarily check STATUS_WORD if the device
    doesn't support it, which we need for this bit.

    Signed-off-by: Edward A. James
    Signed-off-by: Guenter Roeck

    Edward A. James
     
  • Pmbus always reads byte data from the status register, even if
    configured to use STATUS_WORD. Use a function pointer to read the
    correct amount of data from the registers.
    Also switch to try STATUS_WORD first before STATUS_BYTE on init.

    Signed-off-by: Edward A. James
    Signed-off-by: Guenter Roeck

    Edward A. James