• Ralf Baechle's avatar
    MIPS: Fix potencial corruption · b280aaa4
    Ralf Baechle authored
    commit a16dad77 upstream.
    
    Normally r4k_dma_cache_inv should only ever be called with cacheline
    aligned addresses.  If however, it isn't there is the theoretical
    possibility of data corruption.  There is no correct way of handling this
    and anyway, it should only happen if the DMA API is used incorrectly
    so drop
    
    There is a different corruption scenario with these CACHE instructions
    removed but again there is no way of handling this correctly and it can
    be triggered only through incorrect use of the DMA API.
    
    So just get rid of the complexity.
    Signed-off-by: default avatarRalf Baechle <ralf@linux-mips.org>
    Reported-by: default avatarJames Rodriguez <jamesr@juniper.net>
    Signed-off-by: default avatarBen Hutchings <ben@decadent.org.uk>
    b280aaa4
c-r4k.c 37.3 KB