• Bartosz Golaszewski's avatar
    gpio: sim: add lockdep asserts · 11498d99
    Bartosz Golaszewski authored
    We have three functions in gpio-sim that are called with the device lock
    already held. We use the "_unlocked" suffix in their names to indicate
    that. This has proven to be confusing though as the naming convention in
    the kernel varies between using "_locked" or "_unlocked" for this
    purpose. Naming convention also doesn't enforce anything. Let's remove
    the suffix and add lockdep annotation at the top of these functions.
    
    This makes it clear the function requires a lock to be held (and which
    one specifically!) as well as results in a warning if it's not the case.
    The only place where the information is lost is the place where the
    function is called but the caller doesn't care about that information
    anyway.
    Signed-off-by: default avatarBartosz Golaszewski <bartosz.golaszewski@linaro.org>
    11498d99
gpio-sim.c 37.7 KB