summaryrefslogtreecommitdiffstats
path: root/net/llc
diff options
context:
space:
mode:
Diffstat (limited to 'net/llc')
-rw-r--r--net/llc/llc_input.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/net/llc/llc_input.c b/net/llc/llc_input.c
index d62e0f9..cb9f7f0 100644
--- a/net/llc/llc_input.c
+++ b/net/llc/llc_input.c
@@ -142,6 +142,8 @@ int llc_rcv(struct sk_buff *skb, struct net_device *dev,
struct llc_sap *sap;
struct llc_pdu_sn *pdu;
int dest;
+ int (*rcv)(struct sk_buff *, struct net_device *,
+ struct packet_type *, struct net_device *);
/*
* When the interface is in promisc. mode, drop all the crap that it
@@ -169,8 +171,9 @@ int llc_rcv(struct sk_buff *skb, struct net_device *dev,
* First the upper layer protocols that don't need the full
* LLC functionality
*/
- if (sap->rcv_func) {
- sap->rcv_func(skb, dev, pt, orig_dev);
+ rcv = rcu_dereference(sap->rcv_func);
+ if (rcv) {
+ rcv(skb, dev, pt, orig_dev);
goto out_put;
}
dest = llc_pdu_type(skb);
OpenPOWER on IntegriCloud