Received: by 2002:a05:6a10:206:0:0:0:0 with SMTP id 6csp1028883pxj; Wed, 2 Jun 2021 18:42:11 -0700 (PDT) X-Google-Smtp-Source: ABdhPJx4Nbk2LwP7fmiicNDf4XxzEI3jdWIwT13Jo/i6ClcHyS5DM67rPXT5QmdrnZP1juSz3gkq X-Received: by 2002:a17:907:2059:: with SMTP id pg25mr20652925ejb.130.1622684531446; Wed, 02 Jun 2021 18:42:11 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1622684531; cv=none; d=google.com; s=arc-20160816; b=IpIDgjBersFP5V/U18E1mc4Vb0Qnd4nHziFByxkTucfXmk3vK0Z+A2IgTCqnKk+6kO 0B1ctjREhC+mL6SpZXOL5bMBBFqC1Fgd/VfH2vmLICOehfofahgCPImulfMBSNW9Ye+a OfnNMLVbv3n6ggTHUF10w2VzBmCmUcRloy6+UkdE1cUE0zNy2NdqLVuE7x/5faxFBVDm tvuzZpBK4EAn0LJe6wTwztenvzXzqT7GcS8p1W4A5YSTBEZ7UhE8cHZeLQsKc5+6k0A6 7WLVfqnILvwCXc+CREwS2W6J7oMuETEoiTQdANrDVNV/qps4wQ/z87mKzkF7EsWDaaUV ZySg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date; bh=/MlEmwNGEpbw3WMqKMz7pHQ9c3tg/oSqGVst96/7VcA=; b=P6ACrxDkMIflWm9mAFxPxNrJsrOX08SewLvDBNHh9qaUtjooYO+SQK5PipXe/7Ngbs txH1R33Jc82RW+pgLiIBRX0PTEiXNb/cBDSRdR9ALIr1rf8rBwv9vyzjp3cHUgrz6nlP XyU0xRVIaIyQhZJNjsH15Efb9qG1BXitjt8jZCjnP2btBTAsfB8LY1vLLFihk6A2+9sU BU73ahiTnboZ1H3QEXhVTMtsUumTOx1W4tlDZBhfzBwnFFA2IXf0Ayc9i7Qw+c2XWcSw P/THiy56Z3EbyV6nY+RBZjPzojpH3hfjmIN8Uh5NxKkgOr5drSjeqw3aXjwmMT0CuNyz 1Fhw== 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 c13si1086630ejm.484.2021.06.02.18.41.47; Wed, 02 Jun 2021 18:42:11 -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 S229567AbhFCBnW (ORCPT + 99 others); Wed, 2 Jun 2021 21:43:22 -0400 Received: from outgoing-auth-1.mit.edu ([18.9.28.11]:42481 "EHLO outgoing.mit.edu" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S229553AbhFCBnV (ORCPT ); Wed, 2 Jun 2021 21:43:21 -0400 Received: from cwcc.thunk.org (pool-72-74-133-215.bstnma.fios.verizon.net [72.74.133.215]) (authenticated bits=0) (User authenticated as tytso@ATHENA.MIT.EDU) by outgoing.mit.edu (8.14.7/8.12.4) with ESMTP id 1531fVkH009840 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Wed, 2 Jun 2021 21:41:31 -0400 Received: by cwcc.thunk.org (Postfix, from userid 15806) id 137FB15C3CAF; Wed, 2 Jun 2021 21:41:31 -0400 (EDT) Date: Wed, 2 Jun 2021 21:41:31 -0400 From: "Theodore Ts'o" To: Ritesh Harjani Cc: linux-ext4@vger.kernel.org, harshadshirwadkar@gmail.com Subject: Re: [PATCH] ext4: Fix accessing uninit percpu counter variable with fast_commit Message-ID: References: <6cceb9a75c54bef8fa9696c1b08c8df5ff6169e2.1619692410.git.riteshh@linux.ibm.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <6cceb9a75c54bef8fa9696c1b08c8df5ff6169e2.1619692410.git.riteshh@linux.ibm.com> Precedence: bulk List-ID: X-Mailing-List: linux-ext4@vger.kernel.org On Thu, Apr 29, 2021 at 04:13:44PM +0530, Ritesh Harjani wrote: > When running generic/527 with fast_commit configuration, below issue is > seen on Power. > With fast_commit, during ext4_fc_replay() (which can be called from > ext4_fill_super()), if inode eviction happens then it can access an > uninitialized percpu counter variable. > > This patch adds the check b4 accessing the counters in ext4_free_inode() path. Applied, thanks. - Ted