Received: by 2002:ac0:a5a6:0:0:0:0:0 with SMTP id m35-v6csp65994imm; Fri, 31 Aug 2018 17:30:23 -0700 (PDT) X-Google-Smtp-Source: ANB0VdYK+VGNAh1KCE5OOUvjmiCSdgTVll/PKYFf32lqJJLs4TGaQmhC1IgJ/lOZBaQGDE7GRxKQ X-Received: by 2002:a63:f751:: with SMTP id f17-v6mr16667228pgk.410.1535761823880; Fri, 31 Aug 2018 17:30:23 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1535761823; cv=none; d=google.com; s=arc-20160816; b=lD9JGcj8iACYXITKQioybHbg2tKK7ZhTZ8doUanSoVlMoSZKvtvVIJpaTHHhZSgwD4 JsbqYAIX5Ht/GaLazIME8e1El+m2rlvWmCwvWOv9yGP8rfqnkii9d75E00UJWxxIKZvd Z03uXf0L1CkeUgsWdRxCSpfet81oD5P6rlGevlpiNzS20E2dFAivwr3VpeFc5gRVL4H9 0b9/pAudTETIYYaZIbVCULwBlJMCxv7Dqx0+VGtt6zb/7HXqKpoQMJs0L+ekrwl//e6G 8VHbrEIcBGwbS8WOroEKQWgsPykBOZm0Ks/2+SXOLywb7EgOrIs8761dNIyBj6gDriIT uu2A== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:from:date:dkim-signature:arc-authentication-results; bh=StEz1mAJv0KzVZGP1EaarXGr3LePzazclN3Lxla0Mp0=; b=oAfW7k8PHIzc414eeTaGLjjc69a13IVJ5hf81dR9d7hXgSCGTmt1x3X13s5Pti1RKO QSc0WNfheyYKfoweETSokeDTxc4e8cvDU1bMqzdWlOvi2p9jQxgj5p5SmRZ9mi8f1eo0 iIcIgDatN6sk1aZC9oDinJ9VaDBnZsY3GOQEowYeTPQ66NBYAbVZ9e0EFZ8B+UgFc7RR KcdWUFcqksTsaYJ6GujCXgOPehJsK/ejL7K28OvahJVg+bEzzxJIZ+ZczNH1V9RG+wo4 8WjeRv+2CFy2GkCtdc6JyDLI9aNztyKhYzvaC9eAp3e2A+QLY1wMS7cQdJfFSthnGnob R1FA== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@gmail.com header.s=20161025 header.b=Gx+AmDGB; 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; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id t64-v6si10816343pgc.516.2018.08.31.17.30.08; Fri, 31 Aug 2018 17:30:23 -0700 (PDT) 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=fail header.i=@gmail.com header.s=20161025 header.b=Gx+AmDGB; 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; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727601AbeIAEjB (ORCPT + 99 others); Sat, 1 Sep 2018 00:39:01 -0400 Received: from mail-pl1-f196.google.com ([209.85.214.196]:36308 "EHLO mail-pl1-f196.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726430AbeIAEjB (ORCPT ); Sat, 1 Sep 2018 00:39:01 -0400 Received: by mail-pl1-f196.google.com with SMTP id e11-v6so6159259plb.3; Fri, 31 Aug 2018 17:29:04 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=sender:date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to:user-agent; bh=StEz1mAJv0KzVZGP1EaarXGr3LePzazclN3Lxla0Mp0=; b=Gx+AmDGBv/s3qria3fxuFzM5YHMkloGdUQ+f0LNYy2qzNN30B5ctsJi/ZczOaKxzKp ol1RTToAh6Fj6/FRpNXItJchWh2ri4Ftfaqa40Rbk4yBilWli4TlVfNztJ9xCXSON6L+ c07PuyyoWxI5+MUUVc+AZ04hbwysuksBfIomrhqMhqHOEKHT6v5HSmGR7Ei9Td5ptZOU EgLPpQtHnNw2ubvxx5HOYe8yQ8LFsyn6A4K7fkISn5mwMaQ8sr94jEhPPUk8qOEXNNwQ iQd/kqmzja5JV3czwd08abHbjFXZgAz5cKOz572pe6TTJ9OX30XWZhB7p3PB+y6HLX2v /+5Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:date:from:to:cc:subject:message-id :references:mime-version:content-disposition:in-reply-to:user-agent; bh=StEz1mAJv0KzVZGP1EaarXGr3LePzazclN3Lxla0Mp0=; b=F4Fawt6t4S5Hcg2uGesVnxZLHGUokkaK+HCXsyWhQHBAKJfHfV18ULmDo/ryNT4/ym cD3V+EEjz78K+nhCAW0jvpbB76AqWsd7Tv/LEXY9GMZSQRSHOf/TN4Frl15lDIs61H60 ieMNtlBHqGV0ks242Y3Cymw3/7SjuIC6DE+NMkEq2+O9I8t7+fna/qXWo6IvcvBdk9JZ QP+Dce7offnrvOLsNVK6FyifKM3DiXNmblevnnOR4aaoqg53AfRkSgfU5OZoFokpAh61 /SqlyR/ZWpqlCjefv2RRuluzsz+ODFPQ83bMiDQg/DYGO7aLjoPTTK4qPlz/XdSLJqqc vtpA== X-Gm-Message-State: APzg51AXmW7zHKSrvRbeF92YcyoOIS18PrLwtn5lsukn85fhpwWCtV0+ Jtfy3oQkS900VKATmpAPVcg= X-Received: by 2002:a17:902:8b8b:: with SMTP id ay11-v6mr17533808plb.1.1535761743820; Fri, 31 Aug 2018 17:29:03 -0700 (PDT) Received: from localhost ([2620:10d:c090:180::1:a245]) by smtp.gmail.com with ESMTPSA id x4-v6sm14573522pfm.119.2018.08.31.17.29.02 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Fri, 31 Aug 2018 17:29:03 -0700 (PDT) Date: Fri, 31 Aug 2018 17:29:00 -0700 From: Tejun Heo To: Dennis Zhou Cc: Jens Axboe , Johannes Weiner , Josef Bacik , kernel-team@fb.com, linux-block@vger.kernel.org, cgroups@vger.kernel.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH 12/15] blkcg: cleanup and make blk_get_rl use blkg_lookup_create Message-ID: <20180901002900.GJ1488037@devbig004.ftw2.facebook.com> References: <20180831015356.69796-1-dennisszhou@gmail.com> <20180831015356.69796-13-dennisszhou@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20180831015356.69796-13-dennisszhou@gmail.com> User-Agent: Mutt/1.5.21 (2010-09-15) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, Aug 30, 2018 at 09:53:53PM -0400, Dennis Zhou wrote: > From: "Dennis Zhou (Facebook)" > > blk_get_rl is responsible for identifying which request_list a request > should be allocated to. Try get logic was added earlier, but > semantically the logic was not changed. > > This patch makes better use of the bio already having a reference to the > blkg in the hot path. The cold path uses a better fallback of > blkg_lookup_create rather than just blkg_lookup and then falling back to > the q->root_rl. If lookup_create fails with anything but -ENODEV, it > falls back to q->root_rl. > > A clarifying comment is added to explain why q->root_rl is used rather > than the root blkg's rl. > > Signed-off-by: Dennis Zhou Acked-by: Tejun Heo We're replicating that retry busy loop a lot. It'd be really great to factor that out and document what it's doing. Thanks. -- tejun