• Jeremy Kerr's avatar
    net: mctp: tests: create test skbs with the correct net and device · a1f4cf57
    Jeremy Kerr authored
    In our test skb creation functions, we're not setting up the net and
    device data. This doesn't matter at the moment, but we will want to add
    support for distinct net IDs in future.
    
    Set the ->net identifier on the test MCTP device, and ensure that test
    skbs are set up with the correct device-related data on creation. Create
    a helper for setting skb->dev and mctp_skb_cb->net.
    
    We have a few cases where we're calling __mctp_cb() to initialise the cb
    (which we need for the above) separately, so integrate this into the skb
    creation helpers.
    Signed-off-by: default avatarJeremy Kerr <jk@codeconstruct.com.au>
    Signed-off-by: default avatarPaolo Abeni <pabeni@redhat.com>
    a1f4cf57
utils.c 1.35 KB