From mboxrd@z Thu Jan 1 00:00:00 1970 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 0F2DBC433FE for ; Fri, 30 Sep 2022 22:11:27 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232629AbiI3WLZ (ORCPT ); Fri, 30 Sep 2022 18:11:25 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:39242 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232631AbiI3WLQ (ORCPT ); Fri, 30 Sep 2022 18:11:16 -0400 Received: from mail-oa1-f51.google.com (mail-oa1-f51.google.com [209.85.160.51]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 8694712084B; Fri, 30 Sep 2022 15:11:14 -0700 (PDT) Received: by mail-oa1-f51.google.com with SMTP id 586e51a60fabf-127dca21a7dso6941971fac.12; Fri, 30 Sep 2022 15:11:14 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:x-gm-message-state:from:to:cc:subject:date; bh=XScEm+DuYC8Hlch7wHtQ1OIZ+cTh7jVexKgDloeMcLg=; b=yuNno+LYadq20Pk5744APf6fbk2XZ9RAlmPHZyUE0Qc+5mYcRO8VM514K9zlA8aG88 QhMqRE04F+7JLF4fPbUUvedtZ6cgYDIcV8l+RoE4qZB6gG4zLvMfMUQJtmAEUE2dvOLM 7bGSVYr8mETMgRfU1g9c7OHWE1xMikcEDHfE+ahkGNCpOgDW0GuH9oieY1zczPO985tN suGNZgv9IZf/r3dylZMG4fll8MhQ0suDgY4OiNBwhUkFNbsLOLpNjRbDijHg2LyJUP1F W5laPP4ymjkdVEbpY1zRPaSdLXbbq8Lo4pjFQ84DwvV3A/8/DjlHkFVpEGwChSaTl/fs dEdA== X-Gm-Message-State: ACrzQf1F/FJ1/Kv9CaOf68WwhKuqaMrvrKWEDIdinB19gIn49WY9csrf WWdJLMfAIKFvwbzxVQ25Dsl3MuxbQ4qx5ibrX7dOtb4UpyA= X-Google-Smtp-Source: AMsMyM4m1myiTvDwOzrvck//Wg05/NC3MMi+a1KNaAU13c6BxicLH27qNXmeVrDg4jVPM5wJUVs3p+ubk/boXSl7Kdk= X-Received: by 2002:a05:6870:a70f:b0:127:666a:658 with SMTP id g15-20020a056870a70f00b00127666a0658mr156984oam.218.1664575873758; Fri, 30 Sep 2022 15:11:13 -0700 (PDT) MIME-Version: 1.0 References: <20220922041435.709119-1-namhyung@kernel.org> <88915C51-33CD-49A4-A9E0-F5F5ECDEA0C7@gmail.com> In-Reply-To: <88915C51-33CD-49A4-A9E0-F5F5ECDEA0C7@gmail.com> From: Namhyung Kim Date: Fri, 30 Sep 2022 15:11:02 -0700 Message-ID: Subject: Re: [PATCH] perf stat: Support old kernels for bperf cgroup counting To: Arnaldo Carvalho de Melo Cc: Jiri Olsa , Tejun Heo , Zefan Li , Johannes Weiner , cgroups , Arnaldo Carvalho de Melo , LKML , linux-perf-users , Song Liu , bpf Content-Type: text/plain; charset="UTF-8" Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Fri, Sep 30, 2022 at 3:00 PM Arnaldo Carvalho de Melo wrote: > > > > On September 30, 2022 6:56:40 PM GMT-03:00, Namhyung Kim wrote: > >Hi Jiri, > > > >On Fri, Sep 30, 2022 at 2:44 PM Jiri Olsa wrote: > >> > >> On Wed, Sep 21, 2022 at 09:14:35PM -0700, Namhyung Kim wrote: > >> > The recent change in the cgroup will break the backward compatiblity in > >> > the BPF program. It should support both old and new kernels using BPF > >> > CO-RE technique. > >> > > >> > Like the task_struct->__state handling in the offcpu analysis, we can > >> > check the field name in the cgroup struct. > >> > > >> > Signed-off-by: Namhyung Kim > >> > --- > >> > Arnaldo, I think this should go through the cgroup tree since it depends > >> > on the earlier change there. I don't think it'd conflict with other > >> > perf changes but please let me know if you see any trouble, thanks! > >> > >> could you please paste the cgroup tree link? > > > >Do you mean this? > > > > https://git.kernel.org/pub/scm/linux/kernel/git/tj/cgroup.git > > > > > Which branch and cset in that tree does you perf skel depends on? I believe it's for-6.1 and the cset is in https://git.kernel.org/pub/scm/linux/kernel/git/tj/cgroup.git/commit/?h=for-6.1&id=7f203bc89eb66d6afde7eae91347fc0352090cc3 Thanks, Namhyung From mboxrd@z Thu Jan 1 00:00:00 1970 From: Namhyung Kim Subject: Re: [PATCH] perf stat: Support old kernels for bperf cgroup counting Date: Fri, 30 Sep 2022 15:11:02 -0700 Message-ID: References: <20220922041435.709119-1-namhyung@kernel.org> <88915C51-33CD-49A4-A9E0-F5F5ECDEA0C7@gmail.com> Mime-Version: 1.0 Return-path: In-Reply-To: <88915C51-33CD-49A4-A9E0-F5F5ECDEA0C7-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> List-ID: Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: Arnaldo Carvalho de Melo Cc: Jiri Olsa , Tejun Heo , Zefan Li , Johannes Weiner , cgroups , Arnaldo Carvalho de Melo , LKML , linux-perf-users , Song Liu , bpf On Fri, Sep 30, 2022 at 3:00 PM Arnaldo Carvalho de Melo wrote: > > > > On September 30, 2022 6:56:40 PM GMT-03:00, Namhyung Kim wrote: > >Hi Jiri, > > > >On Fri, Sep 30, 2022 at 2:44 PM Jiri Olsa wrote: > >> > >> On Wed, Sep 21, 2022 at 09:14:35PM -0700, Namhyung Kim wrote: > >> > The recent change in the cgroup will break the backward compatiblity in > >> > the BPF program. It should support both old and new kernels using BPF > >> > CO-RE technique. > >> > > >> > Like the task_struct->__state handling in the offcpu analysis, we can > >> > check the field name in the cgroup struct. > >> > > >> > Signed-off-by: Namhyung Kim > >> > --- > >> > Arnaldo, I think this should go through the cgroup tree since it depends > >> > on the earlier change there. I don't think it'd conflict with other > >> > perf changes but please let me know if you see any trouble, thanks! > >> > >> could you please paste the cgroup tree link? > > > >Do you mean this? > > > > https://git.kernel.org/pub/scm/linux/kernel/git/tj/cgroup.git > > > > > Which branch and cset in that tree does you perf skel depends on? I believe it's for-6.1 and the cset is in https://git.kernel.org/pub/scm/linux/kernel/git/tj/cgroup.git/commit/?h=for-6.1&id=7f203bc89eb66d6afde7eae91347fc0352090cc3 Thanks, Namhyung