Skip to content

Commit

Permalink
net: ipmr: remove unused MFC_NOTIFY flag and make the flags enum
Browse files Browse the repository at this point in the history
MFC_NOTIFY was introduced in kernel 2.1.68 but afaik it hasn't been used
and I couldn't find any users currently so just remove it. Only
MFC_STATIC is left, so move it into an enum, add a description and use
BIT().

Signed-off-by: Nikolay Aleksandrov <nikolay@cumulusnetworks.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
  • Loading branch information
Nikolay Aleksandrov authored and David S. Miller committed Nov 30, 2015
1 parent dfc3b0e commit 06bd6c0
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 5 deletions.
10 changes: 7 additions & 3 deletions include/linux/mroute.h
Original file line number Diff line number Diff line change
Expand Up @@ -64,6 +64,13 @@ struct vif_device {

#define VIFF_STATIC 0x8000

/* mfc_flags:
* MFC_STATIC - the entry was added statically (not by a routing daemon)
*/
enum {
MFC_STATIC = BIT(0),
};

struct mfc_cache {
struct list_head list;
__be32 mfc_mcastgrp; /* Group the entry belongs to */
Expand All @@ -89,9 +96,6 @@ struct mfc_cache {
struct rcu_head rcu;
};

#define MFC_STATIC 1
#define MFC_NOTIFY 2

#define MFC_LINES 64

#ifdef __BIG_ENDIAN
Expand Down
2 changes: 0 additions & 2 deletions net/ipv4/ipmr.c
Original file line number Diff line number Diff line change
Expand Up @@ -2199,8 +2199,6 @@ int ipmr_get_route(struct net *net, struct sk_buff *skb,
}

read_lock(&mrt_lock);
if (!nowait && (rtm->rtm_flags & RTM_F_NOTIFY))
cache->mfc_flags |= MFC_NOTIFY;
err = __ipmr_fill_mroute(mrt, skb, cache, rtm);
read_unlock(&mrt_lock);
rcu_read_unlock();
Expand Down

0 comments on commit 06bd6c0

Please sign in to comment.