aboutsummaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@linux-foundation.org>2014-10-07 20:39:25 -0400
committerLinus Torvalds <torvalds@linux-foundation.org>2014-10-07 20:39:25 -0400
commitd0cd84817c745655428dbfdb1e3f754230b46bef (patch)
treea7b6f422f6ac50f506ffa7a66f8e83387f90f212 /include
parentbdf428feb225229b1d4715b45bbdad4a934cd89c (diff)
parent3f334078567245429540e6461c81c749fce87f70 (diff)
Merge tag 'dmaengine-3.17' of git://git.kernel.org/pub/scm/linux/kernel/git/djbw/dmaengine
Pull dmaengine updates from Dan Williams: "Even though this has fixes marked for -stable, given the size and the needed conflict resolutions this is 3.18-rc1/merge-window material. These patches have been languishing in my tree for a long while. The fact that I do not have the time to do proper/prompt maintenance of this tree is a primary factor in the decision to step down as dmaengine maintainer. That and the fact that the bulk of drivers/dma/ activity is going through Vinod these days. The net_dma removal has not been in -next. It has developed simple conflicts against mainline and net-next (for-3.18). Continuing thanks to Vinod for staying on top of drivers/dma/. Summary: 1/ Step down as dmaengine maintainer see commit 08223d80df38 "dmaengine maintainer update" 2/ Removal of net_dma, as it has been marked 'broken' since 3.13 (commit 77873803363c "net_dma: mark broken"), without reports of performance regression. 3/ Miscellaneous fixes" * tag 'dmaengine-3.17' of git://git.kernel.org/pub/scm/linux/kernel/git/djbw/dmaengine: net: make tcp_cleanup_rbuf private net_dma: revert 'copied_early' net_dma: simple removal dmaengine maintainer update dmatest: prevent memory leakage on error path in thread ioat: Use time_before_jiffies() dmaengine: fix xor sources continuation dma: mv_xor: Rename __mv_xor_slot_cleanup() to mv_xor_slot_cleanup() dma: mv_xor: Remove all callers of mv_xor_slot_cleanup() dma: mv_xor: Remove unneeded mv_xor_clean_completed_slots() call ioat: Use pci_enable_msix_exact() instead of pci_enable_msix() drivers: dma: Include appropriate header file in dca.c drivers: dma: Mark functions as static in dma_v3.c dma: mv_xor: Add DMA API error checks ioat/dca: Use dev_is_pci() to check whether it is pci device
Diffstat (limited to 'include')
-rw-r--r--include/linux/dmaengine.h22
-rw-r--r--include/linux/skbuff.h8
-rw-r--r--include/linux/tcp.h8
-rw-r--r--include/net/netdma.h32
-rw-r--r--include/net/sock.h19
-rw-r--r--include/net/tcp.h9
6 files changed, 4 insertions, 94 deletions
diff --git a/include/linux/dmaengine.h b/include/linux/dmaengine.h
index 1f9e642c66ad..212c5b9ac106 100644
--- a/include/linux/dmaengine.h
+++ b/include/linux/dmaengine.h
@@ -900,18 +900,6 @@ static inline void dmaengine_put(void)
900} 900}
901#endif 901#endif
902 902
903#ifdef CONFIG_NET_DMA
904#define net_dmaengine_get() dmaengine_get()
905#define net_dmaengine_put() dmaengine_put()
906#else
907static inline void net_dmaengine_get(void)
908{
909}
910static inline void net_dmaengine_put(void)
911{
912}
913#endif
914
915#ifdef CONFIG_ASYNC_TX_DMA 903#ifdef CONFIG_ASYNC_TX_DMA
916#define async_dmaengine_get() dmaengine_get() 904#define async_dmaengine_get() dmaengine_get()
917#define async_dmaengine_put() dmaengine_put() 905#define async_dmaengine_put() dmaengine_put()
@@ -933,16 +921,8 @@ async_dma_find_channel(enum dma_transaction_type type)
933 return NULL; 921 return NULL;
934} 922}
935#endif /* CONFIG_ASYNC_TX_DMA */ 923#endif /* CONFIG_ASYNC_TX_DMA */
936
937dma_cookie_t dma_async_memcpy_buf_to_buf(struct dma_chan *chan,
938 void *dest, void *src, size_t len);
939dma_cookie_t dma_async_memcpy_buf_to_pg(struct dma_chan *chan,
940 struct page *page, unsigned int offset, void *kdata, size_t len);
941dma_cookie_t dma_async_memcpy_pg_to_pg(struct dma_chan *chan,
942 struct page *dest_pg, unsigned int dest_off, struct page *src_pg,
943 unsigned int src_off, size_t len);
944void dma_async_tx_descriptor_init(struct dma_async_tx_descriptor *tx, 924void dma_async_tx_descriptor_init(struct dma_async_tx_descriptor *tx,
945 struct dma_chan *chan); 925 struct dma_chan *chan);
946 926
947static inline void async_tx_ack(struct dma_async_tx_descriptor *tx) 927static inline void async_tx_ack(struct dma_async_tx_descriptor *tx)
948{ 928{
diff --git a/include/linux/skbuff.h b/include/linux/skbuff.h
index abde271c18ae..a17ba0881afb 100644
--- a/include/linux/skbuff.h
+++ b/include/linux/skbuff.h
@@ -28,7 +28,6 @@
28#include <linux/textsearch.h> 28#include <linux/textsearch.h>
29#include <net/checksum.h> 29#include <net/checksum.h>
30#include <linux/rcupdate.h> 30#include <linux/rcupdate.h>
31#include <linux/dmaengine.h>
32#include <linux/hrtimer.h> 31#include <linux/hrtimer.h>
33#include <linux/dma-mapping.h> 32#include <linux/dma-mapping.h>
34#include <linux/netdev_features.h> 33#include <linux/netdev_features.h>
@@ -581,11 +580,8 @@ struct sk_buff {
581 /* 2/4 bit hole (depending on ndisc_nodetype presence) */ 580 /* 2/4 bit hole (depending on ndisc_nodetype presence) */
582 kmemcheck_bitfield_end(flags2); 581 kmemcheck_bitfield_end(flags2);
583 582
584#if defined CONFIG_NET_DMA || defined CONFIG_NET_RX_BUSY_POLL 583#ifdef CONFIG_NET_RX_BUSY_POLL
585 union { 584 unsigned int napi_id;
586 unsigned int napi_id;
587 dma_cookie_t dma_cookie;
588 };
589#endif 585#endif
590#ifdef CONFIG_NETWORK_SECMARK 586#ifdef CONFIG_NETWORK_SECMARK
591 __u32 secmark; 587 __u32 secmark;
diff --git a/include/linux/tcp.h b/include/linux/tcp.h
index fa5258f322e7..ac82c5ea955b 100644
--- a/include/linux/tcp.h
+++ b/include/linux/tcp.h
@@ -19,7 +19,6 @@
19 19
20 20
21#include <linux/skbuff.h> 21#include <linux/skbuff.h>
22#include <linux/dmaengine.h>
23#include <net/sock.h> 22#include <net/sock.h>
24#include <net/inet_connection_sock.h> 23#include <net/inet_connection_sock.h>
25#include <net/inet_timewait_sock.h> 24#include <net/inet_timewait_sock.h>
@@ -166,13 +165,6 @@ struct tcp_sock {
166 struct iovec *iov; 165 struct iovec *iov;
167 int memory; 166 int memory;
168 int len; 167 int len;
169#ifdef CONFIG_NET_DMA
170 /* members for async copy */
171 struct dma_chan *dma_chan;
172 int wakeup;
173 struct dma_pinned_list *pinned_list;
174 dma_cookie_t dma_cookie;
175#endif
176 } ucopy; 168 } ucopy;
177 169
178 u32 snd_wl1; /* Sequence for window update */ 170 u32 snd_wl1; /* Sequence for window update */
diff --git a/include/net/netdma.h b/include/net/netdma.h
deleted file mode 100644
index 8ba8ce284eeb..000000000000
--- a/include/net/netdma.h
+++ /dev/null
@@ -1,32 +0,0 @@
1/*
2 * Copyright(c) 2004 - 2006 Intel Corporation. All rights reserved.
3 *
4 * This program is free software; you can redistribute it and/or modify it
5 * under the terms of the GNU General Public License as published by the Free
6 * Software Foundation; either version 2 of the License, or (at your option)
7 * any later version.
8 *
9 * This program is distributed in the hope that it will be useful, but WITHOUT
10 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
11 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for
12 * more details.
13 *
14 * You should have received a copy of the GNU General Public License along with
15 * this program; if not, write to the Free Software Foundation, Inc., 59
16 * Temple Place - Suite 330, Boston, MA 02111-1307, USA.
17 *
18 * The full GNU General Public License is included in this distribution in the
19 * file called COPYING.
20 */
21#ifndef NETDMA_H
22#define NETDMA_H
23#ifdef CONFIG_NET_DMA
24#include <linux/dmaengine.h>
25#include <linux/skbuff.h>
26
27int dma_skb_copy_datagram_iovec(struct dma_chan* chan,
28 struct sk_buff *skb, int offset, struct iovec *to,
29 size_t len, struct dma_pinned_list *pinned_list);
30
31#endif /* CONFIG_NET_DMA */
32#endif /* NETDMA_H */
diff --git a/include/net/sock.h b/include/net/sock.h
index b9a5bd0ed9f3..591e607cca35 100644
--- a/include/net/sock.h
+++ b/include/net/sock.h
@@ -233,7 +233,6 @@ struct cg_proto;
233 * @sk_receive_queue: incoming packets 233 * @sk_receive_queue: incoming packets
234 * @sk_wmem_alloc: transmit queue bytes committed 234 * @sk_wmem_alloc: transmit queue bytes committed
235 * @sk_write_queue: Packet sending queue 235 * @sk_write_queue: Packet sending queue
236 * @sk_async_wait_queue: DMA copied packets
237 * @sk_omem_alloc: "o" is "option" or "other" 236 * @sk_omem_alloc: "o" is "option" or "other"
238 * @sk_wmem_queued: persistent queue size 237 * @sk_wmem_queued: persistent queue size
239 * @sk_forward_alloc: space allocated forward 238 * @sk_forward_alloc: space allocated forward
@@ -362,10 +361,6 @@ struct sock {
362 struct sk_filter __rcu *sk_filter; 361 struct sk_filter __rcu *sk_filter;
363 struct socket_wq __rcu *sk_wq; 362 struct socket_wq __rcu *sk_wq;
364 363
365#ifdef CONFIG_NET_DMA
366 struct sk_buff_head sk_async_wait_queue;
367#endif
368
369#ifdef CONFIG_XFRM 364#ifdef CONFIG_XFRM
370 struct xfrm_policy *sk_policy[2]; 365 struct xfrm_policy *sk_policy[2];
371#endif 366#endif
@@ -2206,27 +2201,15 @@ void sock_tx_timestamp(const struct sock *sk, __u8 *tx_flags);
2206 * sk_eat_skb - Release a skb if it is no longer needed 2201 * sk_eat_skb - Release a skb if it is no longer needed
2207 * @sk: socket to eat this skb from 2202 * @sk: socket to eat this skb from
2208 * @skb: socket buffer to eat 2203 * @skb: socket buffer to eat
2209 * @copied_early: flag indicating whether DMA operations copied this data early
2210 * 2204 *
2211 * This routine must be called with interrupts disabled or with the socket 2205 * This routine must be called with interrupts disabled or with the socket
2212 * locked so that the sk_buff queue operation is ok. 2206 * locked so that the sk_buff queue operation is ok.
2213*/ 2207*/
2214#ifdef CONFIG_NET_DMA 2208static inline void sk_eat_skb(struct sock *sk, struct sk_buff *skb)
2215static inline void sk_eat_skb(struct sock *sk, struct sk_buff *skb, bool copied_early)
2216{
2217 __skb_unlink(skb, &sk->sk_receive_queue);
2218 if (!copied_early)
2219 __kfree_skb(skb);
2220 else
2221 __skb_queue_tail(&sk->sk_async_wait_queue, skb);
2222}
2223#else
2224static inline void sk_eat_skb(struct sock *sk, struct sk_buff *skb, bool copied_early)
2225{ 2209{
2226 __skb_unlink(skb, &sk->sk_receive_queue); 2210 __skb_unlink(skb, &sk->sk_receive_queue);
2227 __kfree_skb(skb); 2211 __kfree_skb(skb);
2228} 2212}
2229#endif
2230 2213
2231static inline 2214static inline
2232struct net *sock_net(const struct sock *sk) 2215struct net *sock_net(const struct sock *sk)
diff --git a/include/net/tcp.h b/include/net/tcp.h
index 590e01a476ac..7523c325673e 100644
--- a/include/net/tcp.h
+++ b/include/net/tcp.h
@@ -27,7 +27,6 @@
27#include <linux/cache.h> 27#include <linux/cache.h>
28#include <linux/percpu.h> 28#include <linux/percpu.h>
29#include <linux/skbuff.h> 29#include <linux/skbuff.h>
30#include <linux/dmaengine.h>
31#include <linux/crypto.h> 30#include <linux/crypto.h>
32#include <linux/cryptohash.h> 31#include <linux/cryptohash.h>
33#include <linux/kref.h> 32#include <linux/kref.h>
@@ -262,7 +261,6 @@ extern int sysctl_tcp_adv_win_scale;
262extern int sysctl_tcp_tw_reuse; 261extern int sysctl_tcp_tw_reuse;
263extern int sysctl_tcp_frto; 262extern int sysctl_tcp_frto;
264extern int sysctl_tcp_low_latency; 263extern int sysctl_tcp_low_latency;
265extern int sysctl_tcp_dma_copybreak;
266extern int sysctl_tcp_nometrics_save; 264extern int sysctl_tcp_nometrics_save;
267extern int sysctl_tcp_moderate_rcvbuf; 265extern int sysctl_tcp_moderate_rcvbuf;
268extern int sysctl_tcp_tso_win_divisor; 266extern int sysctl_tcp_tso_win_divisor;
@@ -368,7 +366,6 @@ int tcp_rcv_state_process(struct sock *sk, struct sk_buff *skb,
368void tcp_rcv_established(struct sock *sk, struct sk_buff *skb, 366void tcp_rcv_established(struct sock *sk, struct sk_buff *skb,
369 const struct tcphdr *th, unsigned int len); 367 const struct tcphdr *th, unsigned int len);
370void tcp_rcv_space_adjust(struct sock *sk); 368void tcp_rcv_space_adjust(struct sock *sk);
371void tcp_cleanup_rbuf(struct sock *sk, int copied);
372int tcp_twsk_unique(struct sock *sk, struct sock *sktw, void *twp); 369int tcp_twsk_unique(struct sock *sk, struct sock *sktw, void *twp);
373void tcp_twsk_destructor(struct sock *sk); 370void tcp_twsk_destructor(struct sock *sk);
374ssize_t tcp_splice_read(struct socket *sk, loff_t *ppos, 371ssize_t tcp_splice_read(struct socket *sk, loff_t *ppos,
@@ -1031,12 +1028,6 @@ static inline void tcp_prequeue_init(struct tcp_sock *tp)
1031 tp->ucopy.len = 0; 1028 tp->ucopy.len = 0;
1032 tp->ucopy.memory = 0; 1029 tp->ucopy.memory = 0;
1033 skb_queue_head_init(&tp->ucopy.prequeue); 1030 skb_queue_head_init(&tp->ucopy.prequeue);
1034#ifdef CONFIG_NET_DMA
1035 tp->ucopy.dma_chan = NULL;
1036 tp->ucopy.wakeup = 0;
1037 tp->ucopy.pinned_list = NULL;
1038 tp->ucopy.dma_cookie = 0;
1039#endif
1040} 1031}
1041 1032
1042bool tcp_prequeue(struct sock *sk, struct sk_buff *skb); 1033bool tcp_prequeue(struct sock *sk, struct sk_buff *skb);