• Christoph Hellwig's avatar
    [PATCH] get rid of ->detect for upper layer drivers · 4e5ba3ff
    Christoph Hellwig authored
    Okay, we're finally at the point where ->detect has become entirely
    superflous.  In sd, sr and st it does nothing but return different
    values that are ignored anyway, in sg it increments a variable
    that is never read (and thus removed in this patch aswell), only
    in osst it increments a variable that is actually checked for beeing
    non-zero.  But if it was zero we'd never reached that place anyway
    (same check in the beginning of osst_detect and osst_attach).
    
    This make the upper layer interface a lot nicer and avoids the
    race condition where a device is remove between detect and attach
    (which currently wouldn't matter anyway as we aren't doing anything
    in detect anymore)
    4e5ba3ff
sr.c 21.3 KB