From patchwork Sat Nov 30 14:03:38 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Zheng Liu X-Patchwork-Id: 295578 Return-Path: X-Original-To: patchwork-incoming@ozlabs.org Delivered-To: patchwork-incoming@ozlabs.org Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by ozlabs.org (Postfix) with ESMTP id 479742C007E for ; Sun, 1 Dec 2013 01:00:55 +1100 (EST) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751862Ab3K3OAy (ORCPT ); Sat, 30 Nov 2013 09:00:54 -0500 Received: from mail-pb0-f51.google.com ([209.85.160.51]:50570 "EHLO mail-pb0-f51.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751327Ab3K3OAx (ORCPT ); Sat, 30 Nov 2013 09:00:53 -0500 Received: by mail-pb0-f51.google.com with SMTP id up15so15913165pbc.24 for ; Sat, 30 Nov 2013 06:00:52 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=from:to:cc:subject:date:message-id; bh=uhiAbg7Ovt+L57fM52MJ9qVdWSAXREw/MgzBPd3CGzE=; b=eK1nX0d2Hp90TLAQQ/6Y1NJ0XHxrktthGRKc+D58xkQvxa2szFtR16gacxYWgE26+I BG4zVaIWEbZJOz9AXzbYgV8r1mpdDU/vc0R/eOQaATn7Ip5TqSYHgQjEjGi4jmZ8AUJs tPkEYMa/on/tMgPW9Q32PvFvRXYk+UU7uYvgiT18u+no3GO4e0D7IXMQTPe72RDcQQBB dMAybt+HeN73UM0CRsjJr3eirJ/IvYX1SH9xoyeS7FYW6ir7YAJXF7b8cwleX/PYMI8W P4z4QPfpLq1/nfQsGr+vaJT4h1K4XoJy0U95y+1e8lt80gNuv+9ldVLg9hc3b4r4vrKc 850w== X-Received: by 10.66.255.39 with SMTP id an7mr57257863pad.7.1385820052713; Sat, 30 Nov 2013 06:00:52 -0800 (PST) Received: from alpha.taobao.ali.com ([182.92.247.2]) by mx.google.com with ESMTPSA id e6sm1882469pbg.4.2013.11.30.06.00.50 for (version=TLSv1 cipher=RC4-SHA bits=128/128); Sat, 30 Nov 2013 06:00:51 -0800 (PST) From: Zheng Liu To: linux-ext4@vger.kernel.org Cc: Andreas Dilger , "Theodore Ts'o" , Lukas Czerner , Zheng Liu Subject: [PATCH] ext4: enable punch hole for bigalloc Date: Sat, 30 Nov 2013 22:03:38 +0800 Message-Id: <1385820218-4673-1-git-send-email-wenqing.lz@taobao.com> X-Mailer: git-send-email 1.7.9.7 Sender: linux-ext4-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-ext4@vger.kernel.org From: Zheng Liu After applied this commit (d23142c6), ext4 has supported punch hole for a file system with bigalloc feature. But we forgot to enable it. This commit fixes it. Cc: Andreas Dilger Cc: "Theodore Ts'o" Cc: Lukas Czerner Signed-off-by: Zheng Liu --- fs/ext4/inode.c | 5 ----- 1 file changed, 5 deletions(-) diff --git a/fs/ext4/inode.c b/fs/ext4/inode.c index 0757634..2d73587 100644 --- a/fs/ext4/inode.c +++ b/fs/ext4/inode.c @@ -3513,11 +3513,6 @@ int ext4_punch_hole(struct inode *inode, loff_t offset, loff_t length) if (!S_ISREG(inode->i_mode)) return -EOPNOTSUPP; - if (EXT4_SB(sb)->s_cluster_ratio > 1) { - /* TODO: Add support for bigalloc file systems */ - return -EOPNOTSUPP; - } - trace_ext4_punch_hole(inode, offset, length); /*