• Guenter Roeck's avatar
    sbs-battery: make writes to ManufacturerAccess optional · 17c6d397
    Guenter Roeck authored
    According to the Smart Battery Data Specification, the use
    of ManufacturerAcess (register 0x0) is implementation-defined.
    It appears that some batteries use writes to this register
    in order to implement certain functionality, but others may
    simply NAK all writes to it. As a result, write failures to
    ManufacturerAccess should not be used as an indicator of
    battery presence, nor as a failure to enter sleep mode.
    
    The failed write access was seen with SANYO AP13J3K.
    
    Cc: Brian Norris <briannorris@chromium.org>
    Signed-off-by: default avatarGuenter Roeck <linux@roeck-us.net>
    Signed-off-by: default avatarSebastian Reichel <sre@kernel.org>
    17c6d397
sbs-battery.c 23.4 KB