Lines Matching defs:skb
29 static void (*llc_station_handler)(struct sk_buff *skb);
35 struct sk_buff *skb);
38 struct sk_buff *skb))
50 void llc_set_station_handler(void (*handler)(struct sk_buff *skb))
57 * @skb: input skb
61 static __inline__ int llc_pdu_type(struct sk_buff *skb)
64 struct llc_pdu_sn *pdu = llc_pdu_sn_hdr(skb);
89 * llc_fixup_skb - initializes skb pointers
90 * @skb: This argument points to incoming skb
92 * Initializes internal skb pointer to start of network layer by deriving
97 static inline int llc_fixup_skb(struct sk_buff *skb)
102 if (unlikely(!pskb_may_pull(skb, sizeof(*pdu))))
105 pdu = (struct llc_pdu_un *)skb->data;
110 if (unlikely(!pskb_may_pull(skb, llc_len)))
113 skb->transport_header += llc_len;
114 skb_pull(skb, llc_len);
115 if (skb->protocol == htons(ETH_P_802_2)) {
116 __be16 pdulen = eth_hdr(skb)->h_proto;
120 ((skb_tail_pointer(skb) -
123 if (unlikely(pskb_trim_rcsum(skb, data_size)))
131 * @skb: received pdu
141 int llc_rcv(struct sk_buff *skb, struct net_device *dev,
157 if (unlikely(skb->pkt_type == PACKET_OTHERHOST)) {
161 skb = skb_share_check(skb, GFP_ATOMIC);
162 if (unlikely(!skb))
164 if (unlikely(!llc_fixup_skb(skb)))
166 pdu = llc_pdu_sn_hdr(skb);
181 struct sk_buff *cskb = skb_clone(skb, GFP_ATOMIC);
185 dest = llc_pdu_type(skb);
188 llc_type_handlers[dest - 1](sap, skb);
194 kfree_skb(skb);
197 kfree_skb(skb);
202 llc_station_handler(skb);