• Frans Klaver's avatar
    mtd: core: tone down suggestion that dev.parent should be set · 260e89a6
    Frans Klaver authored
    add_mtd_device() has a comment suggesting that the caller should have
    set dev.parent. This is required to have the parent device symlink show
    up in sysfs, but not for proper operation of the mtd device itself.
    Currently we have five drivers registering mtd devices during module
    initialization, so they don't actually provide a parent device to link
    to. That means we cannot WARN_ON() here, as it would trigger false
    positives.
    
    Make the comment a bit less firm in its assertion that dev.parent should
    be set.
    Signed-off-by: default avatarFrans Klaver <fransklaver@gmail.com>
    Signed-off-by: default avatarBrian Norris <computersforpeace@gmail.com>
    260e89a6
mtdcore.c 33.7 KB