diff options
author | Yehuda Sadeh <yehuda@hq.newdream.net> | 2010-04-06 17:33:58 -0400 |
---|---|---|
committer | Sage Weil <sage@newdream.net> | 2010-05-17 18:25:42 -0400 |
commit | 34d23762d988b7dcb08390ac72a353df3d60193c (patch) | |
tree | 3a49d039527548697165da2b8789f3588b95ffed /fs/ceph/mon_client.c | |
parent | 23804d91f112df09b832cd091b71af4dc2831aa8 (diff) |
ceph: all allocation functions should get gfp_mask
This is essential, as for the rados block device we'll need
to run in different contexts that would need flags that
are other than GFP_NOFS.
Signed-off-by: Yehuda Sadeh <yehuda@hq.newdream.net>
Signed-off-by: Sage Weil <sage@newdream.net>
Diffstat (limited to 'fs/ceph/mon_client.c')
-rw-r--r-- | fs/ceph/mon_client.c | 15 |
1 files changed, 8 insertions, 7 deletions
diff --git a/fs/ceph/mon_client.c b/fs/ceph/mon_client.c index 7062b889ab2f..61cb11701f10 100644 --- a/fs/ceph/mon_client.c +++ b/fs/ceph/mon_client.c | |||
@@ -191,7 +191,7 @@ static void __send_subscribe(struct ceph_mon_client *monc) | |||
191 | struct ceph_mon_subscribe_item *i; | 191 | struct ceph_mon_subscribe_item *i; |
192 | void *p, *end; | 192 | void *p, *end; |
193 | 193 | ||
194 | msg = ceph_msg_new(CEPH_MSG_MON_SUBSCRIBE, 96); | 194 | msg = ceph_msg_new(CEPH_MSG_MON_SUBSCRIBE, 96, GFP_NOFS); |
195 | if (!msg) | 195 | if (!msg) |
196 | return; | 196 | return; |
197 | 197 | ||
@@ -490,10 +490,10 @@ int ceph_monc_do_statfs(struct ceph_mon_client *monc, struct ceph_statfs *buf) | |||
490 | init_completion(&req->completion); | 490 | init_completion(&req->completion); |
491 | 491 | ||
492 | err = -ENOMEM; | 492 | err = -ENOMEM; |
493 | req->request = ceph_msg_new(CEPH_MSG_STATFS, sizeof(*h)); | 493 | req->request = ceph_msg_new(CEPH_MSG_STATFS, sizeof(*h), GFP_NOFS); |
494 | if (!req->request) | 494 | if (!req->request) |
495 | goto out; | 495 | goto out; |
496 | req->reply = ceph_msg_new(CEPH_MSG_STATFS_REPLY, 1024); | 496 | req->reply = ceph_msg_new(CEPH_MSG_STATFS_REPLY, 1024, GFP_NOFS); |
497 | if (!req->reply) | 497 | if (!req->reply) |
498 | goto out; | 498 | goto out; |
499 | 499 | ||
@@ -632,15 +632,16 @@ int ceph_monc_init(struct ceph_mon_client *monc, struct ceph_client *cl) | |||
632 | /* msg pools */ | 632 | /* msg pools */ |
633 | err = -ENOMEM; | 633 | err = -ENOMEM; |
634 | monc->m_subscribe_ack = ceph_msg_new(CEPH_MSG_MON_SUBSCRIBE_ACK, | 634 | monc->m_subscribe_ack = ceph_msg_new(CEPH_MSG_MON_SUBSCRIBE_ACK, |
635 | sizeof(struct ceph_mon_subscribe_ack)); | 635 | sizeof(struct ceph_mon_subscribe_ack), |
636 | GFP_NOFS); | ||
636 | if (!monc->m_subscribe_ack) | 637 | if (!monc->m_subscribe_ack) |
637 | goto out_monmap; | 638 | goto out_monmap; |
638 | 639 | ||
639 | monc->m_auth_reply = ceph_msg_new(CEPH_MSG_AUTH_REPLY, 4096); | 640 | monc->m_auth_reply = ceph_msg_new(CEPH_MSG_AUTH_REPLY, 4096, GFP_NOFS); |
640 | if (!monc->m_auth_reply) | 641 | if (!monc->m_auth_reply) |
641 | goto out_subscribe_ack; | 642 | goto out_subscribe_ack; |
642 | 643 | ||
643 | monc->m_auth = ceph_msg_new(CEPH_MSG_AUTH, 4096); | 644 | monc->m_auth = ceph_msg_new(CEPH_MSG_AUTH, 4096, GFP_NOFS); |
644 | monc->pending_auth = 0; | 645 | monc->pending_auth = 0; |
645 | if (!monc->m_auth) | 646 | if (!monc->m_auth) |
646 | goto out_auth_reply; | 647 | goto out_auth_reply; |
@@ -815,7 +816,7 @@ static struct ceph_msg *mon_alloc_msg(struct ceph_connection *con, | |||
815 | case CEPH_MSG_MON_MAP: | 816 | case CEPH_MSG_MON_MAP: |
816 | case CEPH_MSG_MDS_MAP: | 817 | case CEPH_MSG_MDS_MAP: |
817 | case CEPH_MSG_OSD_MAP: | 818 | case CEPH_MSG_OSD_MAP: |
818 | m = ceph_msg_new(type, front_len); | 819 | m = ceph_msg_new(type, front_len, GFP_NOFS); |
819 | break; | 820 | break; |
820 | } | 821 | } |
821 | 822 | ||