Received: by 2002:a25:8b91:0:0:0:0:0 with SMTP id j17csp9773419ybl; Thu, 26 Dec 2019 05:10:06 -0800 (PST) X-Google-Smtp-Source: APXvYqy9dc2jLqBgzdXjFNpgl9N2XKggySSAuf/KX5oarndan49TogGDj3W+AlJr2gavBkqozp/s X-Received: by 2002:a05:6830:1e67:: with SMTP id m7mr46958260otr.262.1577365806057; Thu, 26 Dec 2019 05:10:06 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1577365806; cv=none; d=google.com; s=arc-20160816; b=lcGDcT45u7Kl30q0c+czmzVLfXgYfZKwHultVpqCuu/rP7a74EGbT2cLWWEkAU3lkp Y2A8Kn5BvEkJ4bYryNgmo6mOb4EfVXWDEAE/+zNlpOXQb1ensXuAn+mFg67uQJiBuBI/ GtjlB2mCczAlh5/a3ofVKov7Gr5rjB4e+rGHw8D/Atcdd3t8ap+hPVABrTKj2FOw5xRP MKdsI1GILII2gfEy9lD0KL6ye906s/jL0+aBt61HaOblHyHJtYjPeim2VrLfV+/VxZJj JgGuKjjncCGWX72Zv8ImurmwQQ14on8Ce8jDXHUqHZWnG49CIFokOkJErr617HYIE38F NOXw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :references:in-reply-to:date:cc:to:from:subject:message-id :dkim-signature; bh=XX+uD6u26dDFDC626LQb9o9CPegZnPxVtayuH9+QP+c=; b=FTaBZSFnL3/GQLWCAtVi3XZ7xBU3W0Rc2TkCpbINGwMRQMrkrSjjj1YUjRMCfBdTUH /TwNbUCz23z1/xS9CWUTS+yOFigoA1fMkQRqKA7/+Qz44PtmaN8CLRoWHisT9Pg2n47t yJ9Gg1bSXCzQeBHUiSRi6e6KeR1uD0TzqZ50FMpxUG/j2nhoQurAqDES2hAkaSL61bbV UE6J3K4MrYoH2HYf5enDD/q+QMzKBCMCQASC96NSsYuDfqq6IPIHsAMzLN43Pvqumbnx 0thzejT4LyeSOsUXFD96bUs+tta+IFBh8yRYRAR3xV7PJ9WMDzZ+NOsE2CrQCEqemAwz oI+Q== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@dubeyko-com.20150623.gappssmtp.com header.s=20150623 header.b=yHMEur93; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id i2si14661152otc.130.2019.12.26.05.09.54; Thu, 26 Dec 2019 05:10:06 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@dubeyko-com.20150623.gappssmtp.com header.s=20150623 header.b=yHMEur93; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726697AbfLZNIo (ORCPT + 99 others); Thu, 26 Dec 2019 08:08:44 -0500 Received: from mail-lj1-f194.google.com ([209.85.208.194]:33543 "EHLO mail-lj1-f194.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726236AbfLZNIo (ORCPT ); Thu, 26 Dec 2019 08:08:44 -0500 Received: by mail-lj1-f194.google.com with SMTP id y6so16679528lji.0 for ; Thu, 26 Dec 2019 05:08:42 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=dubeyko-com.20150623.gappssmtp.com; s=20150623; h=message-id:subject:from:to:cc:date:in-reply-to:references :mime-version:content-transfer-encoding; bh=XX+uD6u26dDFDC626LQb9o9CPegZnPxVtayuH9+QP+c=; b=yHMEur933ZoxenJTF/O5tNptMe7y2msn2A4nAJAGHsuHLTSECG/y5MRFeXwBggLWqp /gqUCKjAPxCWnGxfttHxQxTr2RA4ccUj3nGztv6us+e2bFB3O6r1xR2yD1cLZH0LtVzp ChsZvQzl8eopBmxkxcXv9VU/PN/whUHhS01A2LOp6pkNxxw11O5CDI7yfNbaPUleWeL4 ejLUj6YVTtb2TFohC6tHr2y2CHtudkODp0kVhuMMNYxD4GMEVxc/L27eOg1VWDEeBApJ dcT2nk5ikZMCf8qoCiec2jRp0ShuHC3OXNaaJl2eKI+8DXD4GbCMsHYyeqDiBYk36kT3 wG+w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:message-id:subject:from:to:cc:date:in-reply-to :references:mime-version:content-transfer-encoding; bh=XX+uD6u26dDFDC626LQb9o9CPegZnPxVtayuH9+QP+c=; b=gOJBr5aH/O0K7WdGXrOe4EgisDRTh+89RIHyeeNjLwWy5EsjMyW0PstfCV/tno0tB2 i1+AQ9ejKkDW3NM81JRWkg0CJ6NcrOvvbS2Vmu2ZHOv6XiDqEXD05B7/IkypChFZThRs aUpItSO0H/xfOcBG2xVZhLAU2KvzUO6F9pzcsOGAr5eJOm7VTXMk6WGs62MsQhyh1BK0 wc4phbXZaH5hjz9qr95ePsC9znXBzKOGXT43JgkyiEGZmrZ6E1kXJZR4BXyz0Flc4wz/ rgsCADvx5pQoxSbSMR5OOntUbJlFUyIYKn8E2ySM//0nxSgQvQ2i6AsmVmq8hLqxG2wy EKHA== X-Gm-Message-State: APjAAAVq8tpA2pzIRStrcdwdNBT7PoqxrOZVugXF18ZGgeDj1QvvK34y 3OdMHuoiIAJY0vIeiAbcqKr2Xw== X-Received: by 2002:a05:651c:118b:: with SMTP id w11mr26296295ljo.54.1577365722046; Thu, 26 Dec 2019 05:08:42 -0800 (PST) Received: from msk1wst115n.omp.ru (mail.omprussia.ru. [5.134.221.218]) by smtp.gmail.com with ESMTPSA id d25sm12356658ljj.51.2019.12.26.05.08.41 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Thu, 26 Dec 2019 05:08:41 -0800 (PST) Message-ID: <61e43dcb781c9e880fac95b525830fd384de122a.camel@dubeyko.com> Subject: Re: [PATCH] f2fs: introduce DEFAULT_IO_TIMEOUT_JIFFIES From: Vyacheslav Dubeyko To: Geert Uytterhoeven Cc: Chao Yu , Jaegeuk Kim , linux-f2fs-devel@lists.sourceforge.net, Linux Kernel Mailing List , Chao Yu , Linux FS Devel Date: Thu, 26 Dec 2019 16:08:40 +0300 In-Reply-To: References: <20191223040020.109570-1-yuchao0@huawei.com> <1cc2d2a093ebb15a1fc6eb96d683e918a8d5a7d4.camel@dubeyko.com> Content-Type: text/plain; charset="UTF-8" X-Mailer: Evolution 3.28.5-0ubuntu0.18.04.1 Mime-Version: 1.0 Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi Geert, On Thu, 2019-12-26 at 11:43 +0100, Geert Uytterhoeven wrote: > Hi Vyacheslav, > > On Wed, Dec 25, 2019 at 10:58 AM Vyacheslav Dubeyko < > slava@dubeyko.com> wrote: > > On Mon, 2019-12-23 at 09:41 +0100, Geert Uytterhoeven wrote: > > > On Mon, Dec 23, 2019 at 5:01 AM Chao Yu > > > wrote: > > > > As Geert Uytterhoeven reported: > > > > > > > > for parameter HZ/50 in congestion_wait(BLK_RW_ASYNC, HZ/50); > > > > > > > > On some platforms, HZ can be less than 50, then unexpected 0 > > > > timeout > > > > jiffies will be set in congestion_wait(). > > > > It looks like that HZ could have various value on diferent > > platforms. > > So, why does it need to divide HZ on 50? Does it really necessary? > > Could it be used HZ only without the division operation? > > A timeout of HZ means 1 second. > HZ/50 means 20 ms, but has the risk of being zero, if HZ < 50. > > If you want to use a timeout of 20 ms, you best use > msecs_to_jiffies(20), > as that takes care of the special cases, and never returns 0. > The msecs_to_jiffies(20) looks much better for my taste. Maybe, we could use this as solution of the issue? Thanks, Viacheslav Dubeyko. > Gr{oetje,eeting}s, > > Geert >