Received: by 2002:a25:ca44:0:0:0:0:0 with SMTP id a65csp145726ybg; Tue, 28 Jul 2020 02:11:11 -0700 (PDT) X-Google-Smtp-Source: ABdhPJxckJm/sP188HRKqw5wOTLWTMDucW7UNedJfHeFZx+m7DggOPlxmkrglRkYfWMFII3NLbmw X-Received: by 2002:a17:906:a1c7:: with SMTP id bx7mr24103371ejb.388.1595927470639; Tue, 28 Jul 2020 02:11:10 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1595927470; cv=none; d=google.com; s=arc-20160816; b=Y7ldWOu+jDswXKkYTAgzv0TBku5bR18IRHDruqGE9u8I1hL2YWEP+DdAT7pdxveAJk hAwrTOUViZzaLZwkR+V2i3HKei8IkWB8lKFGzyJFClR84YYNkx7hEgNzdtI/m+CMwP/m NYZHoPW91pL2cFMOdWDTXcwKKKcMBOFgdsLWlzcH4qgFFYij68SDcTPar6Kqqmir3d0j 8R9PmEJRmEidhDevGKp1yH3PcEnzzGiISCxGoE4cMv3889YGQh8P/xtVYuW5hG8cGb02 SPvtyZoPG1FX+HLlIMPaXb6fHxdEuoYSWYLNGJfwOGtobZr2x1WGqOdKEvPbpYjULS8l 5uDQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:in-reply-to :mime-version:user-agent:date:message-id:from:references:cc:to :subject; bh=eJ2JahNn6MRM+qHLEXw/jp0p7EDga9BkKbULZoFOgsM=; b=ojv4xIS4gfaVTQCed0ESXPCgT26HAvEH0kzkipaR0aYufGeKCDPskV5xteqYBo3dxW hpzLTyvZ2sUXBxMUXxAjPqyTlpGjegY8u7/eYYpUFRAGBKHncLnz3el2+9tzY9kXGtLf OyFn8nWi2Y9XIjqHuwFl32OZFUPfzyT3Bt6pkqRjGzw0J51Y+dMw8F8TQbOuSN11AEv8 kNDVGyWy4zySSoo/SOsUd6d/mdVwubQkGnkGzZkbk35GYzcPcsRLko+tJuHILAALHrT9 D6pHX9cANq11yimkiidjVlgNv33nI7pYmfvz1Or51SRVRSbM/FyeHqIqRPPbyEVo6TFf 87/g== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-ext4-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-ext4-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id gs8si6302291ejb.665.2020.07.28.02.10.39; Tue, 28 Jul 2020 02:11:10 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-ext4-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-ext4-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-ext4-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728296AbgG1JKg (ORCPT + 99 others); Tue, 28 Jul 2020 05:10:36 -0400 Received: from szxga04-in.huawei.com ([45.249.212.190]:8837 "EHLO huawei.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1727970AbgG1JKf (ORCPT ); Tue, 28 Jul 2020 05:10:35 -0400 Received: from DGGEMS407-HUB.china.huawei.com (unknown [172.30.72.60]) by Forcepoint Email with ESMTP id 22F452697912E371BFAF; Tue, 28 Jul 2020 17:10:33 +0800 (CST) Received: from [127.0.0.1] (10.174.178.38) by DGGEMS407-HUB.china.huawei.com (10.3.19.207) with Microsoft SMTP Server id 14.3.487.0; Tue, 28 Jul 2020 17:10:28 +0800 Subject: Re: [PATCH 3/6] ext4: Check journal inode extents more carefully To: Jan Kara , Ted Tso CC: , Lukas Czerner References: <20200727114429.1478-1-jack@suse.cz> <20200727114429.1478-4-jack@suse.cz> From: luomeng Message-ID: Date: Tue, 28 Jul 2020 17:10:28 +0800 User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:68.0) Gecko/20100101 Thunderbird/68.8.1 MIME-Version: 1.0 In-Reply-To: <20200727114429.1478-4-jack@suse.cz> Content-Type: text/plain; charset="gbk"; format=flowed Content-Transfer-Encoding: 8bit X-Originating-IP: [10.174.178.38] X-CFilter-Loop: Reflected Sender: linux-ext4-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-ext4@vger.kernel.org ?? 2020/7/27 19:44, Jan Kara ะด??: > -int ext4_data_block_valid(struct ext4_sb_info *sbi, ext4_fsblk_t start_blk, > +int ext4_inode_block_valid(struct inode *inode, ext4_fsblk_t start_blk, > unsigned int count) > { > struct ext4_system_blocks *system_blks; > @@ -344,8 +346,8 @@ int ext4_data_block_valid(struct ext4_sb_info *sbi, ext4_fsblk_t start_blk, > */ > rcu_read_lock(); > system_blks = rcu_dereference(sbi->system_blks); Because of a change in the function parameters??there is no 'sbi' declared. So there will be a compile error: fs/ext4/block_validity.c: In function ??ext4_inode_block_valid??: fs/ext4/block_validity.c:345:32: error: ??sbi?? undeclared (first use in this function) system_blks = rcu_dereference(sbi->system_blks); > - ret = ext4_data_block_valid_rcu(sbi, system_blks, start_blk, > - count); > + ret = ext4_data_block_valid_rcu(EXT4_SB(inode->i_sb), system_blks, > + start_blk, count, inode->i_ino); > rcu_read_unlock(); > return ret; > }