• Lee Jones's avatar
    mfd: htc-i2cpld: Rectify pointer offset error · 9b6a5ad9
    Lee Jones authored
    Checking the result of container_of() against NULL will always result to
    false.  Using the offset of member 'chip_out' to find the start of 'struct
    htcpld_chip' will result in an offset error when .get_chip() is attempting
    to obtain 'htcpld-in'.  Instead, we'll use the correct member based on a
    previously the set chip label.
    Signed-off-by: default avatarLee Jones <lee.jones@linaro.org>
    9b6a5ad9
htc-i2cpld.c 17.5 KB