diff options
Diffstat (limited to 'net')
-rw-r--r-- | net/core/pktgen.c | 27 | ||||
-rw-r--r-- | net/ipv4/tcp_output.c | 10 | ||||
-rw-r--r-- | net/mac80211/rc80211_minstrel_debugfs.c | 6 | ||||
-rw-r--r-- | net/phonet/af_phonet.c | 5 | ||||
-rw-r--r-- | net/rfkill/rfkill-input.c | 5 |
5 files changed, 30 insertions, 23 deletions
diff --git a/net/core/pktgen.c b/net/core/pktgen.c index 99f656d35b4f..a47f5bad110d 100644 --- a/net/core/pktgen.c +++ b/net/core/pktgen.c | |||
@@ -1973,28 +1973,27 @@ static void pktgen_setup_inject(struct pktgen_dev *pkt_dev) | |||
1973 | 1973 | ||
1974 | /* make sure that we don't pick a non-existing transmit queue */ | 1974 | /* make sure that we don't pick a non-existing transmit queue */ |
1975 | ntxq = pkt_dev->odev->real_num_tx_queues; | 1975 | ntxq = pkt_dev->odev->real_num_tx_queues; |
1976 | if (ntxq <= num_online_cpus() && (pkt_dev->flags & F_QUEUE_MAP_CPU)) { | 1976 | if (ntxq > num_online_cpus() && (pkt_dev->flags & F_QUEUE_MAP_CPU)) { |
1977 | printk(KERN_WARNING "pktgen: WARNING: QUEUE_MAP_CPU " | 1977 | printk(KERN_WARNING "pktgen: WARNING: QUEUE_MAP_CPU " |
1978 | "disabled because CPU count (%d) exceeds number ", | 1978 | "disabled because CPU count (%d) exceeds number " |
1979 | num_online_cpus()); | 1979 | "of tx queues (%d) on %s\n", num_online_cpus(), ntxq, |
1980 | printk(KERN_WARNING "pktgen: WARNING: of tx queues " | 1980 | pkt_dev->odev->name); |
1981 | "(%d) on %s \n", ntxq, pkt_dev->odev->name); | ||
1982 | pkt_dev->flags &= ~F_QUEUE_MAP_CPU; | 1981 | pkt_dev->flags &= ~F_QUEUE_MAP_CPU; |
1983 | } | 1982 | } |
1984 | if (ntxq <= pkt_dev->queue_map_min) { | 1983 | if (ntxq <= pkt_dev->queue_map_min) { |
1985 | printk(KERN_WARNING "pktgen: WARNING: Requested " | 1984 | printk(KERN_WARNING "pktgen: WARNING: Requested " |
1986 | "queue_map_min (%d) exceeds number of tx\n", | 1985 | "queue_map_min (zero-based) (%d) exceeds valid range " |
1987 | pkt_dev->queue_map_min); | 1986 | "[0 - %d] for (%d) queues on %s, resetting\n", |
1988 | printk(KERN_WARNING "pktgen: WARNING: queues (%d) on " | 1987 | pkt_dev->queue_map_min, (ntxq ?: 1)- 1, ntxq, |
1989 | "%s, resetting\n", ntxq, pkt_dev->odev->name); | 1988 | pkt_dev->odev->name); |
1990 | pkt_dev->queue_map_min = ntxq - 1; | 1989 | pkt_dev->queue_map_min = ntxq - 1; |
1991 | } | 1990 | } |
1992 | if (ntxq <= pkt_dev->queue_map_max) { | 1991 | if (pkt_dev->queue_map_max >= ntxq) { |
1993 | printk(KERN_WARNING "pktgen: WARNING: Requested " | 1992 | printk(KERN_WARNING "pktgen: WARNING: Requested " |
1994 | "queue_map_max (%d) exceeds number of tx\n", | 1993 | "queue_map_max (zero-based) (%d) exceeds valid range " |
1995 | pkt_dev->queue_map_max); | 1994 | "[0 - %d] for (%d) queues on %s, resetting\n", |
1996 | printk(KERN_WARNING "pktgen: WARNING: queues (%d) on " | 1995 | pkt_dev->queue_map_max, (ntxq ?: 1)- 1, ntxq, |
1997 | "%s, resetting\n", ntxq, pkt_dev->odev->name); | 1996 | pkt_dev->odev->name); |
1998 | pkt_dev->queue_map_max = ntxq - 1; | 1997 | pkt_dev->queue_map_max = ntxq - 1; |
1999 | } | 1998 | } |
2000 | 1999 | ||
diff --git a/net/ipv4/tcp_output.c b/net/ipv4/tcp_output.c index e4c5ac9fe89b..ba85d8831893 100644 --- a/net/ipv4/tcp_output.c +++ b/net/ipv4/tcp_output.c | |||
@@ -2279,6 +2279,11 @@ struct sk_buff *tcp_make_synack(struct sock *sk, struct dst_entry *dst, | |||
2279 | } | 2279 | } |
2280 | 2280 | ||
2281 | memset(&opts, 0, sizeof(opts)); | 2281 | memset(&opts, 0, sizeof(opts)); |
2282 | #ifdef CONFIG_SYN_COOKIES | ||
2283 | if (unlikely(req->cookie_ts)) | ||
2284 | TCP_SKB_CB(skb)->when = cookie_init_timestamp(req); | ||
2285 | else | ||
2286 | #endif | ||
2282 | TCP_SKB_CB(skb)->when = tcp_time_stamp; | 2287 | TCP_SKB_CB(skb)->when = tcp_time_stamp; |
2283 | tcp_header_size = tcp_synack_options(sk, req, mss, | 2288 | tcp_header_size = tcp_synack_options(sk, req, mss, |
2284 | skb, &opts, &md5) + | 2289 | skb, &opts, &md5) + |
@@ -2304,11 +2309,6 @@ struct sk_buff *tcp_make_synack(struct sock *sk, struct dst_entry *dst, | |||
2304 | 2309 | ||
2305 | /* RFC1323: The window in SYN & SYN/ACK segments is never scaled. */ | 2310 | /* RFC1323: The window in SYN & SYN/ACK segments is never scaled. */ |
2306 | th->window = htons(min(req->rcv_wnd, 65535U)); | 2311 | th->window = htons(min(req->rcv_wnd, 65535U)); |
2307 | #ifdef CONFIG_SYN_COOKIES | ||
2308 | if (unlikely(req->cookie_ts)) | ||
2309 | TCP_SKB_CB(skb)->when = cookie_init_timestamp(req); | ||
2310 | else | ||
2311 | #endif | ||
2312 | tcp_options_write((__be32 *)(th + 1), tp, &opts, &md5_hash_location); | 2312 | tcp_options_write((__be32 *)(th + 1), tp, &opts, &md5_hash_location); |
2313 | th->doff = (tcp_header_size >> 2); | 2313 | th->doff = (tcp_header_size >> 2); |
2314 | TCP_INC_STATS(sock_net(sk), TCP_MIB_OUTSEGS); | 2314 | TCP_INC_STATS(sock_net(sk), TCP_MIB_OUTSEGS); |
diff --git a/net/mac80211/rc80211_minstrel_debugfs.c b/net/mac80211/rc80211_minstrel_debugfs.c index 0b024cd6b809..98f480708050 100644 --- a/net/mac80211/rc80211_minstrel_debugfs.c +++ b/net/mac80211/rc80211_minstrel_debugfs.c | |||
@@ -94,8 +94,8 @@ minstrel_stats_open(struct inode *inode, struct file *file) | |||
94 | prob / 10, prob % 10, | 94 | prob / 10, prob % 10, |
95 | mr->last_success, | 95 | mr->last_success, |
96 | mr->last_attempts, | 96 | mr->last_attempts, |
97 | mr->succ_hist, | 97 | (unsigned long long)mr->succ_hist, |
98 | mr->att_hist); | 98 | (unsigned long long)mr->att_hist); |
99 | } | 99 | } |
100 | p += sprintf(p, "\nTotal packet count:: ideal %d " | 100 | p += sprintf(p, "\nTotal packet count:: ideal %d " |
101 | "lookaround %d\n\n", | 101 | "lookaround %d\n\n", |
@@ -106,7 +106,7 @@ minstrel_stats_open(struct inode *inode, struct file *file) | |||
106 | return 0; | 106 | return 0; |
107 | } | 107 | } |
108 | 108 | ||
109 | static int | 109 | static ssize_t |
110 | minstrel_stats_read(struct file *file, char __user *buf, size_t len, loff_t *o) | 110 | minstrel_stats_read(struct file *file, char __user *buf, size_t len, loff_t *o) |
111 | { | 111 | { |
112 | struct minstrel_stats_info *ms; | 112 | struct minstrel_stats_info *ms; |
diff --git a/net/phonet/af_phonet.c b/net/phonet/af_phonet.c index b9d97effebe3..defeb7a0d502 100644 --- a/net/phonet/af_phonet.c +++ b/net/phonet/af_phonet.c | |||
@@ -261,6 +261,8 @@ static inline int can_respond(struct sk_buff *skb) | |||
261 | return 0; /* we are not the destination */ | 261 | return 0; /* we are not the destination */ |
262 | if (ph->pn_res == PN_PREFIX && !pskb_may_pull(skb, 5)) | 262 | if (ph->pn_res == PN_PREFIX && !pskb_may_pull(skb, 5)) |
263 | return 0; | 263 | return 0; |
264 | if (ph->pn_res == PN_COMMGR) /* indications */ | ||
265 | return 0; | ||
264 | 266 | ||
265 | ph = pn_hdr(skb); /* re-acquires the pointer */ | 267 | ph = pn_hdr(skb); /* re-acquires the pointer */ |
266 | pm = pn_msg(skb); | 268 | pm = pn_msg(skb); |
@@ -309,7 +311,8 @@ static int send_reset_indications(struct sk_buff *rskb) | |||
309 | 311 | ||
310 | return pn_raw_send(data, sizeof(data), rskb->dev, | 312 | return pn_raw_send(data, sizeof(data), rskb->dev, |
311 | pn_object(oph->pn_sdev, 0x00), | 313 | pn_object(oph->pn_sdev, 0x00), |
312 | pn_object(oph->pn_rdev, oph->pn_robj), 0x10); | 314 | pn_object(oph->pn_rdev, oph->pn_robj), |
315 | PN_COMMGR); | ||
313 | } | 316 | } |
314 | 317 | ||
315 | 318 | ||
diff --git a/net/rfkill/rfkill-input.c b/net/rfkill/rfkill-input.c index 21124ec0a73d..bfdade72e066 100644 --- a/net/rfkill/rfkill-input.c +++ b/net/rfkill/rfkill-input.c | |||
@@ -256,6 +256,11 @@ static struct input_handler rfkill_handler = { | |||
256 | 256 | ||
257 | static int __init rfkill_handler_init(void) | 257 | static int __init rfkill_handler_init(void) |
258 | { | 258 | { |
259 | unsigned long last_run = jiffies - msecs_to_jiffies(500); | ||
260 | rfkill_wlan.last = last_run; | ||
261 | rfkill_bt.last = last_run; | ||
262 | rfkill_uwb.last = last_run; | ||
263 | rfkill_wimax.last = last_run; | ||
259 | return input_register_handler(&rfkill_handler); | 264 | return input_register_handler(&rfkill_handler); |
260 | } | 265 | } |
261 | 266 | ||