Received: by 2002:a05:6358:3188:b0:123:57c1:9b43 with SMTP id q8csp29474182rwd; Wed, 5 Jul 2023 12:22:37 -0700 (PDT) X-Google-Smtp-Source: APBJJlGt4RFb99LQVYkrXgQL2WsQgAIIqk+xkKU82m6lMhNkbJCH+WQjqCNl73Y8LkeG5zwK+X2u X-Received: by 2002:a17:90b:4d83:b0:259:24c4:4dd4 with SMTP id oj3-20020a17090b4d8300b0025924c44dd4mr12915014pjb.10.1688584956822; Wed, 05 Jul 2023 12:22:36 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1688584956; cv=none; d=google.com; s=arc-20160816; b=o7a5gVpWDzOWzZJuKTXihl6UECkxVxF6KqlgToy+I71/H/FrTTAEuz52tPt8ekS//T 4rqfrN/MpfjBAXypuokSI2syP1bXfFE/g4LiZF19vnJVXsaJuAR5Od3D6F3Jh12AzJEH hZ9/2H+/3rhyQsgA+d+Ur0Dnasc7fXf5Os3JNzpq4Q5X1EnAbnyqmmlw7UksHJDY5F9A PiaMQq/wP7eBI82nwsYetd2sJRJFDG6VdYFMMqOGXC6suwn25yxiC1InJHv5K7/Ly/Ea U0JrGns9ur8K1MLJy0Fe2yIrUi/FeJ/8F3ea54DpVCh5tZW8PLLNBzxnBM0wNnN+Tymw nusA== 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=8T8+NSX7bDEhf8RGg0k1fsoDqEa1IlRejydP1SKXk60=; fh=oZBkGLGxLa12UvCOqW6OqTg+fFLuGFOGuObjtaECCwA=; b=qVeBQshurQfNqSyVdwV2LcSV86oh5etKoIaCywPd8yBXgZCftFvqAynsIReDT88Cu7 qQowTTbUez4FIFvDEZ8FowzBHsQvLZRxWJEv0unAPjReUH64OGqYFIV6pAPvDz7tIzeY RAJj7JwbRrmbeIJtPYBXLL0Uwfr9wIez8SfmlPJMbbyZIAEuS4L6fDAYOSOIxFipdkGF WUAw0ZQ91m/4ihitKnhoNrsXnW5Bela6TBROyvPcYD4t6Yp5uwD2i7z0IfF9joLOE1Kz JJVEIfNb3eSbdPq15Yh+ZMgcSxMFpP+5uwKKto0im7bsyFF+amPkEFnWcrqRzxv4JsPC fwUg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=pM+4NH2M; 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 n18-20020a17090aab9200b0026309d5ac17si2142896pjq.71.2023.07.05.12.22.21; Wed, 05 Jul 2023 12:22:36 -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=pM+4NH2M; 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 S233472AbjGETDc (ORCPT + 99 others); Wed, 5 Jul 2023 15:03:32 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:42908 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S233396AbjGETD2 (ORCPT ); Wed, 5 Jul 2023 15:03:28 -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 69D081985; Wed, 5 Jul 2023 12:03:20 -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 D2762616C4; Wed, 5 Jul 2023 19:03:19 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 35903C433C8; Wed, 5 Jul 2023 19:03:18 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1688583799; bh=Y/meLmwCWNAsn5J38ZDDhtkdnkG182kUzNf/PHgf2VI=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=pM+4NH2Mids4CxpLS5rSap4VcC4ygdGDr8BXUIqOTu8qDZ0KNP0PhUxrSYwjdG2tm TNg4o34B2caVF+Ipkq7ZskuLUN6XwbobArABtlRZCnHavfYBUY123MGBOgOYAqMicm ixxlWo8iaZ0xg49JGuSmrCF+oLZjIFCcD6BahO8Dm1kEIng0qGhfSs1OcTyf3FIBP+ K58HB33IflEhe5BayuDCKNhAkauNUNi4cZHi+QBXYbcMFQtLMEHJcLrXwMULmPWdRS oShNaFMagHkUpIx06ahi+hey20WIelFocVARFoSJuFKOfrj3dq9czS3726+0xGw5jl 4acVjPoiSzdxw== From: Jeff Layton To: Christian Brauner , Steve French , Paulo Alcantara , Ronnie Sahlberg , Shyam Prasad N , Tom Talpey Cc: Al Viro , Jan Kara , linux-fsdevel@vger.kernel.org, linux-kernel@vger.kernel.org, linux-cifs@vger.kernel.org, samba-technical@lists.samba.org Subject: [PATCH v2 06/92] cifs: update the ctime on a partial page write Date: Wed, 5 Jul 2023 15:00:33 -0400 Message-ID: <20230705190309.579783-6-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 POSIX says: "Upon successful completion, where nbyte is greater than 0, write() shall mark for update the last data modification and last file status change timestamps of the file..." Add the missing ctime update. Signed-off-by: Jeff Layton --- fs/smb/client/file.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/fs/smb/client/file.c b/fs/smb/client/file.c index 879bc8e6555c..0a5fe8d5314b 100644 --- a/fs/smb/client/file.c +++ b/fs/smb/client/file.c @@ -2596,7 +2596,7 @@ static int cifs_partialpagewrite(struct page *page, unsigned from, unsigned to) write_data, to - from, &offset); cifsFileInfo_put(open_file); /* Does mm or vfs already set times? */ - inode->i_atime = inode->i_mtime = current_time(inode); + inode->i_atime = inode->i_mtime = inode->i_ctime = current_time(inode); if ((bytes_written > 0) && (offset)) rc = 0; else if (bytes_written < 0) -- 2.41.0