spi-topcliff-pch: Fix issue for transmitting over 4KByte
[zen-stable.git] / net / core / kmap_skb.h
blob81e1ed7c838396e9e18a772447304284dbe81d5a
1 #include <linux/highmem.h>
3 static inline void *kmap_skb_frag(const skb_frag_t *frag)
5 #ifdef CONFIG_HIGHMEM
6 BUG_ON(in_irq());
8 local_bh_disable();
9 #endif
10 return kmap_atomic(skb_frag_page(frag), KM_SKB_DATA_SOFTIRQ);
13 static inline void kunmap_skb_frag(void *vaddr)
15 kunmap_atomic(vaddr, KM_SKB_DATA_SOFTIRQ);
16 #ifdef CONFIG_HIGHMEM
17 local_bh_enable();
18 #endif