Received: by 2002:a05:6358:3188:b0:123:57c1:9b43 with SMTP id q8csp29486916rwd; Wed, 5 Jul 2023 12:35:00 -0700 (PDT) X-Google-Smtp-Source: APBJJlEhtYszClqK0MqVcyoC2XZO3IxcDCrNcxJJzLG8/zbXb6wzPz17Pa8ayyFx7+XztgQZc9Tu X-Received: by 2002:a05:6a21:6d92:b0:126:dd24:ca40 with SMTP id wl18-20020a056a216d9200b00126dd24ca40mr156143pzb.9.1688585699919; Wed, 05 Jul 2023 12:34:59 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1688585699; cv=none; d=google.com; s=arc-20160816; b=ajPlfK+ryDtFdm9+QRv4teL8JesWAOHhqu8ZuJ9FhOErJ7S1VO2zSBeGgapymeGnPe bYqQDpSKgGwPefuos2LCnD6kcCfqr46LTJ9Zc1Bjt4LbjlYYYn9X/dm0teBqwvmMxiO1 dYi2uGbo4oipXJdBGzHCey1lYrIF0XLy+b+fzljNdiqDeDXWlLCYv7LpaD9fogkqhnii FfCpMrKE6quRSkQUXkxyklhSWo8JarqesNPOD7lT10NSbbBagf/MQY/74kte29PmCPKX 4kKrwPquqRa4tUvHMkbrghYPeO5LVQ1WuGBqfWObmI1MgQneME6cH/774g9qMVYGvuCL pdyA== 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=xKAUX1gAiGeMAe4hDD9pQTq1NUzFHWrVLxy+KkYN7Hk=; fh=F0TBjGtdr07rIyL2N50xNH5K7Dnohp0JfmFjEcpmwnA=; b=HUb2YJvNPB555OW2uqwFEsBCsCpQMhKDB+O69j8dMxt4SgXeVUVsAmLZv4PrEzX6Bx 5bqmugzIEngbyDaA828sdhXuDoGJnswld1DBvFjaO4HIckHMIAElc9IEtU7/3U+/9quf ajQbw+w37RyCBZ/QNzGRRGNvHZ8JhQ697oPZRMbIlOjzQ5ogg9oG6jrNV4sbdMdNYEut FBKlc/CewQxsrdL+o+R0BGm8vgTaPc9NpuWx/NEhNkj0G5RUyqCgWbBunEJoeYjzKmcF HtktahdGTN2cZB2gcn1LrGsBMLs2vsAPR0a3UJKgFBDvX+q6/pa9udZuQUBC4b/JDvBy qugg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=NJB7XRGZ; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 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 out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id x184-20020a6386c1000000b0054fd504e80asi6658325pgd.542.2023.07.05.12.34.47; Wed, 05 Jul 2023 12:34:59 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=NJB7XRGZ; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S233441AbjGETDy (ORCPT + 99 others); Wed, 5 Jul 2023 15:03:54 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:43180 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S233496AbjGETDb (ORCPT ); Wed, 5 Jul 2023 15:03:31 -0400 Received: from dfw.source.kernel.org (dfw.source.kernel.org [IPv6:2604:1380:4641:c500::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 815A119BF; Wed, 5 Jul 2023 12:03:24 -0700 (PDT) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits)) (No client certificate requested) by dfw.source.kernel.org (Postfix) with ESMTPS id 5F6F8616FB; Wed, 5 Jul 2023 19:03:24 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 03D32C433C8; Wed, 5 Jul 2023 19:03:22 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1688583803; bh=L6EzW1gN0+SRZxIErz0sW6Tb73or6lNTvn+UvQ+UhLc=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=NJB7XRGZ9/2aNYHQfjzBlRCDmmvV+Ti6HLP+oIQ9g5KZrdjQjm0y+Jhl8rdVoiCqG yNAQ8W/mgqYsGvz9nBNxe8BJ21A3QMuv0zJQYxL9guo6asboijEkgDeRQSrBfSig/p y3um6RHGyvKy2DmOpaWHlvqNe+TYIVNtPu4I/5h85aojGvgO6+zM0Ewv62AZ5sItYJ BGFhUukmOesc8UyqgAF96u85MDN4IqtfnbWGFTIJ63/U+8my5inkcImSFEKNDrDBdG voaAhfGJLsCJB7IlrDCNOmZcmkHZs+5FZ8A/Dag+FPXM+vt3V1xLIcdts0ws7Ae+oa roSY/5/VnBDgw== From: Jeff Layton To: Christian Brauner , Hugh Dickins , Andrew Morton Cc: Al Viro , Jan Kara , linux-fsdevel@vger.kernel.org, linux-kernel@vger.kernel.org, linux-mm@kvack.org Subject: [PATCH v2 11/92] shmem: convert to simple_rename_timestamp Date: Wed, 5 Jul 2023 15:00:36 -0400 Message-ID: <20230705190309.579783-9-jlayton@kernel.org> X-Mailer: git-send-email 2.41.0 In-Reply-To: <20230705190309.579783-1-jlayton@kernel.org> References: <20230705185755.579053-1-jlayton@kernel.org> <20230705190309.579783-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,T_SCC_BODY_TEXT_LINE 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 A rename potentially involves updating 4 different inode timestamps. Convert to the new simple_rename_timestamp helper function. Signed-off-by: Jeff Layton --- mm/shmem.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/mm/shmem.c b/mm/shmem.c index 0f45e72a5ca7..1693134959c5 100644 --- a/mm/shmem.c +++ b/mm/shmem.c @@ -3306,9 +3306,7 @@ static int shmem_rename2(struct mnt_idmap *idmap, old_dir->i_size -= BOGO_DIRENT_SIZE; new_dir->i_size += BOGO_DIRENT_SIZE; - old_dir->i_ctime = old_dir->i_mtime = - new_dir->i_ctime = new_dir->i_mtime = - inode->i_ctime = current_time(old_dir); + simple_rename_timestamp(old_dir, old_dentry, new_dir, new_dentry); inode_inc_iversion(old_dir); inode_inc_iversion(new_dir); return 0; -- 2.41.0