• Dirk Eibach's avatar
    gpio/pca953x: Fix wrong pointer type · 1648237d
    Dirk Eibach authored
    pca953x_get_alt_pdata() uses uint16_t* as result type for
    of_get_property(), but numeric of values are __be32.
    
    Checking for negative values is bogus because of-property
    values are unsigned by definition.
    Instead check for proper property size.
    
    v3: - assume big-endian properties
        - check property size
    v2: - removed bogus check for negative property values
    Signed-off-by: default avatarDirk Eibach <eibach@gdsys.de>
    Signed-off-by: default avatarGrant Likely <grant.likely@secretlab.ca>
    1648237d
pca953x.c 13.8 KB