Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 96D47C636D6 for ; Thu, 23 Feb 2023 01:23:08 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S233163AbjBWBXH (ORCPT ); Wed, 22 Feb 2023 20:23:07 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:59092 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S233098AbjBWBXB (ORCPT ); Wed, 22 Feb 2023 20:23:01 -0500 Received: from mail-pl1-x62e.google.com (mail-pl1-x62e.google.com [IPv6:2607:f8b0:4864:20::62e]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id D565220057; Wed, 22 Feb 2023 17:22:57 -0800 (PST) Received: by mail-pl1-x62e.google.com with SMTP id e5so12115836plg.8; Wed, 22 Feb 2023 17:22:57 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=in-reply-to:content-disposition:mime-version:references:message-id :subject:cc:to:from:date:sender:from:to:cc:subject:date:message-id :reply-to; bh=W8JlHnEeXi6Ume/0LdrQ/Wv4xR86SmiNzZL4WaoGYxI=; b=jBFbnzW7xxeQ02Nn1kicQZiPHvOTRESreCrOnCUHxOap4EINoKmuv2fpdpUpZJkvMZ I18kqjayiDk2HybGVTLc89pQv5IAbL/Jj7ZTwCSOKFa3zolNkeWLV6NaqsDsH6FsTrEr uwSz/f64lMtjpjKIvK85XyFd+XSLI21mwFZd/bkDMqs+ZZpn0OGPaK8/O6H+my0RGouc F4PqwPgghTEBAG9VWjCWqLKv6rc9t56HzzjecLF2OS3wgSgetSwEBAmIZrN2mY5f6pvt YUw4v/hQA24d2GwnTtAvh/X/IRgb8aoOYPmKne5Ij0TMi4Ysi7FAa8vWI+8MS4owiQnH BNFw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=in-reply-to:content-disposition:mime-version:references:message-id :subject:cc:to:from:date:sender:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=W8JlHnEeXi6Ume/0LdrQ/Wv4xR86SmiNzZL4WaoGYxI=; b=1vRihr3rUKVp27WtegchYmuEoMUZ6Y6LjlVAeg8d3CRfkps55E952BVdGcas5lhEAZ zlIqiRHvtVyRodWyg8TZKvhpH+KwgZaO+NFwJHWXDg5k1D7jaNBvTqK3txhQ9DaA4EKj Ps3OlwirSBI6ElnKe+W06548oLOwQYDDc3KZ65fDmiIOqQ+ZPk6eccHqP9eNz0/2oiWX u1Z+QFI2NL6c6BCU8qbeP+LkROd2Z7wVSAFUc/SpTmwl8nvHunHtN4ixABxYioFqVjqN H40vX66RLfHNuBdiumg44p0MFE92HCwiK03tBSrji48/eLcFA/pPhdNqpgdSzXxJBNNU uH5A== X-Gm-Message-State: AO0yUKUGuA0XJRnQdHEgNRxDj1BtIJavEyQ+qH8lRGPpk+x6UbpJzE5B lbobbnYt+EVnqkRcza5BDrc= X-Google-Smtp-Source: AK7set8in1ZoSyRyaJNEnYf4iObtvL5YKbdNJ1Kol3k6xu9FgnbnNUwO+2zBhHO1PZl1PLKvXuxtkg== X-Received: by 2002:a17:902:ea07:b0:19a:9580:74c with SMTP id s7-20020a170902ea0700b0019a9580074cmr10568768plg.7.1677115376917; Wed, 22 Feb 2023 17:22:56 -0800 (PST) Received: from localhost ([2620:10d:c090:400::5:1bf3]) by smtp.gmail.com with ESMTPSA id y1-20020a1709027c8100b0019cbb055a95sm277694pll.94.2023.02.22.17.22.55 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 22 Feb 2023 17:22:55 -0800 (PST) Sender: Tejun Heo Date: Wed, 22 Feb 2023 15:22:53 -1000 From: Tejun Heo To: Alexei Starovoitov Cc: Alexei Starovoitov , Daniel Borkmann , Andrii Nakryiko , Martin KaFai Lau , Song Liu , Yonghong Song , John Fastabend , KP Singh , Stanislav Fomichev , Hao Luo , Jiri Olsa , bpf , Dave Marchevsky , David Vernet , LKML , Kernel Team Subject: Re: [PATCH bpf-next] bpf: Add bpf_cgroup_from_id() kfunc Message-ID: References: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, Feb 22, 2023 at 01:20:19PM -0800, Alexei Starovoitov wrote: > On Tue, Feb 21, 2023 at 2:09 PM Tejun Heo wrote: > > > > cgroup ID is an userspace-visible 64bit value uniquely identifying a given > > cgroup. As the IDs are used widely, it's useful to be able to look up the > > matching cgroups. Add bpf_cgroup_from_id(). > > > > Signed-off-by: Tejun Heo > > --- > > Documentation/bpf/kfuncs.rst | 10 +++-- > > kernel/bpf/helpers.c | 18 ++++++++ > > .../selftests/bpf/prog_tests/cgrp_kfunc.c | 1 + > > .../selftests/bpf/progs/cgrp_kfunc_common.h | 1 + > > .../selftests/bpf/progs/cgrp_kfunc_success.c | 42 +++++++++++++++++++ > > 5 files changed, 69 insertions(+), 3 deletions(-) > > Looks great, but could you please split it into two patches: > One for helpers.c and kfuncs.rst and another for selftests > with [PATCH bpf-next] selftests/bpf: subject ? > Doesn't matter much in this case, but it might ease backporting > and easier to track patches grouped by subj. Will do. Thanks. -- tejun