Received: by 2002:a05:6358:3188:b0:123:57c1:9b43 with SMTP id q8csp3462168rwd; Mon, 22 May 2023 14:18:04 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ4SzSlJSxqaTYph43ifobgn2p/epG/SBVa3euFoBhL9uyNO2EZnP0K7V4ttlrIsmsrDT0hO X-Received: by 2002:a05:6a00:1505:b0:64c:c5c0:6e01 with SMTP id q5-20020a056a00150500b0064cc5c06e01mr17982147pfu.31.1684790284637; Mon, 22 May 2023 14:18:04 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1684790284; cv=none; d=google.com; s=arc-20160816; b=AF3hvbTOD90qzV6tFMB0S1Ezi2k3pQiUhObWCET4Fm/jBkljMYbUp5kSixqVSjn9oT Qi3+Q9dKzaDhBQHyKaSgh4aSYnYDxFdxduAv5ZuPJ/tC+1Nlh7lEcY7W6zLInRS7pIrv OcPc9K30gPS10OhXQIKKp2GR0Rgzy17WckGLXDn+WkRZhvxXlyJLh+PPnkI/mzvIe3ov y/esZfY/QHd7UFaICtT+7tDUytLi5JvbgYMKleRgDzSk1tM+vdsRK+/lyJisVD6Lh4KG Fg90trCPl4pJWwJgymTXdvJpOjEO54LEGqKBqgPW7SE2sQRN/fuHiUjFh3cM4Hd7qZGj SR/w== 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=oZIY9GTPXEPoSMZhe+ryqBhZXmHTyjPJq3hYdlaANCY=; b=mLuACHuMRj6WOLdtuRsEBn+wL/7HIIf3/GX+qwm8951bhzXWH8wGlO7/66N/2DPfPq L1gl10qa2KWZKehW0NFGXm+mN6emJGyOuzxcJllEXsg+NvRalDnV1R/s4hQXA0FTIeoK yFjLgtd0KGIcKAVl0NXjMMGkdtiucWKO/S651En1TjojLhrLynNQDzs1HWqb5XSXoDR/ 6SbjraPo+omouojpoD/nqRVKm/J0A59wKqcU90F+TsWeX9WLcmWE/SvN4CU9f++oHOUM 0E9zaYRuvdN56J5qJLK13XBLhqkuIYsgQQTrAdi2270PuxkTWPl8CNf7Rd+xG8wEgU66 m8Uw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@redhat.com header.s=mimecast20190719 header.b=MoY4Ojos; 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=redhat.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id k186-20020a6284c3000000b0064d109bad99si3497985pfd.29.2023.05.22.14.17.39; Mon, 22 May 2023 14:18:04 -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=@redhat.com header.s=mimecast20190719 header.b=MoY4Ojos; 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=redhat.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S235212AbjEVU65 (ORCPT + 99 others); Mon, 22 May 2023 16:58:57 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:57514 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234641AbjEVU6p (ORCPT ); Mon, 22 May 2023 16:58:45 -0400 Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.133.124]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 478F6BF for ; Mon, 22 May 2023 13:58:00 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1684789079; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=oZIY9GTPXEPoSMZhe+ryqBhZXmHTyjPJq3hYdlaANCY=; b=MoY4OjoskLooqeppXLTciFeL2Fj5ImoCxNXgjD4VK9WDd+1XuA4TBK5oWh8eiq0hBKbPIN ds7AP6tbgW92L+QH2OiezI6J1tXDBYfuWQACVo0Z95Zp5QIjDa/GAxmvW/bXJYLHL0LxOW o9ymf6QCQdJUJUZ8vAyXd60k4zxlzC4= Received: from mimecast-mx02.redhat.com (mx3-rdu2.redhat.com [66.187.233.73]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id us-mta-580-uxNl4WjbMQmkgPs6MbWOuQ-1; Mon, 22 May 2023 16:57:53 -0400 X-MC-Unique: uxNl4WjbMQmkgPs6MbWOuQ-1 Received: from smtp.corp.redhat.com (int-mx06.intmail.prod.int.rdu2.redhat.com [10.11.54.6]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx02.redhat.com (Postfix) with ESMTPS id 3732F28EC104; Mon, 22 May 2023 20:57:52 +0000 (UTC) Received: from warthog.procyon.org.uk (unknown [10.39.192.68]) by smtp.corp.redhat.com (Postfix) with ESMTP id 9B2D02166B25; Mon, 22 May 2023 20:57:49 +0000 (UTC) From: David Howells To: Jens Axboe , Al Viro , Christoph Hellwig Cc: David Howells , Matthew Wilcox , Jan Kara , Jeff Layton , David Hildenbrand , Jason Gunthorpe , Logan Gunthorpe , Hillf Danton , Christian Brauner , Linus Torvalds , linux-fsdevel@vger.kernel.org, linux-block@vger.kernel.org, linux-kernel@vger.kernel.org, linux-mm@kvack.org, John Hubbard , Dave Chinner , Christoph Hellwig Subject: [PATCH v21 1/6] iomap: Don't get an reference on ZERO_PAGE for direct I/O block zeroing Date: Mon, 22 May 2023 21:57:39 +0100 Message-Id: <20230522205744.2825689-2-dhowells@redhat.com> In-Reply-To: <20230522205744.2825689-1-dhowells@redhat.com> References: <20230522205744.2825689-1-dhowells@redhat.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Scanned-By: MIMEDefang 3.1 on 10.11.54.6 X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_NONE, RCVD_IN_MSPIKE_H2,SPF_HELO_NONE,SPF_NONE,T_SCC_BODY_TEXT_LINE autolearn=unavailable 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 ZERO_PAGE can't go away, no need to hold an extra reference. Signed-off-by: David Howells Reviewed-by: David Hildenbrand Reviewed-by: John Hubbard Reviewed-by: Dave Chinner Reviewed-by: Christoph Hellwig cc: Al Viro cc: linux-fsdevel@vger.kernel.org --- fs/iomap/direct-io.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/fs/iomap/direct-io.c b/fs/iomap/direct-io.c index 019cc87d0fb3..66a9f10e3207 100644 --- a/fs/iomap/direct-io.c +++ b/fs/iomap/direct-io.c @@ -203,7 +203,7 @@ static void iomap_dio_zero(const struct iomap_iter *iter, struct iomap_dio *dio, bio->bi_private = dio; bio->bi_end_io = iomap_dio_bio_end_io; - get_page(page); + bio_set_flag(bio, BIO_NO_PAGE_REF); __bio_add_page(bio, page, len, 0); iomap_dio_submit_bio(iter, dio, bio, pos); }