From patchwork Mon Feb 25 23:42:19 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Alex Elder X-Patchwork-Id: 2183241 Return-Path: X-Original-To: patchwork-ceph-devel@patchwork.kernel.org Delivered-To: patchwork-process-083081@patchwork1.kernel.org Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by patchwork1.kernel.org (Postfix) with ESMTP id 924053FD4E for ; Mon, 25 Feb 2013 23:42:23 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1759853Ab3BYXmX (ORCPT ); Mon, 25 Feb 2013 18:42:23 -0500 Received: from mail-ie0-f181.google.com ([209.85.223.181]:34196 "EHLO mail-ie0-f181.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1759825Ab3BYXmW (ORCPT ); Mon, 25 Feb 2013 18:42:22 -0500 Received: by mail-ie0-f181.google.com with SMTP id 17so3760014iea.26 for ; Mon, 25 Feb 2013 15:42:22 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=x-received:message-id:date:from:user-agent:mime-version:to:subject :references:in-reply-to:content-type:content-transfer-encoding :x-gm-message-state; bh=TG6YYAzKjOjuly9Hllw50pfntWzGYVjr5wyvjxhiMKA=; b=R6YwpAj1iI8l214DmDIB7xqNbRHkphT3LHkWxI/MayKn4FjbPCcvQguKaCukDOubIp KQvyeB+l5evOIjPjUM/x6JTdQp9YJlV6WEl3Jl2p7AE1z0utDn3RsZQr9/GEwdZNlJ9A GnuJIjjaHb+RLWxGcByd+oNTqpt02Ee1MJtKoFGDXpqUb0U/8OoBW+yKE68plUR5pwY1 Puqbx/v5pu9HsIK7S4LLcNG2O4LAPWemvlwSD18xegDAhSMFid1NDHeWLXIoibKVJy5J ty+i3YeJqTolwtVMlZyiXLjaIapuul2ni8BGlU+S7lxGZTWM/ce76Ht1I3HrI2jZZOU3 980A== X-Received: by 10.50.42.165 with SMTP id p5mr4433433igl.75.1361835742195; Mon, 25 Feb 2013 15:42:22 -0800 (PST) Received: from [172.22.22.4] (c-71-195-31-37.hsd1.mn.comcast.net. [71.195.31.37]) by mx.google.com with ESMTPS id nh1sm6390892igc.4.2013.02.25.15.42.20 (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Mon, 25 Feb 2013 15:42:21 -0800 (PST) Message-ID: <512BF6DB.1040003@inktank.com> Date: Mon, 25 Feb 2013 17:42:19 -0600 From: Alex Elder User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:17.0) Gecko/20130106 Thunderbird/17.0.2 MIME-Version: 1.0 To: "ceph-devel@vger.kernel.org" Subject: [PATCH 2/4] libceph: set page alignment in start_request() References: <512BF683.5050905@inktank.com> In-Reply-To: <512BF683.5050905@inktank.com> X-Gm-Message-State: ALoCoQmW4h3+AJnfFFJniglhPOqhVdaEWz/iZzUK1xRbXYS5P6+Vb72IYf7xcZ4tnu/yiGVQl8Vb Sender: ceph-devel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: ceph-devel@vger.kernel.org The page alignment field for a request is currently set in ceph_osdc_build_request(). It's not needed at that point nor do either of its callers need that value assigned at any point before they call ceph_osdc_start_request(). So move that assignment into ceph_osdc_start_request(). Signed-off-by: Alex Elder --- net/ceph/osd_client.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) msg_size = p - msg->front.iov_base; @@ -1632,6 +1631,7 @@ int ceph_osdc_start_request(struct ceph_osd_client *osdc, req->r_request->pages = req->r_pages; req->r_request->page_count = req->r_num_pages; + req->r_request->page_alignment = req->r_page_alignment; #ifdef CONFIG_BLOCK req->r_request->bio = req->r_bio; #endif diff --git a/net/ceph/osd_client.c b/net/ceph/osd_client.c index 0a4d4a0..1bb2b59 100644 --- a/net/ceph/osd_client.c +++ b/net/ceph/osd_client.c @@ -369,7 +369,6 @@ void ceph_osdc_build_request(struct ceph_osd_request *req, data_len += len; } req->r_request->hdr.data_len = cpu_to_le32(data_len); - req->r_request->page_alignment = req->r_page_alignment; BUG_ON(p > msg->front.iov_base + msg->front.iov_len);