• Mika Westerberg's avatar
    thunderbolt: Make tb_switch_alloc() return ERR_PTR() · 444ac384
    Mika Westerberg authored
    In order to detect possible connections to other domains we need to be
    able to find out why tb_switch_alloc() fails so make it return ERR_PTR()
    instead. This allows the caller to differentiate between errors such as
    -ENOMEM which comes from the kernel and for instance -EIO which comes
    from the hardware when trying to access the possible switch.
    
    Convert all the current call sites to handle this properly.
    Signed-off-by: default avatarMika Westerberg <mika.westerberg@linux.intel.com>
    444ac384
icm.c 50 KB