CEPH filesystem development
 help / color / mirror / Atom feed
* [PATCH 00/16] ceph: messenger cleanups and fixes
@ 2012-05-17 13:54 Alex Elder
  2012-05-17 14:03 ` [PATCH 01/16] libceph: don't reset kvec in prepare_write_banner() Alex Elder
                   ` (15 more replies)
  0 siblings, 16 replies; 17+ messages in thread
From: Alex Elder @ 2012-05-17 13:54 UTC (permalink / raw)
  To: ceph-devel

This series culminates in fixing a bug in which ceph connection
header might get sent over the wire before its associated authorizer
structure has been fully prepared.  More info is found here:
     http://tracker.newdream.net/issues/2424

Sage preemptively reviewed them before I got them posted to the
list, and the patches that follow indicate that.  These patches are
being tested now, and unless I get actionable feedback (and if they
successfully pass testing) I'll be committing them as-is.

Along the way a few other small bugs are fixed (or avoided) and some
data structures and interfaces are modified a bit to simplify
things.  Here is a bit of summary information about them.

These first four rearrange some places where a connection's out_kvec
fields get reset, and where/when a banner gets put out prior to a
connection header.  A couple of functions can then eliminate a
parameter as a result.
     libceph: don't reset kvec in prepare_write_banner()
     ceph: messenger: reset connection kvec caller
     ceph: messenger: send banner in process_connect()
     ceph: drop msgr argument from prepare_write_connect()

This defers setting WRITE_PENDING when a connection header has been
queued to write but not its associated authorizer buffer.
     ceph: don't set WRITE_PENDING too early

These add error checking in two spots, and rearranges a function so
a simple case can be handled without dropping a connection's mutex.
     ceph: messenger: check prepare_write_connect() result
     ceph: messenger: rework prepare_connect_authorizer()
     ceph: messenger: check return from get_authorizer

This defines a type to group some authorizer-related fields, then
uses it to simplify some function interfaces.  It also adds some
additional checking before using method function pointers.
     ceph: define ceph_auth_handshake type
     ceph: messenger: reduce args to create_authorizer
     ceph: ensure auth ops are defined before use
     ceph: have get_authorizer methods return pointers
     ceph: use info returned by get_authorizer
     ceph: return pointer from prepare_connect_authorizer()

These final two implement the final fix for bug 2424 mentioned
above.  It doesn't place the connection header into out_kvec until
it is fully initialized, and then ensures the associated authorizer
buffer is also added before marking the WRITE_PENDING flag on the
connection (and also before dropping the connection mutex).
     ceph: rename prepare_connect_authorizer()
     ceph: add auth buf in prepare_write_connect()

					-Alex

^ permalink raw reply	[flat|nested] 17+ messages in thread

end of thread, other threads:[~2012-05-17 14:05 UTC | newest]

Thread overview: 17+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-05-17 13:54 [PATCH 00/16] ceph: messenger cleanups and fixes Alex Elder
2012-05-17 14:03 ` [PATCH 01/16] libceph: don't reset kvec in prepare_write_banner() Alex Elder
2012-05-17 14:04 ` [PATCH 02/16] ceph: messenger: reset connection kvec caller Alex Elder
2012-05-17 14:04 ` [PATCH 03/16] ceph: messenger: send banner in process_connect() Alex Elder
2012-05-17 14:04 ` [PATCH 04/16] ceph: drop msgr argument from prepare_write_connect() Alex Elder
2012-05-17 14:04 ` [PATCH 05/16] ceph: don't set WRITE_PENDING too early Alex Elder
2012-05-17 14:04 ` [PATCH 06/16] ceph: messenger: check prepare_write_connect() result Alex Elder
2012-05-17 14:04 ` [PATCH 07/16] ceph: messenger: rework prepare_connect_authorizer() Alex Elder
2012-05-17 14:04 ` [PATCH 08/16] ceph: messenger: check return from get_authorizer Alex Elder
2012-05-17 14:04 ` [PATCH 09/16] ceph: define ceph_auth_handshake type Alex Elder
2012-05-17 14:04 ` [PATCH 10/16] ceph: messenger: reduce args to create_authorizer Alex Elder
2012-05-17 14:05 ` [PATCH 11/16] ceph: ensure auth ops are defined before use Alex Elder
2012-05-17 14:05 ` [PATCH 12/16] ceph: have get_authorizer methods return pointers Alex Elder
2012-05-17 14:05 ` [PATCH 13/16] ceph: use info returned by get_authorizer Alex Elder
2012-05-17 14:05 ` [PATCH 14/16] ceph: return pointer from prepare_connect_authorizer() Alex Elder
2012-05-17 14:05 ` [PATCH 15/16] ceph: rename prepare_connect_authorizer() Alex Elder
2012-05-17 14:05 ` [PATCH 16/16] ceph: add auth buf in prepare_write_connect() Alex Elder

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox