Received: by 2002:a05:7412:2a8c:b0:e2:908c:2ebd with SMTP id u12csp3156862rdh; Thu, 28 Sep 2023 04:35:42 -0700 (PDT) X-Google-Smtp-Source: AGHT+IHv1sK4LVtP08k27N5P+euyP2GMNOVeYJcwUTIAlTSSibXBVstE/D70pQjEBddBuboNf6EA X-Received: by 2002:a05:6a00:2e96:b0:68c:6a77:4845 with SMTP id fd22-20020a056a002e9600b0068c6a774845mr1167395pfb.12.1695900942535; Thu, 28 Sep 2023 04:35:42 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1695900942; cv=none; d=google.com; s=arc-20160816; b=QUtUKFtFCrwNQ7OTcd/OxA1cfIztSN4ynaM6TQtWLjYbQPiZUrSbkqxTcfhek+9hmw L0C4xvpeqp4BhrGbfa+AU5Bbhso/UXWQVHwFM9/ziXFQZNS+y87L10/WeF4MjF0g82qf 0dZLucjIuE+mZ4sMyKavC8jUpKWla/UVFZbErcUb464xGqDOAyJzNe1Xdes22+ddRI9a xVpaPnvC0XO6F8qOtu2F9W7ZWaYV/I7LCTOvEY6H1g+TSzV1EHA7L6emrHE4TanyBmRv qP87vgNiq/l4kc8k2mHteYLnb6KNsogzbtQ/coOkXCpy9Jf0ucmUjuVA66Vk5HH7lxc2 OAkw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=cQftH2Fysoysf7bzBQ1Wrx3YxQ0oANUR0B/2tGQP8rE=; fh=c46m5ey7SAzRIMX10Og2AyTSJ44BS0wa+PqFJ/sgKgY=; b=oSs8iF3Vcg6aPdQGIubh97MU8+77tJJePYZD17GtDG6M9Fvs7+eau1VMRENDP2rBWL ZT2XTot+epa1/QvcXe6vUJFj43Ck9neMx9tdvYGakfSedVoaWY7UWzemwWss4TFRv5B5 xRTxX17A8nFzKJajTU7QtLVlLhxw5xrCd6S7E+NlPtNuoc7Nj80WaM8avp/BdUQadl/S NblWt5sN3j81G2hYvsvWeMIg1HGY/HvH7lFM1kWn7O3z7ICtWmKff2RKEEj/1KsoJvgO hm/9gaftwHhjEeOqiTkEfb6tMm1NmlTJEVw0Y3JJNp5sOk5uheYkik6/VNBqM6HtdbCJ oWNw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b="DuP/wv+a"; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:7 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from snail.vger.email (snail.vger.email. [2620:137:e000::3:7]) by mx.google.com with ESMTPS id v3-20020a655c43000000b00565e5916ab6si18245209pgr.598.2023.09.28.04.35.42 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 28 Sep 2023 04:35:42 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:7 as permitted sender) client-ip=2620:137:e000::3:7; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b="DuP/wv+a"; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:7 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by snail.vger.email (Postfix) with ESMTP id 45BF880FC721; Thu, 28 Sep 2023 04:22:47 -0700 (PDT) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.10 at snail.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232197AbjI1LWh (ORCPT + 99 others); Thu, 28 Sep 2023 07:22:37 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:48180 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231868AbjI1LWV (ORCPT ); Thu, 28 Sep 2023 07:22:21 -0400 Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id C513730C2; Thu, 28 Sep 2023 04:05:50 -0700 (PDT) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 1EAB7C433C9; Thu, 28 Sep 2023 11:05:47 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1695899148; bh=/OzpYTerhvIxS1I7NYNGCj7AfHI9vs2n0+hMzd5zjnw=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=DuP/wv+atLxYolVz3TsVy7tiJ9223Z4WvylhKVREmBxsCU+CN1xVxwsq/2PSJlKEj 0SeFCWDbJDEV2ld8iYUItZxaNPQKwnCASz+Napuig4CEsneZ1BjStWwJ4HAb+OA7cy SC9iG6X9UH80RRDJ1thj83wDn1k8f+8TcsKMLv9fjOR20LSA6H5T9oflMf7xc2GvJF O+eaXZLTN+H3mhRL9ttNl/zo0SzNSOVAPN7PO6IE8z90ITg/kKteuIEqbh6j7HpWoT JbjgE6gSfyISnBqy3vYQBrzvpMobxvgl/MqrGENhf1ZBiEdRbysBwAoi7vgbpwg+Lw 0YxsoKatJ28nA== From: Jeff Layton To: Alexander Viro , Christian Brauner , linux-fsdevel@vger.kernel.org, linux-kernel@vger.kernel.org Cc: Martin KaFai Lau , Song Liu , Yonghong Song , John Fastabend , KP Singh , Stanislav Fomichev , Hao Luo , Jiri Olsa , bpf@vger.kernel.org Subject: [PATCH 79/87] kernel/bpf: convert to new inode {a,m}time accessors Date: Thu, 28 Sep 2023 07:03:28 -0400 Message-ID: <20230928110413.33032-78-jlayton@kernel.org> X-Mailer: git-send-email 2.41.0 In-Reply-To: <20230928110413.33032-1-jlayton@kernel.org> References: <20230928110300.32891-1-jlayton@kernel.org> <20230928110413.33032-1-jlayton@kernel.org> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-4.4 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_MED, SPF_HELO_NONE,SPF_PASS autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (snail.vger.email [0.0.0.0]); Thu, 28 Sep 2023 04:22:47 -0700 (PDT) Signed-off-by: Jeff Layton --- kernel/bpf/inode.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/kernel/bpf/inode.c b/kernel/bpf/inode.c index 99d0625b6c82..1aafb2ff2e95 100644 --- a/kernel/bpf/inode.c +++ b/kernel/bpf/inode.c @@ -118,8 +118,7 @@ static struct inode *bpf_get_inode(struct super_block *sb, return ERR_PTR(-ENOSPC); inode->i_ino = get_next_ino(); - inode->i_atime = inode_set_ctime_current(inode); - inode->i_mtime = inode->i_atime; + simple_inode_init_ts(inode); inode_init_owner(&nop_mnt_idmap, inode, dir, mode); @@ -147,7 +146,7 @@ static void bpf_dentry_finalize(struct dentry *dentry, struct inode *inode, d_instantiate(dentry, inode); dget(dentry); - dir->i_mtime = inode_set_ctime_current(dir); + inode_set_mtime_to_ts(dir, inode_set_ctime_current(dir)); } static int bpf_mkdir(struct mnt_idmap *idmap, struct inode *dir, -- 2.41.0