• Vivien Didelot's avatar
    net: switchdev: pass callback to dump operation · 25f07adc
    Vivien Didelot authored
    Similar to the notifier_call callback of a notifier_block, change the
    function signature of switchdev dump operation to:
    
        int switchdev_port_obj_dump(struct net_device *dev,
                                    enum switchdev_obj_id id, void *obj,
                                    int (*cb)(void *obj));
    
    This allows the caller to pass and expect back a specific
    switchdev_obj_* structure instead of the generic switchdev_obj one.
    
    Drivers implementation of dump operation can now expect this specific
    structure and call the callback with it. Drivers have been changed
    accordingly.
    Signed-off-by: default avatarVivien Didelot <vivien.didelot@savoirfairelinux.com>
    Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
    25f07adc
rocker.c 146 KB