summaryrefslogtreecommitdiffstats
path: root/drivers/net/ethernet/netronome/nfp/flower/metadata.c
diff options
context:
space:
mode:
authorJohn Hurley <john.hurley@netronome.com>2017-09-25 12:23:35 +0200
committerDavid S. Miller <davem@davemloft.net>2017-09-27 06:27:35 +0200
commit79ede4ae2d01b0282bfaaf761308a5ac485c8144 (patch)
treefd2a157e0391cb0e258c9bfa549fad08ce0ff5aa /drivers/net/ethernet/netronome/nfp/flower/metadata.c
parentMerge branch 'mlxsw-pass-gact' (diff)
downloadlinux-79ede4ae2d01b0282bfaaf761308a5ac485c8144.tar.xz
linux-79ede4ae2d01b0282bfaaf761308a5ac485c8144.zip
nfp: add helper to get flower cmsg length
Add a helper function that returns the length of the cmsg data when given the cmsg skb Signed-off-by: John Hurley <john.hurley@netronome.com> Signed-off-by: Simon Horman <simon.horman@netronome.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/ethernet/netronome/nfp/flower/metadata.c')
-rw-r--r--drivers/net/ethernet/netronome/nfp/flower/metadata.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/net/ethernet/netronome/nfp/flower/metadata.c b/drivers/net/ethernet/netronome/nfp/flower/metadata.c
index 3226ddc55f99..193520ef23f0 100644
--- a/drivers/net/ethernet/netronome/nfp/flower/metadata.c
+++ b/drivers/net/ethernet/netronome/nfp/flower/metadata.c
@@ -140,7 +140,7 @@ exit_rcu_unlock:
void nfp_flower_rx_flow_stats(struct nfp_app *app, struct sk_buff *skb)
{
- unsigned int msg_len = skb->len - NFP_FLOWER_CMSG_HLEN;
+ unsigned int msg_len = nfp_flower_cmsg_get_data_len(skb);
struct nfp_fl_stats_frame *stats_frame;
unsigned char *msg;
int i;