aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/ethernet/broadcom/cnic.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/net/ethernet/broadcom/cnic.c')
-rw-r--r--drivers/net/ethernet/broadcom/cnic.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/drivers/net/ethernet/broadcom/cnic.c b/drivers/net/ethernet/broadcom/cnic.c
index 09f3fefcbf9c..4dd48d2fa804 100644
--- a/drivers/net/ethernet/broadcom/cnic.c
+++ b/drivers/net/ethernet/broadcom/cnic.c
@@ -436,7 +436,7 @@ static int cnic_offld_prep(struct cnic_sock *csk)
436static int cnic_close_prep(struct cnic_sock *csk) 436static int cnic_close_prep(struct cnic_sock *csk)
437{ 437{
438 clear_bit(SK_F_CONNECT_START, &csk->flags); 438 clear_bit(SK_F_CONNECT_START, &csk->flags);
439 smp_mb__after_clear_bit(); 439 smp_mb__after_atomic();
440 440
441 if (test_and_clear_bit(SK_F_OFFLD_COMPLETE, &csk->flags)) { 441 if (test_and_clear_bit(SK_F_OFFLD_COMPLETE, &csk->flags)) {
442 while (test_and_set_bit(SK_F_OFFLD_SCHED, &csk->flags)) 442 while (test_and_set_bit(SK_F_OFFLD_SCHED, &csk->flags))
@@ -450,7 +450,7 @@ static int cnic_close_prep(struct cnic_sock *csk)
450static int cnic_abort_prep(struct cnic_sock *csk) 450static int cnic_abort_prep(struct cnic_sock *csk)
451{ 451{
452 clear_bit(SK_F_CONNECT_START, &csk->flags); 452 clear_bit(SK_F_CONNECT_START, &csk->flags);
453 smp_mb__after_clear_bit(); 453 smp_mb__after_atomic();
454 454
455 while (test_and_set_bit(SK_F_OFFLD_SCHED, &csk->flags)) 455 while (test_and_set_bit(SK_F_OFFLD_SCHED, &csk->flags))
456 msleep(1); 456 msleep(1);
@@ -3646,7 +3646,7 @@ static int cnic_cm_destroy(struct cnic_sock *csk)
3646 3646
3647 csk_hold(csk); 3647 csk_hold(csk);
3648 clear_bit(SK_F_INUSE, &csk->flags); 3648 clear_bit(SK_F_INUSE, &csk->flags);
3649 smp_mb__after_clear_bit(); 3649 smp_mb__after_atomic();
3650 while (atomic_read(&csk->ref_count) != 1) 3650 while (atomic_read(&csk->ref_count) != 1)
3651 msleep(1); 3651 msleep(1);
3652 cnic_cm_cleanup(csk); 3652 cnic_cm_cleanup(csk);
@@ -4026,7 +4026,7 @@ static void cnic_cm_process_kcqe(struct cnic_dev *dev, struct kcqe *kcqe)
4026 L4_KCQE_COMPLETION_STATUS_PARITY_ERROR) 4026 L4_KCQE_COMPLETION_STATUS_PARITY_ERROR)
4027 set_bit(SK_F_HW_ERR, &csk->flags); 4027 set_bit(SK_F_HW_ERR, &csk->flags);
4028 4028
4029 smp_mb__before_clear_bit(); 4029 smp_mb__before_atomic();
4030 clear_bit(SK_F_OFFLD_SCHED, &csk->flags); 4030 clear_bit(SK_F_OFFLD_SCHED, &csk->flags);
4031 cnic_cm_upcall(cp, csk, opcode); 4031 cnic_cm_upcall(cp, csk, opcode);
4032 break; 4032 break;