From mboxrd@z Thu Jan 1 00:00:00 1970 From: Craig Dillabaugh Subject: [PATCH net-next 1/2] net sched: Implemented get_fill_size routine for act_csum. Date: Tue, 1 May 2018 10:17:43 -0400 Message-ID: <1525184264-9436-2-git-send-email-cdillaba@mojatatu.com> References: <1525184264-9436-1-git-send-email-cdillaba@mojatatu.com> Cc: netdev@vger.kernel.org, jhs@mojatatu.com, xiyou.wangcong@gmail.com, Craig Dillabaugh To: davem@davemloft.net Return-path: Received: from mail-it0-f67.google.com ([209.85.214.67]:34459 "EHLO mail-it0-f67.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1755729AbeEAOSC (ORCPT ); Tue, 1 May 2018 10:18:02 -0400 Received: by mail-it0-f67.google.com with SMTP id c5-v6so11481282itj.1 for ; Tue, 01 May 2018 07:18:02 -0700 (PDT) In-Reply-To: <1525184264-9436-1-git-send-email-cdillaba@mojatatu.com> Sender: netdev-owner@vger.kernel.org List-ID: Signed-off-by: Craig Dillabaugh --- net/sched/act_csum.c | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/net/sched/act_csum.c b/net/sched/act_csum.c index 7e28b2c..b85e088 100644 --- a/net/sched/act_csum.c +++ b/net/sched/act_csum.c @@ -648,6 +648,11 @@ static int tcf_csum_search(struct net *net, struct tc_action **a, u32 index, return tcf_idr_search(tn, a, index); } +static size_t tcf_csum_get_fill_size(const struct tc_action *act) +{ + return nla_total_size(sizeof(struct tc_csum)); +} + static struct tc_action_ops act_csum_ops = { .kind = "csum", .type = TCA_ACT_CSUM, @@ -658,6 +663,7 @@ static int tcf_csum_search(struct net *net, struct tc_action **a, u32 index, .cleanup = tcf_csum_cleanup, .walk = tcf_csum_walker, .lookup = tcf_csum_search, + .get_fill_size = tcf_csum_get_fill_size, .size = sizeof(struct tcf_csum), }; -- 1.9.1