remarkable-linux/fs/ceph
Alex Elder 153e5167e0 libceph: don't assign page info in ceph_osdc_new_request()
Currently ceph_osdc_new_request() assigns an osd request's
r_num_pages and r_alignment fields.  The only thing it does
after that is call ceph_osdc_build_request(), and that doesn't
need those fields to be assigned.

Move the assignment of those fields out of ceph_osdc_new_request()
and into its caller.  As a result, the page_align parameter is no
longer used, so get rid of it.

Note that in ceph_sync_write(), the value for req->r_num_pages had
already been calculated earlier (as num_pages, and fortunately
it was computed the same way).  So don't bother recomputing it,
but because it's not needed earlier, move that calculation after the
call to ceph_osdc_new_request().  Hold off making the assignment to
r_alignment, doing it instead r_pages and r_num_pages are
getting set.

Similarly, in start_read(), nr_pages already holds the number of
pages in the array (and is calculated the same way), so there's no
need to recompute it.  Move the assignment of the page alignment
down with the others there as well.

This and the next few patches are preparation work for:
    http://tracker.ceph.com/issues/4127

Signed-off-by: Alex Elder <elder@inktank.com>
Reviewed-by: Josh Durgin <josh.durgin@inktank.com>
2013-05-01 21:16:23 -07:00
..
addr.c libceph: don't assign page info in ceph_osdc_new_request() 2013-05-01 21:16:23 -07:00
caps.c ceph: use I_COMPLETE inode flag instead of D_COMPLETE flag 2013-05-01 21:14:33 -07:00
ceph_frag.c ceph: factor out libceph from Ceph file system 2010-10-20 15:37:28 -07:00
debugfs.c libceph: delay debugfs initialization until we learn global_id 2012-08-20 10:03:15 -07:00
dir.c ceph: use I_COMPLETE inode flag instead of D_COMPLETE flag 2013-05-01 21:14:33 -07:00
export.c fs: encode_fh: return FILEID_INVALID if invalid fid_type 2013-02-26 02:46:10 -05:00
file.c libceph: don't assign page info in ceph_osdc_new_request() 2013-05-01 21:16:23 -07:00
inode.c ceph: acquire i_mutex in __ceph_do_pending_vmtruncate 2013-05-01 21:16:11 -07:00
ioctl.c libceph: rename ceph_calc_object_layout() 2013-05-01 21:16:17 -07:00
ioctl.h ceph: fully initialize new layout 2012-05-16 14:28:27 -05:00
Kconfig fs/ceph: remove depends on CONFIG_EXPERIMENTAL 2013-01-11 11:39:04 -08:00
locks.c new helper: file_inode(file) 2013-02-22 23:31:31 -05:00
Makefile ceph: Makefile: Remove unnessary code 2011-01-12 15:15:13 -08:00
mds_client.c libceph: no need for alignment for mds message 2013-05-01 21:16:20 -07:00
mds_client.h Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/sage/ceph-client 2013-02-28 17:43:09 -08:00
mdsmap.c ceph: update support for PGID64, PGPOOL3, OSDENC protocol features 2013-02-26 15:02:25 -08:00
snap.c ceph: define snap counts as u32 everywhere 2012-07-30 18:15:47 -07:00
strings.c libceph: update ceph_mds_state_name() and ceph_mds_op_name() 2013-02-18 12:20:34 -06:00
super.c fs: Limit sys_mount to only request filesystem modules. 2013-03-03 19:36:31 -08:00
super.h ceph: acquire i_mutex in __ceph_do_pending_vmtruncate 2013-05-01 21:16:11 -07:00
xattr.c ceph: eliminate sparse warnings in fs code 2013-02-25 15:37:14 -06:00