From patchwork Tue Jan 29 16:23:43 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Dave Kleikamp X-Patchwork-Id: 216600 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from merlin.infradead.org (merlin.infradead.org [IPv6:2001:4978:20e::2]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (Client did not present a certificate) by ozlabs.org (Postfix) with ESMTPS id D783E2C009D for ; Wed, 30 Jan 2013 03:25:24 +1100 (EST) Received: from localhost ([::1] helo=merlin.infradead.org) by merlin.infradead.org with esmtp (Exim 4.76 #1 (Red Hat Linux)) id 1U0Dz1-0006l4-FW; Tue, 29 Jan 2013 16:24:27 +0000 Received: from aserp1040.oracle.com ([141.146.126.69]) by merlin.infradead.org with esmtps (Exim 4.76 #1 (Red Hat Linux)) id 1U0Dyy-0006j7-AO for linux-mtd@lists.infradead.org; Tue, 29 Jan 2013 16:24:25 +0000 Received: from ucsinet22.oracle.com (ucsinet22.oracle.com [156.151.31.94]) by aserp1040.oracle.com (Sentrion-MTA-4.3.1/Sentrion-MTA-4.3.1) with ESMTP id r0TGOIvG012229 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK); Tue, 29 Jan 2013 16:24:19 GMT Received: from acsmt358.oracle.com (acsmt358.oracle.com [141.146.40.158]) by ucsinet22.oracle.com (8.14.4+Sun/8.14.4) with ESMTP id r0TGOHPs029298 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Tue, 29 Jan 2013 16:24:18 GMT Received: from abhmt104.oracle.com (abhmt104.oracle.com [141.146.116.56]) by acsmt358.oracle.com (8.12.11.20060308/8.12.11) with ESMTP id r0TGOH00013817; Tue, 29 Jan 2013 10:24:17 -0600 Received: from shaggy-t410.oracle.com (/99.156.91.244) by default (Oracle Beehive Gateway v4.0) with ESMTP ; Tue, 29 Jan 2013 08:24:17 -0800 Received: by shaggy-t410.oracle.com (Postfix, from userid 1000) id 607EA242C27; Tue, 29 Jan 2013 10:24:15 -0600 (CST) From: Dave Kleikamp To: Alexander Viro Subject: [PATCH V6 30/30] ubifs: convert file ops from aio_read/write to read/write_iter Date: Tue, 29 Jan 2013 10:23:43 -0600 Message-Id: <1359476623-10544-31-git-send-email-dave.kleikamp@oracle.com> X-Mailer: git-send-email 1.8.1.1 In-Reply-To: <1359476623-10544-1-git-send-email-dave.kleikamp@oracle.com> References: <1359476623-10544-1-git-send-email-dave.kleikamp@oracle.com> X-Source-IP: ucsinet22.oracle.com [156.151.31.94] X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20130129_112424_468861_9234D381 X-CRM114-Status: GOOD ( 13.06 ) X-Spam-Score: -4.9 (----) X-Spam-Report: SpamAssassin version 3.3.2 on merlin.infradead.org summary: Content analysis details: (-4.9 points) pts rule name description ---- ---------------------- -------------------------------------------------- -2.3 RCVD_IN_DNSWL_MED RBL: Sender listed at http://www.dnswl.org/, medium trust [141.146.126.69 listed in list.dnswl.org] -0.0 SPF_PASS SPF: sender matches SPF record -0.7 RP_MATCHES_RCVD Envelope sender domain matches handover relay domain -1.9 BAYES_00 BODY: Bayes spam probability is 0 to 1% [score: 0.0000] 0.0 UNPARSEABLE_RELAY Informational: message has unparseable relay lines Cc: Artem Bityutskiy , linux-kernel@vger.kernel.org, Adrian Hunter , Dave Kleikamp , linux-mtd@lists.infradead.org, linux-fsdevel@vger.kernel.org, Zach Brown , "Maxim V. Patlasov" X-BeenThere: linux-mtd@lists.infradead.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: Linux MTD discussion mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Sender: linux-mtd-bounces@lists.infradead.org Errors-To: linux-mtd-bounces+incoming=patchwork.ozlabs.org@lists.infradead.org Signed-off-by: Dave Kleikamp Cc: Artem Bityutskiy Cc: Adrian Hunter Cc: linux-mtd@lists.infradead.org --- fs/ubifs/file.c | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/fs/ubifs/file.c b/fs/ubifs/file.c index 5bc7781..cfe6210 100644 --- a/fs/ubifs/file.c +++ b/fs/ubifs/file.c @@ -44,7 +44,7 @@ * 'ubifs_writepage()' we are only guaranteed that the page is locked. * * Similarly, @i_mutex is not always locked in 'ubifs_readpage()', e.g., the - * read-ahead path does not lock it ("sys_read -> generic_file_aio_read -> + * read-ahead path does not lock it ("sys_read -> generic_file_read_iter -> * ondemand_readahead -> readpage"). In case of readahead, @I_SYNC flag is not * set as well. However, UBIFS disables readahead. */ @@ -1394,8 +1394,8 @@ static int update_mctime(struct ubifs_info *c, struct inode *inode) return 0; } -static ssize_t ubifs_aio_write(struct kiocb *iocb, const struct iovec *iov, - unsigned long nr_segs, loff_t pos) +static ssize_t ubifs_write_iter(struct kiocb *iocb, struct iov_iter *iter, + loff_t pos) { int err; struct inode *inode = iocb->ki_filp->f_mapping->host; @@ -1405,7 +1405,7 @@ static ssize_t ubifs_aio_write(struct kiocb *iocb, const struct iovec *iov, if (err) return err; - return generic_file_aio_write(iocb, iov, nr_segs, pos); + return generic_file_write_iter(iocb, iter, pos); } static int ubifs_set_page_dirty(struct page *page) @@ -1580,8 +1580,8 @@ const struct file_operations ubifs_file_operations = { .llseek = generic_file_llseek, .read = do_sync_read, .write = do_sync_write, - .aio_read = generic_file_aio_read, - .aio_write = ubifs_aio_write, + .read_iter = generic_file_read_iter, + .write_iter = ubifs_write_iter, .mmap = ubifs_file_mmap, .fsync = ubifs_fsync, .unlocked_ioctl = ubifs_ioctl,