• Michal Kazior's avatar
    ath10k: fix possible bmi crash · 04ed9dfe
    Michal Kazior authored
    While testing other things I've found that CE
    items aren't cleared properly. This could lead to
    null dereferences in BMI.
    
    To prevent that make sure CE revoking clears the
    nbytes value (which is used as a buffer completion
    indication) and memset the entire CE ring data
    shared between host and target when
    (re)initializing.
    
    Also make sure to check BMI xfer pointer and print
    a splat instead of crashing the kernel.
    Signed-off-by: default avatarMichal Kazior <michal.kazior@tieto.com>
    Signed-off-by: default avatarKalle Valo <kvalo@qca.qualcomm.com>
    04ed9dfe
ce.c 32.7 KB