Received: by 2002:a05:6358:51dd:b0:131:369:b2a3 with SMTP id 29csp545859rwl; Wed, 9 Aug 2023 20:00:34 -0700 (PDT) X-Google-Smtp-Source: AGHT+IGdZQT5wkvD3A4zujSODor6afKMjan61WX6/1JYlucDsyMmcn5oVx+k71UP2SgG+/3PrgDN X-Received: by 2002:a05:6a00:18a5:b0:687:82f9:3d8d with SMTP id x37-20020a056a0018a500b0068782f93d8dmr1144405pfh.2.1691636434241; Wed, 09 Aug 2023 20:00:34 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1691636434; cv=none; d=google.com; s=arc-20160816; b=Bq4o7IYegsHsAaozq9YTaVpKMrVJ8jrxZVfwAfJ+QMyWGmmFPm4GXZeF+EdDV1lcvJ /Wv+vyMZ+yrqiA7UbZ7MZR3NUr9uK6RZKaIsw/76gTIuBttcQvUGMEC2CUOAdANOSPSK mbbt7xpJlRrEaYgnFY2/uWbclfqnc0v6QIb/tgPyuLCNL5VFOu8z37mPUHECP8WTIPJw 3REBPdMVUdApHnbi7t8ka6Uw7YLyEWY4sxFX35IhWENlTJ4TKIGA14o9zAKFibPawX8U d160LmbaawawN0nD5uBeO2zjsVBMroHO9TAYGYcNiOWfHurjysiwJSF/zudytSaQn/W1 cXDw== 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:subject:cc:to:from:date :dkim-signature; bh=kHnppH8OkHE3+a/XnL69tDk6mKlaaFEW6slsoeTV/t4=; fh=zZCUntHpFvRBPt77YEvDHl6ywIyh/phj6nRmmgAoFJU=; b=suTQn02uyMLteQxscZPDRL51DN+MP4UWBPqMImtFk9d4WdiRkr9aWB6bOdY0GBI3Ev hNK3ppv3QxBRJvjvP7Xre+IklTmYc1nAN36lGzbPPaOCByv1075pM+PREHyl4EfrEAZ+ lhzeevLlIqhcn6ypiDfyTIq96ULtbx7jPyKDwmNq4O2IyZdnt6XvrpJQWfJLrdxjxTD9 U/p6/bKcZwxX7K6JGy2g9DLb++jASdIhzdj4MuyMHDK5sap8vTwyAhj/3GF8eHuTJQNT e67RstV3VdsorSqvevvQaBwIza5+gTNOkg28mr+NIJ7QpdJcLXzXNZ+W834a+d3WTH73 VzKA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20221208 header.b=JAfqWE3U; 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=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id dw15-20020a056a00368f00b0068717205f44si588976pfb.154.2023.08.09.20.00.21; Wed, 09 Aug 2023 20:00:34 -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=@gmail.com header.s=20221208 header.b=JAfqWE3U; 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=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231230AbjHJCKb (ORCPT + 99 others); Wed, 9 Aug 2023 22:10:31 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:42464 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229543AbjHJCKa (ORCPT ); Wed, 9 Aug 2023 22:10:30 -0400 Received: from mail-pf1-x42d.google.com (mail-pf1-x42d.google.com [IPv6:2607:f8b0:4864:20::42d]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 1872210DA for ; Wed, 9 Aug 2023 19:10:30 -0700 (PDT) Received: by mail-pf1-x42d.google.com with SMTP id d2e1a72fcca58-686ba29ccb1so308824b3a.1 for ; Wed, 09 Aug 2023 19:10:30 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20221208; t=1691633429; x=1692238229; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:subject:cc:to:from:date:from:to:cc:subject:date :message-id:reply-to; bh=kHnppH8OkHE3+a/XnL69tDk6mKlaaFEW6slsoeTV/t4=; b=JAfqWE3U8jNNlTcGM/mwc4vGcdo7iZq4rU6vElQtrpc7VfBiz+GxIa9t1PD10V5aJn IqfW5QNYs78BJ3Wpd1i+mnZIsGBiaEvuoEQvWNz9GvFAvTCEFCInvqu2MbXnRYBUMtvF FLcjHMl8FnuEP2K2/9zocgsKB1aY3E5RJf4mP5EW1kvChgc/0x9rgDwvnOZbGD1yKw1c XiE1LfvwZMi3LapcNLMqSlksTuV/1nrsYp/dQP6Gktln6wD5bkrHKoO0eyX4zYetoUFr hSKLe8QazoaEeMWcwJPN+r45SM6txTzNCUSgKI+ROEGjZeU+ysCUejrPoNbKZmpUuBzG Z81Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1691633429; x=1692238229; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:subject:cc:to:from:date:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=kHnppH8OkHE3+a/XnL69tDk6mKlaaFEW6slsoeTV/t4=; b=kM9cE6fqrnOzqrpOUlHS+KAzQzPdWdIyekHbgw5jgoQCRcBHRafKLAwZ9DBG46SG+L CBQA7X6fk7KjRqjTzsZuDz67rv3Muoc4mu12q+mbgjDHJlrIMIZBy/b0xDFn0cAv1lO1 G8/ONfQMdeumDzZbobTcpgKhHUXEzjbMt5hghHTBoPAwcOm5WCCGdyeCVQwb4JlbNuoj YELUZ5fDyAMd7FXydiCKhoXjHcJI8GawP/8VSgIRTs5IC4TA0pNxeHKlmTuyRFeViGMP N3xps0/iA6rPC4yuCup3747cc6d7Mw8tGrw8w2Jp1pu7/wXvOTlNhJrz9geMxZxTJKo1 nS2w== X-Gm-Message-State: AOJu0Yz3vLOsIj2NLOahbrM1/H2b1HDZSt1oFCe/yScRIVTib4Yi/0I/ aOJxLnAkZV6QBTIQt2gjUIpLZvEbJyY= X-Received: by 2002:a05:6a00:189c:b0:687:1300:22ff with SMTP id x28-20020a056a00189c00b00687130022ffmr1294241pfh.1.1691633429485; Wed, 09 Aug 2023 19:10:29 -0700 (PDT) Received: from localhost ([156.236.96.163]) by smtp.gmail.com with ESMTPSA id 24-20020aa79218000000b006827c26f148sm256157pfo.195.2023.08.09.19.10.27 (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Wed, 09 Aug 2023 19:10:29 -0700 (PDT) Date: Thu, 10 Aug 2023 10:20:01 +0800 From: Yue Hu To: Ferry Meng Cc: linux-erofs@lists.ozlabs.org, LKML , huyue2@coolpad.com Subject: Re: [PATCH] erofs: refine warning messages for data I/Os Message-ID: <20230810102001.000035ca.zbestahu@gmail.com> In-Reply-To: <20230809060637.21311-1-mengferry@linux.alibaba.com> References: <20230809060637.21311-1-mengferry@linux.alibaba.com> X-Mailer: Claws Mail 3.17.3 (GTK+ 2.24.32; i686-w64-mingw32) MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,FREEMAIL_FROM, RCVD_IN_DNSWL_BLOCKED,SPF_HELO_NONE,SPF_PASS 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 On Wed, 9 Aug 2023 14:06:37 +0800 Ferry Meng wrote: erofs: refine warning messages for zdata I/Os > Don't warn users since -EINTR is returned due to user interruption. > Also suppress warning messages of readmore. > > Signed-off-by: Ferry Meng Reviewed-by: Yue Hu > --- > fs/erofs/zdata.c | 23 +++++++++-------------- > 1 file changed, 9 insertions(+), 14 deletions(-) > > diff --git a/fs/erofs/zdata.c b/fs/erofs/zdata.c > index de4f12152b62..53820271e538 100644 > --- a/fs/erofs/zdata.c > +++ b/fs/erofs/zdata.c > @@ -1848,15 +1848,10 @@ static void z_erofs_pcluster_readmore(struct z_erofs_decompress_frontend *f, > > page = erofs_grab_cache_page_nowait(inode->i_mapping, index); > if (page) { > - if (PageUptodate(page)) { > + if (PageUptodate(page)) > unlock_page(page); > - } else { > - err = z_erofs_do_read_page(f, page); > - if (err) > - erofs_err(inode->i_sb, > - "readmore error at page %lu @ nid %llu", > - index, EROFS_I(inode)->nid); > - } > + else > + (void)z_erofs_do_read_page(f, page); > put_page(page); > } > > @@ -1885,8 +1880,9 @@ static int z_erofs_read_folio(struct file *file, struct folio *folio) > /* if some compressed cluster ready, need submit them anyway */ > z_erofs_runqueue(&f, z_erofs_is_sync_decompress(sbi, 0), false); > > - if (err) > - erofs_err(inode->i_sb, "failed to read, err [%d]", err); > + if (err && err != -EINTR) > + erofs_err(inode->i_sb, "read error %d @ %lu of nid %llu", > + err, folio->index, EROFS_I(inode)->nid); > > erofs_put_metabuf(&f.map.buf); > erofs_release_pages(&f.pagepool); > @@ -1920,10 +1916,9 @@ static void z_erofs_readahead(struct readahead_control *rac) > head = (void *)page_private(page); > > err = z_erofs_do_read_page(&f, page); > - if (err) > - erofs_err(inode->i_sb, > - "readahead error at page %lu @ nid %llu", > - page->index, EROFS_I(inode)->nid); > + if (err && err != -EINTR) > + erofs_err(inode->i_sb, "readahead error %d @ %lu of nid %llu", > + err, page->index, EROFS_I(inode)->nid); > put_page(page); > } > z_erofs_pcluster_readmore(&f, rac, false);