From patchwork Fri Dec 4 21:21:59 2009 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Manoj Iyer X-Patchwork-Id: 40369 X-Patchwork-Delegate: apw@canonical.com Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from chlorine.canonical.com (chlorine.canonical.com [91.189.94.204]) by ozlabs.org (Postfix) with ESMTP id 6F7F5B7C04 for ; Sat, 5 Dec 2009 08:22:17 +1100 (EST) Received: from localhost ([127.0.0.1] helo=chlorine.canonical.com) by chlorine.canonical.com with esmtp (Exim 4.60) (envelope-from ) id 1NGfbL-0003FC-Qe; Fri, 04 Dec 2009 21:22:07 +0000 Received: from adelie.canonical.com ([91.189.90.139]) by chlorine.canonical.com with esmtp (Exim 4.60) (envelope-from ) id 1NGfbG-0003F5-Gq for kernel-team@lists.ubuntu.com; Fri, 04 Dec 2009 21:22:02 +0000 Received: from hutte.canonical.com ([91.189.90.181]) by adelie.canonical.com with esmtp (Exim 4.69 #1 (Debian)) id 1NGfbG-0008S4-Cu; Fri, 04 Dec 2009 21:22:02 +0000 Received: from [70.114.236.114] (helo=hungry.local) by hutte.canonical.com with esmtpsa (TLS-1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.69) (envelope-from ) id 1NGfbG-0007AQ-2F; Fri, 04 Dec 2009 21:22:02 +0000 Date: Fri, 4 Dec 2009 15:21:59 -0600 (CST) From: Manoj Iyer To: iscsitarget-devel@lists.sourceforge.net Subject: [PATCH] replace sync_page_range() with generic_write_sync() in file-io.c Message-ID: User-Agent: Alpine 2.00 (DEB 1167 2008-08-23) MIME-Version: 1.0 Cc: Ubuntu Kernel Team X-BeenThere: kernel-team@lists.ubuntu.com X-Mailman-Version: 2.1.8 Precedence: list Reply-To: Manoj Iyer List-Id: Kernel team discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: kernel-team-bounces@lists.ubuntu.com Errors-To: kernel-team-bounces@lists.ubuntu.com ---- resending patch, my previous mail bounced coz of membership requirement ---- sync_page_range() was recently removed from 2.6, this causes the iscsi-target build to fail in file-io.c. possibly sync_page_range() can be replaced with generic_write_sync() ? cheers --- manjo Index: kernel/file-io.c =================================================================== --- kernel/file-io.c (revision 276) +++ kernel/file-io.c (working copy) @@ -75,8 +75,6 @@ static int fileio_sync(struct iet_volume *lu, struct tio *tio) { struct fileio_data *p = lu->private; - struct inode *inode = p->filp->f_dentry->d_inode; - struct address_space *mapping = inode->i_mapping; loff_t ppos, count; int res; @@ -88,7 +86,7 @@ count = lu->blk_cnt << lu->blk_shift; } - res = sync_page_range(inode, mapping, ppos, count); + res = generic_write_sync(p->filp, ppos, count); if (res) { eprintk("I/O error: syncing pages failed: %d\n", res); return -EIO;