Received: with ECARTIS (v1.0.0; list netdev); Wed, 03 Nov 2004 22:26:21 -0800 (PST) Received: from kaber.coreworks.de ([62.206.217.67]) by oss.sgi.com (8.13.0/8.13.0) with ESMTP id iA46QEsA008143 for ; Wed, 3 Nov 2004 22:26:14 -0800 Received: from localhost ([127.0.0.1] ident=kaber) by kaber.coreworks.de with esmtp (Exim 4.34) id 1CPb4C-00021w-IT; Thu, 04 Nov 2004 07:25:52 +0100 Message-ID: <4189CB70.3060703@trash.net> Date: Thu, 04 Nov 2004 07:25:52 +0100 From: Patrick McHardy User-Agent: Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv:1.7.3) Gecko/20041008 Debian/1.7.3-5 X-Accept-Language: en MIME-Version: 1.0 To: "David S. Miller" CC: netdev@oss.sgi.com, jamal Subject: [PATCH 2.6 5/5]: act_api: mark some functions static/remove unused function Content-Type: multipart/mixed; boundary="------------000304030001030906050804" X-archive-position: 11426 X-ecartis-version: Ecartis v1.0.0 Sender: netdev-bounce@oss.sgi.com Errors-to: netdev-bounce@oss.sgi.com X-original-sender: kaber@trash.net Precedence: bulk X-list: netdev Content-Length: 4010 Lines: 164 This is a multi-part message in MIME format. --------------000304030001030906050804 Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit Mark some functions static in act_api. tc_lookup_action_id was unused so I removed it. --------------000304030001030906050804 Content-Type: text/x-patch; name="5.diff" Content-Transfer-Encoding: 7bit Content-Disposition: inline; filename="5.diff" # This is a BitKeeper generated diff -Nru style patch. # # ChangeSet # 2004/11/04 06:45:26+01:00 kaber@coreworks.de # [PKT_SCHED]: act_api: mark some functions static/remove unused function # # Signed-off-by: Patrick McHardy # # net/sched/act_api.c # 2004/11/04 06:45:20+01:00 kaber@coreworks.de +11 -33 # [PKT_SCHED]: act_api: mark some functions static/remove unused function # # Signed-off-by: Patrick McHardy # diff -Nru a/net/sched/act_api.c b/net/sched/act_api.c --- a/net/sched/act_api.c 2004-11-04 07:17:32 +01:00 +++ b/net/sched/act_api.c 2004-11-04 07:17:32 +01:00 @@ -88,7 +88,7 @@ } /* lookup by name */ -struct tc_action_ops *tc_lookup_action_n(char *kind) +static struct tc_action_ops *tc_lookup_action_n(char *kind) { struct tc_action_ops *a = NULL; @@ -111,7 +111,7 @@ } /* lookup by rtattr */ -struct tc_action_ops *tc_lookup_action(struct rtattr *kind) +static struct tc_action_ops *tc_lookup_action(struct rtattr *kind) { struct tc_action_ops *a = NULL; @@ -134,28 +134,6 @@ return a; } -/* lookup by id */ -struct tc_action_ops *tc_lookup_action_id(u32 type) -{ - struct tc_action_ops *a = NULL; - - if (type) { - read_lock(&act_mod_lock); - for (a = act_base; a; a = a->next) { - if (a->type == type) { - if (!try_module_get(a->owner)) { - read_unlock(&act_mod_lock); - return NULL; - } - break; - } - } - read_unlock(&act_mod_lock); - } - - return a; -} - int tcf_action_exec(struct sk_buff *skb,struct tc_action *act, struct tcf_result *res) { @@ -504,7 +482,7 @@ return err; } -int tcf_action_get_1(struct rtattr *rta, struct tc_action *a, struct nlmsghdr *n, u32 pid) +static int tcf_action_get_1(struct rtattr *rta, struct tc_action *a, struct nlmsghdr *n, u32 pid) { struct tc_action_ops *a_o; char act_name[4 + IFNAMSIZ + 1]; @@ -571,7 +549,7 @@ return err; } -void cleanup_a (struct tc_action *act) +static void cleanup_a (struct tc_action *act) { struct tc_action *a; @@ -587,7 +565,7 @@ } } -struct tc_action_ops *get_ao(struct rtattr *kind, struct tc_action *a) +static struct tc_action_ops *get_ao(struct rtattr *kind, struct tc_action *a) { char act_name[4 + IFNAMSIZ + 1]; struct tc_action_ops *a_o = NULL; @@ -622,7 +600,7 @@ return a_o; } -struct tc_action *create_a(int i) +static struct tc_action *create_a(int i) { struct tc_action *act = NULL; @@ -639,7 +617,7 @@ return act; } -int tca_action_flush(struct rtattr *rta, struct nlmsghdr *n, u32 pid) +static int tca_action_flush(struct rtattr *rta, struct nlmsghdr *n, u32 pid) { struct sk_buff *skb; unsigned char *b; @@ -709,7 +687,7 @@ return err; } -int tca_action_gd(struct rtattr *rta, struct nlmsghdr *n, u32 pid, int event ) +static int tca_action_gd(struct rtattr *rta, struct nlmsghdr *n, u32 pid, int event ) { int s = 0; @@ -793,7 +771,7 @@ } -int tcf_add_notify(struct tc_action *a, u32 pid, u32 seq, int event, unsigned flags) +static int tcf_add_notify(struct tc_action *a, u32 pid, u32 seq, int event, unsigned flags) { struct tcamsg *t; struct nlmsghdr *nlh; @@ -840,7 +818,7 @@ } -int tcf_action_add(struct rtattr *rta, struct nlmsghdr *n, u32 pid, int ovr ) +static int tcf_action_add(struct rtattr *rta, struct nlmsghdr *n, u32 pid, int ovr ) { int ret = 0; struct tc_action *act = NULL; @@ -923,7 +901,7 @@ return ret; } -char * +static char * find_dump_kind(struct nlmsghdr *n) { struct rtattr *tb1, *tb2[TCA_ACT_MAX+1]; --------------000304030001030906050804--