• Jakub Kicinski's avatar
    devlink: add device information API · f9cf2288
    Jakub Kicinski authored
    ethtool -i has served us well for a long time, but its showing
    its limitations more and more. The device information should
    also be reported per device not per-netdev.
    
    Lay foundation for a simple devlink-based way of reading device
    info. Add driver name and device serial number as initial pieces
    of information exposed via this new API.
    
    v3:
     - rename helpers (Jiri);
     - rename driver name attr (Jiri);
     - remove double spacing in commit message (Jiri).
    RFC v2:
     - wrap the skb into an opaque structure (Jiri);
     - allow the serial number of be any length (Jiri & Andrew);
     - add driver name (Jonathan).
    Signed-off-by: default avatarJakub Kicinski <jakub.kicinski@netronome.com>
    Acked-by: default avatarJiri Pirko <jiri@mellanox.com>
    Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
    f9cf2288
devlink.c 134 KB