<feed xmlns='http://www.w3.org/2005/Atom'>
<title>linux/net/ceph, branch v3.5</title>
<subtitle>Mirror of https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/
</subtitle>
<id>https://git.shady.money/linux/atom?h=v3.5</id>
<link rel='self' href='https://git.shady.money/linux/atom?h=v3.5'/>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/'/>
<updated>2012-07-18T02:35:59Z</updated>
<entry>
<title>libceph: fix messenger retry</title>
<updated>2012-07-18T02:35:59Z</updated>
<author>
<name>Sage Weil</name>
<email>sage@inktank.com</email>
</author>
<published>2012-07-10T18:53:34Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=5bdca4e0768d3e0f4efa43d9a2cc8210aeb91ab9'/>
<id>urn:sha1:5bdca4e0768d3e0f4efa43d9a2cc8210aeb91ab9</id>
<content type='text'>
In ancient times, the messenger could both initiate and accept connections.
An artifact if that was data structures to store/process an incoming
ceph_msg_connect request and send an outgoing ceph_msg_connect_reply.
Sadly, the negotiation code was referencing those structures and ignoring
important information (like the peer's connect_seq) from the correct ones.

Among other things, this fixes tight reconnect loops where the server sends
RETRY_SESSION and we (the client) retries with the same connect_seq as last
time.  This bug pretty easily triggered by injecting socket failures on the
MDS and running some fs workload like workunits/direct_io/test_sync_io.

Signed-off-by: Sage Weil &lt;sage@inktank.com&gt;
</content>
</entry>
<entry>
<title>libceph: flush msgr queue during mon_client shutdown</title>
<updated>2012-06-20T12:43:50Z</updated>
<author>
<name>Sage Weil</name>
<email>sage@inktank.com</email>
</author>
<published>2012-06-11T03:43:56Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=642c0dbde32f34baa7886e988a067089992adc8f'/>
<id>urn:sha1:642c0dbde32f34baa7886e988a067089992adc8f</id>
<content type='text'>
We need to flush the msgr workqueue during mon_client shutdown to
ensure that any work affecting our embedded ceph_connection is
finished so that we can be safely destroyed.

Previously, we were flushing the work queue after osd_client
shutdown and before mon_client shutdown to ensure that any osd
connection refs to authorizers are flushed.  Remove the redundant
flush, and document in the comment that the mon_client flush is
needed to cover that case as well.

Signed-off-by: Sage Weil &lt;sage@inktank.com&gt;
Reviewed-by: Alex Elder &lt;elder@inktank.com&gt;
(cherry picked from commit f3dea7edd3d449fe7a6d402c1ce56a294b985261)
</content>
</entry>
<entry>
<title>rbd: Clear ceph_msg-&gt;bio_iter for retransmitted message</title>
<updated>2012-06-20T12:43:50Z</updated>
<author>
<name>Yan, Zheng</name>
<email>zheng.z.yan@intel.com</email>
</author>
<published>2012-06-07T00:35:55Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=b132cf4c733f91bb4dd2277ea049243cf16e8b66'/>
<id>urn:sha1:b132cf4c733f91bb4dd2277ea049243cf16e8b66</id>
<content type='text'>
The bug can cause NULL pointer dereference in write_partial_msg_pages

Signed-off-by: Zheng Yan &lt;zheng.z.yan@intel.com&gt;
Reviewed-by: Alex Elder &lt;elder@inktank.com&gt;
(cherry picked from commit 43643528cce60ca184fe8197efa8e8da7c89a037)
</content>
</entry>
<entry>
<title>libceph: use con get/put ops from osd_client</title>
<updated>2012-06-20T12:43:49Z</updated>
<author>
<name>Sage Weil</name>
<email>sage@inktank.com</email>
</author>
<published>2012-06-01T03:22:18Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=88ed6ea0b295f8e2383d599a04027ec596cdf97b'/>
<id>urn:sha1:88ed6ea0b295f8e2383d599a04027ec596cdf97b</id>
<content type='text'>
There were a few direct calls to ceph_con_{get,put}() instead of the con
ops from osd_client.c.  This is a bug since those ops aren't defined to
be ceph_con_get/put.

This breaks refcounting on the ceph_osd structs that contain the
ceph_connections, and could lead to all manner of strangeness.

The purpose of the -&gt;get and -&gt;put methods in a ceph connection are
to allow the connection to indicate it has a reference to something
external to the messaging system, *not* to indicate something
external has a reference to the connection.

[elder@inktank.com: added that last sentence]

Signed-off-by: Sage Weil &lt;sage@newdream.net&gt;
Reviewed-by: Alex Elder &lt;elder@inktank.com&gt;
(cherry picked from commit 0d47766f14211a73eaf54cab234db134ece79f49)
</content>
</entry>
<entry>
<title>libceph: osd_client: don't drop reply reference too early</title>
<updated>2012-06-20T12:43:48Z</updated>
<author>
<name>Alex Elder</name>
<email>elder@inktank.com</email>
</author>
<published>2012-06-04T19:43:32Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=680584fab05efff732b5ae16ad601ba994d7b505'/>
<id>urn:sha1:680584fab05efff732b5ae16ad601ba994d7b505</id>
<content type='text'>
In ceph_osdc_release_request(), a reference to the r_reply message
is dropped.  But just after that, that same message is revoked if it
was in use to receive an incoming reply.  Reorder these so we are
sure we hold a reference until we're actually done with the message.

Signed-off-by: Alex Elder &lt;elder@inktank.com&gt;
Reviewed-by: Sage Weil &lt;sage@inktank.com&gt;
(cherry picked from commit ab8cb34a4b2f60281a4b18b1f1ad23bc2313d91b)
</content>
</entry>
<entry>
<title>Merge git://git.kernel.org/pub/scm/linux/kernel/git/sage/ceph-client</title>
<updated>2012-05-30T18:17:19Z</updated>
<author>
<name>Linus Torvalds</name>
<email>torvalds@linux-foundation.org</email>
</author>
<published>2012-05-30T18:17:19Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=af56e0aa35f3ae2a4c1a6d1000702df1dd78cb76'/>
<id>urn:sha1:af56e0aa35f3ae2a4c1a6d1000702df1dd78cb76</id>
<content type='text'>
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
  ...
</content>
</entry>
<entry>
<title>libceph: fix pg_temp updates</title>
<updated>2012-05-22T03:40:42Z</updated>
<author>
<name>Sage Weil</name>
<email>sage@inktank.com</email>
</author>
<published>2012-05-21T16:45:23Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=6bd9adbdf9ca6a052b0b7455ac67b925eb38cfad'/>
<id>urn:sha1:6bd9adbdf9ca6a052b0b7455ac67b925eb38cfad</id>
<content type='text'>
Usually, we are adding pg_temp entries or removing them.  Occasionally they
update.  In that case, osdmap_apply_incremental() was failing because the
rbtree entry already exists.

Fix by removing the existing entry before inserting a new one.

Fixes http://tracker.newdream.net/issues/2446

Signed-off-by: Sage Weil &lt;sage@inktank.com&gt;
Reviewed-by: Alex Elder &lt;elder@inktank.com&gt;
</content>
</entry>
<entry>
<title>libceph: avoid unregistering osd request when not registered</title>
<updated>2012-05-19T00:36:00Z</updated>
<author>
<name>Sage Weil</name>
<email>sage@inktank.com</email>
</author>
<published>2012-05-16T20:16:38Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=35f9f8a09e1e88e31bd34a1e645ca0e5f070dd5c'/>
<id>urn:sha1:35f9f8a09e1e88e31bd34a1e645ca0e5f070dd5c</id>
<content type='text'>
There is a race between two __unregister_request() callers: the
reply path and the ceph_osdc_wait_request().  If we get a reply
*and* the timeout expires at roughly the same time, both callers
will try to unregister the request, and the second one will do bad
things.

Simply check if the request is still already unregistered; if so,
return immediately and do nothing.

Fixes http://tracker.newdream.net/issues/2420

Signed-off-by: Sage Weil &lt;sage@inktank.com&gt;
Reviewed-by: Alex Elder &lt;elder@inktank.com&gt;
</content>
</entry>
<entry>
<title>ceph: add auth buf in prepare_write_connect()</title>
<updated>2012-05-19T00:35:59Z</updated>
<author>
<name>Alex Elder</name>
<email>elder@inktank.com</email>
</author>
<published>2012-05-16T20:16:39Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=3da54776e2c0385c32d143fd497a7f40a88e29dd'/>
<id>urn:sha1:3da54776e2c0385c32d143fd497a7f40a88e29dd</id>
<content type='text'>
Move the addition of the authorizer buffer to a connection's
out_kvec out of get_connect_authorizer() and into its caller.  This
way, the caller--prepare_write_connect()--can avoid adding the
connect header to out_kvec before it has been fully initialized.

Prior to this patch, it was possible for a connect header to be
sent over the wire before the authorizer protocol or buffer length
fields were initialized.  An authorizer buffer associated with that
header could also be queued to send only after the connection header
that describes it was on the wire.

Fixes http://tracker.newdream.net/issues/2424

Signed-off-by: Alex Elder &lt;elder@inktank.com&gt;
Reviewed-by: Sage Weil &lt;sage@inktank.com&gt;
</content>
</entry>
<entry>
<title>ceph: rename prepare_connect_authorizer()</title>
<updated>2012-05-17T13:18:13Z</updated>
<author>
<name>Alex Elder</name>
<email>elder@inktank.com</email>
</author>
<published>2012-05-16T20:16:39Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=dac1e716c60161867a47745bca592987ca3a9cb2'/>
<id>urn:sha1:dac1e716c60161867a47745bca592987ca3a9cb2</id>
<content type='text'>
Change the name of prepare_connect_authorizer().  The next
patch is going to make this function no longer add anything to the
connection's out_kvec, so it will no longer fit the pattern of
the rest of the prepare_connect_*() functions.

In addition, pass the address of a variable that will hold the
authorization protocol to use.  Move the assignment of that to the
connection's out_connect structure into prepare_write_connect().

Signed-off-by: Alex Elder &lt;elder@inktank.com&gt;
Reviewed-by: Sage Weil &lt;sage@inktank.com&gt;
</content>
</entry>
</feed>
