From patchwork Thu May 17 11:33:17 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: =?utf-8?q?Andreas_Gr=C3=BCnbacher?= X-Patchwork-Id: 10406639 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id 78C9160230 for ; Thu, 17 May 2018 11:33:26 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id D8A0726E98 for ; Thu, 17 May 2018 11:33:23 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id CD0A828518; Thu, 17 May 2018 11:33:23 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-8.0 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, FREEMAIL_FROM, MAILING_LIST_MULTI, RCVD_IN_DNSWL_HI autolearn=ham version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 8929926E98 for ; Thu, 17 May 2018 11:33:23 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752176AbeEQLdV (ORCPT ); Thu, 17 May 2018 07:33:21 -0400 Received: from mail-wm0-f68.google.com ([74.125.82.68]:54481 "EHLO mail-wm0-f68.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752121AbeEQLdT (ORCPT ); Thu, 17 May 2018 07:33:19 -0400 Received: by mail-wm0-f68.google.com with SMTP id f6-v6so7784331wmc.4; Thu, 17 May 2018 04:33:18 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc; bh=UvCzzD0N+E53BQA+IXZ2XdiH/FbmeOgACI8PUXYhYQo=; b=KZ7DCtwWvhoTFr6Lp1jr1/+fje2GJyHUfbDFGhxY37dycBc1CnLTq15Ra7V1xIoUf4 O9fGIlGT23jNu6OREtYjSj346bYw1absoveC8IJZTyRXda8i2qZ1n+RNe1q6hWUp89VG y9wcnqD/ts6Bw8hOUOauiukKrdsh4yOy6EoHAL+y2tMlQ9OowFoOjqh+QQQstYu1A/G+ E0vbelLnAmBSddKZazjdM0Z5Q27ItVgwzZw+gfUVR7/H9GOHoSD7DNvDlRWwk/n2D1Ui C2cvo+XUtjcIuVeR2Rp290zJT3AlusBw9pVd87Ce37Orz/C32osMo5jjuHH+H3h9wWPD Hs5A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to:cc; bh=UvCzzD0N+E53BQA+IXZ2XdiH/FbmeOgACI8PUXYhYQo=; b=XL9wmCfg8lkLvrfTzRVpVWIkb6L20N6FTnvMY95Q6N/DlUac3hLbQzCrHzV3HMzZgp bwQ+9+XvxkOFgEAiOgOzp51PFh6A/gytxItHS4jI+Xc3NBOWHOZ45YfsVgJ3B3Zq5ThW sPSWnoF4aVYZhthUmdBnjPgyZWi4ITWCDWUgcCOduRpm9BG1ivAlsV8uec60Q5g0BceR 3CvxrqDZe1YG1s+a/9C7aBVL4J6X2Fgwtl0zH7l8g6avQP9A0rhZ0fFtzjFOKDp8QOgb OKmkOwOjdJaBZqF7Mrmu09EjIK/Rd02usdnrdRl95Y6gsMMo0byhvZhmPtop31ITzqX0 qVdQ== X-Gm-Message-State: ALKqPwd9z5fsrstavtG6oJLEcX0G+lhoBG4awA/xG2z3bYdX2TZds25a vWySQwu7yLyHAga7ArkFiTN7Xmcf/GeOoImsCPY= X-Google-Smtp-Source: AB8JxZrNs4UESWQsYHCppnDB530R04IpSA/C4PBUmefd7IGnxeDQAss+KAYS8n216oMbfuhalTJEz7jxdNWevPjiH90= X-Received: by 2002:a1c:c1c9:: with SMTP id r192-v6mr1449872wmf.120.1526556797630; Thu, 17 May 2018 04:33:17 -0700 (PDT) MIME-Version: 1.0 Received: by 2002:adf:9592:0:0:0:0:0 with HTTP; Thu, 17 May 2018 04:33:17 -0700 (PDT) In-Reply-To: <20180509074830.16196-5-hch@lst.de> References: <20180509074830.16196-1-hch@lst.de> <20180509074830.16196-5-hch@lst.de> From: =?UTF-8?Q?Andreas_Gr=C3=BCnbacher?= Date: Thu, 17 May 2018 13:33:17 +0200 Message-ID: Subject: Re: [PATCH 04/33] fs: remove the buffer_unwritten check in page_seek_hole_data To: Christoph Hellwig Cc: linux-xfs@vger.kernel.org, Linux FS-devel Mailing List , linux-block@vger.kernel.org, linux-mm@kvack.org Sender: linux-fsdevel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-fsdevel@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP 2018-05-09 9:48 GMT+02:00 Christoph Hellwig : > We only call into this function through the iomap iterators, so we already > know the buffer is unwritten. In addition to that we always require the > uptodate flag that is ORed with the result anyway. Please update the page_cache_seek_hole_data description as well: Thanks, Andreas --- a/fs/iomap.c +++ b/fs/iomap.c @@ -647,8 +647,8 @@ * Seek for SEEK_DATA / SEEK_HOLE in the page cache. * * Within unwritten extents, the page cache determines which parts are holes - * and which are data: unwritten and uptodate buffer heads count as data; - * everything else counts as a hole. + * and which are data: uptodate buffer heads count as data; everything else + * counts as a hole. * * Returns the resulting offset on successs, and -ENOENT otherwise. */