From: Linus Torvalds Date: Wed, 30 May 2012 18:17:19 +0000 (-0700) Subject: Merge git://git.kernel.org/pub/scm/linux/kernel/git/sage/ceph-client X-Git-Tag: v3.5-rc1~36 X-Git-Url: https://git.karo-electronics.de/?a=commitdiff_plain;h=af56e0aa35f3ae2a4c1a6d1000702df1dd78cb76;p=karo-tx-linux.git Merge git://git.kernel.org/pub/scm/linux/kernel/git/sage/ceph-client Pull ceph updates from Sage Weil: "There are some updates and cleanups to the CRUSH placement code, a bug fix with incremental maps, several cleanups and fixes from Josh Durgin in the RBD block device code, a series of cleanups and bug fixes from Alex Elder in the messenger code, and some miscellaneous bounds checking and gfp cleanups/fixes." Fix up trivial conflicts in net/ceph/{messenger.c,osdmap.c} due to the networking people preferring "unsigned int" over just "unsigned". * git://git.kernel.org/pub/scm/linux/kernel/git/sage/ceph-client: (45 commits) libceph: fix pg_temp updates libceph: avoid unregistering osd request when not registered ceph: add auth buf in prepare_write_connect() ceph: rename prepare_connect_authorizer() ceph: return pointer from prepare_connect_authorizer() ceph: use info returned by get_authorizer ceph: have get_authorizer methods return pointers ceph: ensure auth ops are defined before use ceph: messenger: reduce args to create_authorizer ceph: define ceph_auth_handshake type ceph: messenger: check return from get_authorizer ceph: messenger: rework prepare_connect_authorizer() ceph: messenger: check prepare_write_connect() result ceph: don't set WRITE_PENDING too early ceph: drop msgr argument from prepare_write_connect() ceph: messenger: send banner in process_connect() ceph: messenger: reset connection kvec caller libceph: don't reset kvec in prepare_write_banner() ceph: ignore preferred_osd field ceph: fully initialize new layout ... --- af56e0aa35f3ae2a4c1a6d1000702df1dd78cb76 diff --cc net/ceph/crush/mapper.c index 363f8f7e6c3c,11cf352201ba..d7edc24333b8 --- a/net/ceph/crush/mapper.c +++ b/net/ceph/crush/mapper.c @@@ -69,11 -68,11 +69,11 @@@ int crush_find_rule(const struct crush_ static int bucket_perm_choose(struct crush_bucket *bucket, int x, int r) { - unsigned pr = r % bucket->size; - unsigned i, s; + unsigned int pr = r % bucket->size; + unsigned int i, s; /* start a new permutation if @x has changed */ - if (bucket->perm_x != x || bucket->perm_n == 0) { + if (bucket->perm_x != (__u32)x || bucket->perm_n == 0) { dprintk("bucket %d new x=%d\n", bucket->id, x); bucket->perm_x = x; diff --cc net/ceph/messenger.c index 36fa6bf68498,1a80907282cc..524f4e4f598b --- a/net/ceph/messenger.c +++ b/net/ceph/messenger.c @@@ -695,12 -698,12 +698,12 @@@ static void prepare_write_banner(struc set_bit(WRITE_PENDING, &con->state); } - static int prepare_write_connect(struct ceph_messenger *msgr, - struct ceph_connection *con, - int include_banner) + static int prepare_write_connect(struct ceph_connection *con) { - unsigned global_seq = get_global_seq(con->msgr, 0); + unsigned int global_seq = get_global_seq(con->msgr, 0); int proto; + int auth_proto; + struct ceph_auth_handshake *auth; switch (con->peer_name.type) { case CEPH_ENTITY_TYPE_MON: @@@ -1627,9 -1663,10 +1663,10 @@@ static int read_partial_message_bio(str static int read_partial_message(struct ceph_connection *con) { struct ceph_msg *m = con->in_msg; + int size; + int end; int ret; - int to, left; - unsigned front_len, middle_len, data_len; + unsigned int front_len, middle_len, data_len; bool do_datacrc = !con->msgr->nocrc; int skip; u64 seq; diff --cc net/ceph/osdmap.c index 56e561a69004,1892c523c43c..81e3b84a77ef --- a/net/ceph/osdmap.c +++ b/net/ceph/osdmap.c @@@ -998,12 -995,11 +995,11 @@@ int ceph_calc_object_layout(struct ceph struct ceph_file_layout *fl, struct ceph_osdmap *osdmap) { - unsigned num, num_mask; + unsigned int num, num_mask; struct ceph_pg pgid; - s32 preferred = (s32)le32_to_cpu(fl->fl_pg_preferred); int poolid = le32_to_cpu(fl->fl_pg_pool); struct ceph_pg_pool_info *pool; - unsigned ps; + unsigned int ps; BUG_ON(!osdmap); @@@ -1045,8 -1031,7 +1031,7 @@@ static int *calc_pg_raw(struct ceph_osd struct ceph_pg_mapping *pg; struct ceph_pg_pool_info *pool; int ruleno; - unsigned int poolid, ps, pps, t; - int preferred; - unsigned poolid, ps, pps, t, r; ++ unsigned int poolid, ps, pps, t, r; poolid = le32_to_cpu(pgid.pool); ps = le16_to_cpu(pgid.ps);