From patchwork Sat Sep 8 02:13:36 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Long Li X-Patchwork-Id: 10592867 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id CDE3C18FD for ; Sat, 8 Sep 2018 02:16:49 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id C77912B684 for ; Sat, 8 Sep 2018 02:16:49 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id BBA102B68A; Sat, 8 Sep 2018 02:16:49 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-7.9 required=2.0 tests=BAYES_00,MAILING_LIST_MULTI, RCVD_IN_DNSWL_HI autolearn=unavailable version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 71B1D2B684 for ; Sat, 8 Sep 2018 02:16:49 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726545AbeIHG7J (ORCPT ); Sat, 8 Sep 2018 02:59:09 -0400 Received: from a2nlsmtp01-02.prod.iad2.secureserver.net ([198.71.225.36]:47266 "EHLO a2nlsmtp01-02.prod.iad2.secureserver.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726032AbeIHG7J (ORCPT ); Sat, 8 Sep 2018 02:59:09 -0400 Received: from linuxonhyperv2.linuxonhyperv.com ([107.180.71.197]) by : HOSTING RELAY : with ESMTP id ySlKfRLunWFPMySlKffcrV; Fri, 07 Sep 2018 19:14:22 -0700 x-originating-ip: 107.180.71.197 Received: from longli by linuxonhyperv2.linuxonhyperv.com with local (Exim 4.91) (envelope-from ) id 1fySlK-0005Dj-RE; Fri, 07 Sep 2018 19:14:14 -0700 From: Long Li To: Steve French , linux-cifs@vger.kernel.org, samba-technical@lists.samba.org, linux-kernel@vger.kernel.org, linux-rdma@vger.kernel.org Cc: Long Li Subject: [Patch v3 04/16] CIFS: pass page offset when issuing SMB write Date: Sat, 8 Sep 2018 02:13:36 +0000 Message-Id: <20180908021348.19956-5-longli@linuxonhyperv.com> X-Mailer: git-send-email 2.18.0 In-Reply-To: <20180908021348.19956-1-longli@linuxonhyperv.com> References: <20180908021348.19956-1-longli@linuxonhyperv.com> Reply-To: longli@microsoft.com X-CMAE-Envelope: MS4wfJ1feJ/TGt2PGk3lQEMBaXYiUMCSWvMRHiScg/MqSq4873sTxqzx/haTexSzlG+EAEsFNPmQ7qj5ph4kNz/fBF2F6xaA5MmWJxI6jXKU+RLb/Qugj8T/ PsBiHi+jf7+v6yZRYIfCMIwMdoNFG7J+InZ3Ts+FxIHShHPt7PO8JEklFopKbKWT+l0CwyG/f2oRKZp+fefw3cJqpdP+uVpAGVXpj8HQi3T1qQ8xK0ggiBnc HszmYWJa8fb9K2NUW2TjVbe6ZSWJVlbheA811NGr73fd4fb5yXiEmS9ebsAwD29MX0zJ81lNNfg6QZO9IAju7e+J0S4ouFwAD7OlQ1ehlw5LhfVwO9AECG71 tjOt8pI976H7aQHMF0RLqZsiYskBMJ8TUj8ilrcaaIELfJx4tSpyrBGKV0TrwklHklCq3LxA Sender: linux-rdma-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-rdma@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP From: Long Li When issuing SMB writes, pass along the write data page offset to transport. Signed-off-by: Long Li --- fs/cifs/cifssmb.c | 1 + fs/cifs/smb2pdu.c | 1 + 2 files changed, 2 insertions(+) diff --git a/fs/cifs/cifssmb.c b/fs/cifs/cifssmb.c index 503e0ed..0a57c61 100644 --- a/fs/cifs/cifssmb.c +++ b/fs/cifs/cifssmb.c @@ -2200,6 +2200,7 @@ cifs_async_writev(struct cifs_writedata *wdata, rqst.rq_iov = iov; rqst.rq_nvec = 2; rqst.rq_pages = wdata->pages; + rqst.rq_offset = wdata->page_offset; rqst.rq_npages = wdata->nr_pages; rqst.rq_pagesz = wdata->pagesz; rqst.rq_tailsz = wdata->tailsz; diff --git a/fs/cifs/smb2pdu.c b/fs/cifs/smb2pdu.c index 6c22da8..f603fbe 100644 --- a/fs/cifs/smb2pdu.c +++ b/fs/cifs/smb2pdu.c @@ -3046,6 +3046,7 @@ smb2_async_writev(struct cifs_writedata *wdata, rqst.rq_iov = iov; rqst.rq_nvec = 2; rqst.rq_pages = wdata->pages; + rqst.rq_offset = wdata->page_offset; rqst.rq_npages = wdata->nr_pages; rqst.rq_pagesz = wdata->pagesz; rqst.rq_tailsz = wdata->tailsz;