Merge master.kernel.org:/pub/scm/linux/kernel/git/davem/net-2.6
This commit is contained in:
@@ -958,7 +958,7 @@ static __inline__ int ip_vs_todrop(void)
|
||||
*/
|
||||
#define IP_VS_FWD_METHOD(cp) (cp->flags & IP_VS_CONN_F_FWD_MASK)
|
||||
|
||||
extern __inline__ char ip_vs_fwd_tag(struct ip_vs_conn *cp)
|
||||
static inline char ip_vs_fwd_tag(struct ip_vs_conn *cp)
|
||||
{
|
||||
char fwd;
|
||||
|
||||
|
@@ -709,6 +709,12 @@ static inline int sk_stream_rmem_schedule(struct sock *sk, struct sk_buff *skb)
|
||||
sk_stream_mem_schedule(sk, skb->truesize, 1);
|
||||
}
|
||||
|
||||
static inline int sk_stream_wmem_schedule(struct sock *sk, int size)
|
||||
{
|
||||
return size <= sk->sk_forward_alloc ||
|
||||
sk_stream_mem_schedule(sk, size, 0);
|
||||
}
|
||||
|
||||
/* Used by processes to "lock" a socket state, so that
|
||||
* interrupts and bottom half handlers won't change it
|
||||
* from under us. It essentially blocks any incoming
|
||||
@@ -1203,8 +1209,7 @@ static inline struct sk_buff *sk_stream_alloc_pskb(struct sock *sk,
|
||||
skb = alloc_skb_fclone(size + hdr_len, gfp);
|
||||
if (skb) {
|
||||
skb->truesize += mem;
|
||||
if (sk->sk_forward_alloc >= (int)skb->truesize ||
|
||||
sk_stream_mem_schedule(sk, skb->truesize, 0)) {
|
||||
if (sk_stream_wmem_schedule(sk, skb->truesize)) {
|
||||
skb_reserve(skb, hdr_len);
|
||||
return skb;
|
||||
}
|
||||
@@ -1227,10 +1232,8 @@ static inline struct page *sk_stream_alloc_page(struct sock *sk)
|
||||
{
|
||||
struct page *page = NULL;
|
||||
|
||||
if (sk->sk_forward_alloc >= (int)PAGE_SIZE ||
|
||||
sk_stream_mem_schedule(sk, PAGE_SIZE, 0))
|
||||
page = alloc_pages(sk->sk_allocation, 0);
|
||||
else {
|
||||
page = alloc_pages(sk->sk_allocation, 0);
|
||||
if (!page) {
|
||||
sk->sk_prot->enter_memory_pressure();
|
||||
sk_stream_moderate_sndbuf(sk);
|
||||
}
|
||||
|
@@ -454,6 +454,7 @@ extern int tcp_retransmit_skb(struct sock *, struct sk_buff *);
|
||||
extern void tcp_xmit_retransmit_queue(struct sock *);
|
||||
extern void tcp_simple_retransmit(struct sock *);
|
||||
extern int tcp_trim_head(struct sock *, struct sk_buff *, u32);
|
||||
extern int tcp_fragment(struct sock *, struct sk_buff *, u32, unsigned int);
|
||||
|
||||
extern void tcp_send_probe0(struct sock *);
|
||||
extern void tcp_send_partial(struct sock *);
|
||||
|
Reference in New Issue
Block a user