aboutsummaryrefslogtreecommitdiffstats
path: root/fs
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@linux-foundation.org>2019-04-17 12:57:45 -0400
committerLinus Torvalds <torvalds@linux-foundation.org>2019-04-17 12:57:45 -0400
commit2a3a028fc61d03e80ac57091330eb514280bd5be (patch)
treec0f98d752faa37fed4d11231f08d368dce120786 /fs
parent444fe991353987c1c9bc5ab1f903d01f1b4ad415 (diff)
parente6986423d28362aafe64d3757bbbc493f2687f8f (diff)
Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net
Pull networking fixes from David Miller: 1) Handle init flow failures properly in iwlwifi driver, from Shahar S Matityahu. 2) mac80211 TXQs need to be unscheduled on powersave start, from Felix Fietkau. 3) SKB memory accounting fix in A-MDSU aggregation, from Felix Fietkau. 4) Increase RCU lock hold time in mlx5 FPGA code, from Saeed Mahameed. 5) Avoid checksum complete with XDP in mlx5, also from Saeed. 6) Fix netdev feature clobbering in ibmvnic driver, from Thomas Falcon. 7) Partial sent TLS record leak fix from Jakub Kicinski. 8) Reject zero size iova range in vhost, from Jason Wang. 9) Allow pending work to complete before clcsock release from Karsten Graul. 10) Fix XDP handling max MTU in thunderx, from Matteo Croce. 11) A lot of protocols look at the sa_family field of a sockaddr before validating it's length is large enough, from Tetsuo Handa. 12) Don't write to free'd pointer in qede ptp error path, from Colin Ian King. 13) Have to recompile IP options in ipv4_link_failure because it can be invoked from ARP, from Stephen Suryaputra. 14) Doorbell handling fixes in qed from Denis Bolotin. 15) Revert net-sysfs kobject register leak fix, it causes new problems. From Wang Hai. 16) Spectre v1 fix in ATM code, from Gustavo A. R. Silva. 17) Fix put of BROPT_VLAN_STATS_PER_PORT in bridging code, from Nikolay Aleksandrov. * git://git.kernel.org/pub/scm/linux/kernel/git/davem/net: (111 commits) socket: fix compat SO_RCVTIMEO_NEW/SO_SNDTIMEO_NEW tcp: tcp_grow_window() needs to respect tcp_space() ocelot: Clean up stats update deferred work ocelot: Don't sleep in atomic context (irqs_disabled()) net: bridge: fix netlink export of vlan_stats_per_port option qed: fix spelling mistake "faspath" -> "fastpath" tipc: set sysctl_tipc_rmem and named_timeout right range tipc: fix link established but not in session net: Fix missing meta data in skb with vlan packet net: atm: Fix potential Spectre v1 vulnerabilities net/core: work around section mismatch warning for ptp_classifier net: bridge: fix per-port af_packet sockets bnx2x: fix spelling mistake "dicline" -> "decline" route: Avoid crash from dereferencing NULL rt->from MAINTAINERS: normalize Woojung Huh's email address bonding: fix event handling for stacked bonds Revert "net-sysfs: Fix memory leak in netdev_register_kobject" rtnetlink: fix rtnl_valid_stats_req() nlmsg_len check qed: Fix the DORQ's attentions handling qed: Fix missing DORQ attentions ...
Diffstat (limited to 'fs')
-rw-r--r--fs/afs/rxrpc.c24
1 files changed, 17 insertions, 7 deletions
diff --git a/fs/afs/rxrpc.c b/fs/afs/rxrpc.c
index 2c588f9bbbda..c14001b42d20 100644
--- a/fs/afs/rxrpc.c
+++ b/fs/afs/rxrpc.c
@@ -610,6 +610,7 @@ static long afs_wait_for_call_to_complete(struct afs_call *call,
610 bool stalled = false; 610 bool stalled = false;
611 u64 rtt; 611 u64 rtt;
612 u32 life, last_life; 612 u32 life, last_life;
613 bool rxrpc_complete = false;
613 614
614 DECLARE_WAITQUEUE(myself, current); 615 DECLARE_WAITQUEUE(myself, current);
615 616
@@ -621,7 +622,7 @@ static long afs_wait_for_call_to_complete(struct afs_call *call,
621 rtt2 = 2; 622 rtt2 = 2;
622 623
623 timeout = rtt2; 624 timeout = rtt2;
624 last_life = rxrpc_kernel_check_life(call->net->socket, call->rxcall); 625 rxrpc_kernel_check_life(call->net->socket, call->rxcall, &last_life);
625 626
626 add_wait_queue(&call->waitq, &myself); 627 add_wait_queue(&call->waitq, &myself);
627 for (;;) { 628 for (;;) {
@@ -639,7 +640,12 @@ static long afs_wait_for_call_to_complete(struct afs_call *call,
639 if (afs_check_call_state(call, AFS_CALL_COMPLETE)) 640 if (afs_check_call_state(call, AFS_CALL_COMPLETE))
640 break; 641 break;
641 642
642 life = rxrpc_kernel_check_life(call->net->socket, call->rxcall); 643 if (!rxrpc_kernel_check_life(call->net->socket, call->rxcall, &life)) {
644 /* rxrpc terminated the call. */
645 rxrpc_complete = true;
646 break;
647 }
648
643 if (timeout == 0 && 649 if (timeout == 0 &&
644 life == last_life && signal_pending(current)) { 650 life == last_life && signal_pending(current)) {
645 if (stalled) 651 if (stalled)
@@ -663,12 +669,16 @@ static long afs_wait_for_call_to_complete(struct afs_call *call,
663 remove_wait_queue(&call->waitq, &myself); 669 remove_wait_queue(&call->waitq, &myself);
664 __set_current_state(TASK_RUNNING); 670 __set_current_state(TASK_RUNNING);
665 671
666 /* Kill off the call if it's still live. */
667 if (!afs_check_call_state(call, AFS_CALL_COMPLETE)) { 672 if (!afs_check_call_state(call, AFS_CALL_COMPLETE)) {
668 _debug("call interrupted"); 673 if (rxrpc_complete) {
669 if (rxrpc_kernel_abort_call(call->net->socket, call->rxcall, 674 afs_set_call_complete(call, call->error, call->abort_code);
670 RX_USER_ABORT, -EINTR, "KWI")) 675 } else {
671 afs_set_call_complete(call, -EINTR, 0); 676 /* Kill off the call if it's still live. */
677 _debug("call interrupted");
678 if (rxrpc_kernel_abort_call(call->net->socket, call->rxcall,
679 RX_USER_ABORT, -EINTR, "KWI"))
680 afs_set_call_complete(call, -EINTR, 0);
681 }
672 } 682 }
673 683
674 spin_lock_bh(&call->state_lock); 684 spin_lock_bh(&call->state_lock);