Skip to content

Commit

Permalink
Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel…
Browse files Browse the repository at this point in the history
…/git/sage/ceph-client

Pull ceph revert from Sage Weil:
 "This corrects a recent misadventure with __GFP_MEMALLOC and
  PF_MEMALLOC; it turns out it's not a good fit for RBD and we're better
  off relying on dirty page throttling"

* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/sage/ceph-client:
  Revert "libceph: use memalloc flags for net IO"
  • Loading branch information
torvalds committed Apr 8, 2015
2 parents b97fdef + 6d7fdb0 commit 9a08da1
Showing 1 changed file with 1 addition and 8 deletions.
9 changes: 1 addition & 8 deletions net/ceph/messenger.c
Original file line number Diff line number Diff line change
Expand Up @@ -484,7 +484,7 @@ static int ceph_tcp_connect(struct ceph_connection *con)
IPPROTO_TCP, &sock);
if (ret)
return ret;
sock->sk->sk_allocation = GFP_NOFS | __GFP_MEMALLOC;
sock->sk->sk_allocation = GFP_NOFS;

#ifdef CONFIG_LOCKDEP
lockdep_set_class(&sock->sk->sk_lock, &socket_class);
Expand Down Expand Up @@ -520,8 +520,6 @@ static int ceph_tcp_connect(struct ceph_connection *con)
ret);
}

sk_set_memalloc(sock->sk);

con->sock = sock;
return 0;
}
Expand Down Expand Up @@ -2808,11 +2806,8 @@ static void con_work(struct work_struct *work)
{
struct ceph_connection *con = container_of(work, struct ceph_connection,
work.work);
unsigned long pflags = current->flags;
bool fault;

current->flags |= PF_MEMALLOC;

mutex_lock(&con->mutex);
while (true) {
int ret;
Expand Down Expand Up @@ -2866,8 +2861,6 @@ static void con_work(struct work_struct *work)
con_fault_finish(con);

con->ops->put(con);

tsk_restore_flags(current, pflags, PF_MEMALLOC);
}

/*
Expand Down

0 comments on commit 9a08da1

Please sign in to comment.