Received: by 2002:a05:6358:3188:b0:123:57c1:9b43 with SMTP id q8csp26284212rwd; Mon, 3 Jul 2023 07:44:42 -0700 (PDT) X-Google-Smtp-Source: APBJJlEPGUjF0vYyFVqWyA6hVIWodQaXtOYzoEoVVGkbJ2penRZPPoZtVOjeLG7aEzInsqNrVHmD X-Received: by 2002:a17:902:7b95:b0:1b7:facb:2e79 with SMTP id w21-20020a1709027b9500b001b7facb2e79mr7702118pll.18.1688395481375; Mon, 03 Jul 2023 07:44:41 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1688395481; cv=none; d=google.com; s=arc-20160816; b=Kn98xdqyRQhl5K+1iR1VYq5ZbSDW0FjFx/UT7H89nacZ4n3AZbURaVD5CAY8c/g2Nj zJP76R3EcOioJfKhNKuz+AsrZ0Z6f6PLh5j2GjttaDd3SC2CNevmlAvYPoMltkIqCht/ Dcbl++tKG3KVNb7HKQ894QLu8i4edAMxNcEswiHbzFqYxulTRhoiJWHVHX+MO0jMQhOl tocCbnWIZqVQzkV/BtluVt0TU+cVC8gqLf7Y0g1VmXgJAN+qLZlg/bH47MSa8pzTRtFX H6J3g++8L0wK3zpQBwlYyqE1yzqsdYCcMWhEqPMdJfrc02UyCYwvfIWzkY/uJ7q3FJII 1sQQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:user-agent:in-reply-to:content-disposition :mime-version:references:message-id:subject:cc:to:from:date :dkim-signature; bh=So6jXT0WYt/MPFDr7iZzJBW84Dz1OXnGoKO73pWKQ2Y=; fh=AfCaarrJloRV9X8pgVoQkWOYp+JFhFv1/c5FQOfH+1Q=; b=PURehPUOwpInNSms7FvVUa+hqStgs/z/H6n3lilFYn7SbjNBGuRr0pAmqS3F8eTwRL ty3S4BqoiX3Tncd2JYrfbqbhtJiyor10NtH6cFIailfb0Zb1f7pvqj5TVl9m6WWihEqY nDQXYX5UeXl4hd+Qv6LIvRv1NBpAf7BXo8OuvJ2FZUNOIArwsgTgjVE8yW3gAdzkS1Hl 81lDlQbWDr6iWBibfZbqLKL/4ZsCAg3xhZlrR7aXGtKFiQpOawvuERQRNP9ih+UV3ZaY qa112Xpsiz5lCaMk+cST7gWm2jBVkZxv+PsSXveSMJAPuKqnAKtoQ+iLPenRlUELxxiT ZSfQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@nabijaczleweli.xyz header.s=202305 header.b=EsXuPnSi; 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=nabijaczleweli.xyz Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id j16-20020a170902da9000b001b891de7583si3365795plx.348.2023.07.03.07.44.27; Mon, 03 Jul 2023 07:44:41 -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=@nabijaczleweli.xyz header.s=202305 header.b=EsXuPnSi; 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=nabijaczleweli.xyz Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231309AbjGCOm3 (ORCPT + 99 others); Mon, 3 Jul 2023 10:42:29 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:56998 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231290AbjGCOm1 (ORCPT ); Mon, 3 Jul 2023 10:42:27 -0400 Received: from tarta.nabijaczleweli.xyz (unknown [139.28.40.42]) by lindbergh.monkeyblade.net (Postfix) with ESMTP id 806B2E74; Mon, 3 Jul 2023 07:42:23 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=nabijaczleweli.xyz; s=202305; t=1688395342; bh=SowbDY6YnsriPuN0djgR0SpF4itfDBztRXtp8moML7o=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=EsXuPnSi0xOmIDA9aB+N2jhQz9p0AOzj61HDIQTIJdzsnRWnGbDF/huwP1B2Kx+s4 GKbOd+IEDrPuqA8IYlgDBOn6HOsDRcDqUnEcUykq7eexZHfYx4Z3D/N8VYaI//nkFq WJkt4AYUkUzX5FoP6FZzjhpdok8hVpqoRCs4WGx2pbfxIKqawO2xUiBirSXWlAmDpE P8FV50NHcwz5rhWzafQCFhpJ2R+IRTIKCBssG8XeIt/RX5FLzqNjXl7fEXeVDbeqZB +llvKsXyqOJZ9yQPPq7UR0PsOfrof+FV3TOpe1D5CNEgiM3y7YUE3X9IMLGbTYa4l6 iS2kXT2bbIGnA== Received: from tarta.nabijaczleweli.xyz (unknown [192.168.1.250]) by tarta.nabijaczleweli.xyz (Postfix) with ESMTPSA id 9D49F1DC4; Mon, 3 Jul 2023 16:42:22 +0200 (CEST) Date: Mon, 3 Jul 2023 16:42:21 +0200 From: Ahelenia =?utf-8?Q?Ziemia=C5=84ska?= To: Christian Brauner Cc: Alexander Viro , Jan Kara , Amir Goldstein , Chung-Chiang Cheng , linux-fsdevel@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH v5 3/3] splice: fsnotify_access(in), fsnotify_modify(out) on success in tee Message-ID: <10d76dd8c85017ae3cd047c9b9a32e26daefdaa2.1688393619.git.nabijaczleweli@nabijaczleweli.xyz> References: MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="kdyjczppc4aawsdj" Content-Disposition: inline In-Reply-To: User-Agent: NeoMutt/20230517 X-Spam-Status: No, score=-1.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,PDS_RDNS_DYNAMIC_FP, RDNS_DYNAMIC,SPF_HELO_PASS,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=no 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 --kdyjczppc4aawsdj Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable Same logic applies here: this can fill up the pipe, and pollers that rely on getting IN_MODIFY notifications never wake up. Fixes: 983652c69199 ("splice: report related fsnotify events") Link: https://lore.kernel.org/linux-fsdevel/jbyihkyk5dtaohdwjyivambb2gffyjs= 3dodpofafnkkunxq7bu@jngkdxx65pux/t/#u Link: https://bugs.debian.org/1039488 Signed-off-by: Ahelenia Ziemia=C5=84ska Reviewed-by: Amir Goldstein Acked-by: Jan Kara --- fs/splice.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/fs/splice.c b/fs/splice.c index 5deb12d743b1..c49909dbf3c5 100644 --- a/fs/splice.c +++ b/fs/splice.c @@ -1815,6 +1815,11 @@ long do_tee(struct file *in, struct file *out, size_= t len, unsigned int flags) } } =20 + if (ret > 0) { + fsnotify_access(in); + fsnotify_modify(out); + } + return ret; } =20 --=20 2.39.2 --kdyjczppc4aawsdj Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQIzBAABCgAdFiEEfWlHToQCjFzAxEFjvP0LAY0mWPEFAmSi3k0ACgkQvP0LAY0m WPF9+Q/+J6bU/ve99xlYUDp9QIZx97GByxsAc60UTli80+/M2askRgboNzVMr54t WeQhhZ+c7qDVF5b6m6xBASK/cOF8jqSawpVZI7RY6FvxvaTl1gBxbaLdizgPIBc0 FpMxenMxQ/fxAlCj4OAYJRjSyunx8JciUdCo8iq9PPa+wGVFYa8Di8UMwzeh60r5 Yu+VQvsGvm74MpvZMhjtvQdljLMsdoZUx/fR4I4SIiyXP34sRm1wM+xOtlT9XO2H tm+6BizWGO0mvh6XDYeKRhgszHAKITKtH8RygIW+Vl7VrtqeUkNxh6g8XOKDQ/oK UlCnE8lWjXUq7iabebSTxBKUPSiCMMhe5tmQ77OL3RFq+frPLZV1uefCPkY/dHvP GjNnAp+vDMQ4kTN9sWK6TobWHVeN4ZQVK2EWm8jA4vTuNqp5DQTvc9pG43j/sXeC zXyUS9+KLuW6PBfJKqoULRnLgufbShCdp2EEdNpBqjgQWB8zMyYGbHq0WRVDvdfW 46irAZjFq6Hcma5/MwRU/fcPRm0TZR4uoyqiSnny7BhGoS8aCDkED5Qe8jWQt2p2 O4yuYvg5To59EL+oPrT5Oel3lRjjeysySFPEBpT3YDolvxaGnHeD1w5QVcitS5e1 2Tx8PIUIN+/ho8iKkqJBqvrUr+Idn+VF7PGi2R0IeOuPwNSmiIc= =htXo -----END PGP SIGNATURE----- --kdyjczppc4aawsdj--