diff options
| -rw-r--r-- | net/ceph/messenger.c | 9 |
1 files changed, 1 insertions, 8 deletions
diff --git a/net/ceph/messenger.c b/net/ceph/messenger.c index 6b3f54ed65ba..a9f4ae45b7fb 100644 --- a/net/ceph/messenger.c +++ b/net/ceph/messenger.c | |||
| @@ -484,7 +484,7 @@ static int ceph_tcp_connect(struct ceph_connection *con) | |||
| 484 | IPPROTO_TCP, &sock); | 484 | IPPROTO_TCP, &sock); |
| 485 | if (ret) | 485 | if (ret) |
| 486 | return ret; | 486 | return ret; |
| 487 | sock->sk->sk_allocation = GFP_NOFS | __GFP_MEMALLOC; | 487 | sock->sk->sk_allocation = GFP_NOFS; |
| 488 | 488 | ||
| 489 | #ifdef CONFIG_LOCKDEP | 489 | #ifdef CONFIG_LOCKDEP |
| 490 | lockdep_set_class(&sock->sk->sk_lock, &socket_class); | 490 | lockdep_set_class(&sock->sk->sk_lock, &socket_class); |
| @@ -520,8 +520,6 @@ static int ceph_tcp_connect(struct ceph_connection *con) | |||
| 520 | ret); | 520 | ret); |
| 521 | } | 521 | } |
| 522 | 522 | ||
| 523 | sk_set_memalloc(sock->sk); | ||
| 524 | |||
| 525 | con->sock = sock; | 523 | con->sock = sock; |
| 526 | return 0; | 524 | return 0; |
| 527 | } | 525 | } |
| @@ -2808,11 +2806,8 @@ static void con_work(struct work_struct *work) | |||
| 2808 | { | 2806 | { |
| 2809 | struct ceph_connection *con = container_of(work, struct ceph_connection, | 2807 | struct ceph_connection *con = container_of(work, struct ceph_connection, |
| 2810 | work.work); | 2808 | work.work); |
| 2811 | unsigned long pflags = current->flags; | ||
| 2812 | bool fault; | 2809 | bool fault; |
| 2813 | 2810 | ||
| 2814 | current->flags |= PF_MEMALLOC; | ||
| 2815 | |||
| 2816 | mutex_lock(&con->mutex); | 2811 | mutex_lock(&con->mutex); |
| 2817 | while (true) { | 2812 | while (true) { |
| 2818 | int ret; | 2813 | int ret; |
| @@ -2866,8 +2861,6 @@ static void con_work(struct work_struct *work) | |||
| 2866 | con_fault_finish(con); | 2861 | con_fault_finish(con); |
| 2867 | 2862 | ||
| 2868 | con->ops->put(con); | 2863 | con->ops->put(con); |
| 2869 | |||
| 2870 | tsk_restore_flags(current, pflags, PF_MEMALLOC); | ||
| 2871 | } | 2864 | } |
| 2872 | 2865 | ||
| 2873 | /* | 2866 | /* |
