Received: by 2002:a05:6358:1087:b0:cb:c9d3:cd90 with SMTP id j7csp508110rwi; Tue, 18 Oct 2022 22:05:46 -0700 (PDT) X-Google-Smtp-Source: AMsMyM7gc4VEiGTZZJ+aNBvV2kUK1et8IJrbRWCjjDmVw/HX9dNfo8xjot1MAPRPxNM9EXfx8xkD X-Received: by 2002:a62:5a86:0:b0:563:553d:878e with SMTP id o128-20020a625a86000000b00563553d878emr6737322pfb.73.1666155946354; Tue, 18 Oct 2022 22:05:46 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1666155946; cv=none; d=google.com; s=arc-20160816; b=MyhkrIIWhcG0SB5qqayrU8aeV2+TyQhss4/0ezcIMP9TkZnI2V0QU/RLMOOcrW5CUZ ArQy3OXQuKhFMuUTmjv4wL5gKmStsJax9Zwok4BDm4OwalwbMpE5WGF4zkEtyUmuLj09 fmUzU6atbFvI0a7SU51+b3b9HT1NXNghPczFtfm4c5Q+vFgnRDimIq5+QJuJLYC1/QR0 s1CDf330YwYoFsYhwtKvCBzxQ2r3zuR7Z1HsKp03vOExbwOf8UIxb0MHIUgyiWhCZR9T KOIQFvJz5SQSTs5UB9iG8rLC5ENObF6lrFrixzGG+LUMhMEIhe65P6TRzfT73PHtkuy6 //qg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:cc:to:subject:message-id:date:from:in-reply-to :references:mime-version:dkim-signature; bh=35peG0IP4JiPLGxzfXqI/wQBb35mxDEhGOgvcGpqSyc=; b=APkbg4vH8UfkSRM+ktKUxy49mYE3cKfQG72PdmqIAmHS4N4KSH70wN63QwXgqSjVXE Qp2a6IkFxnlCQub2TdlVb34wOPRPkYh2wtNokPV5yC4Sty9prCBkiapJGJfk9MTqJori fgrz74mh7VuxJo1H4mDFMivhKnXz9121M+bniqTGYyDmxRfYdYFLJ+Wc06QFHnPFnY2L Hqf7rISVjf91tDkORrsTjM7qNM9t5ln32PPpD+MyQRT1EKOZpUAyJs2VVZzmSW4QHouX InGdJDM/jM+R2YCauCI/TLAJ6k2HW36pjnqK7taITVlhO2xoGbohQUVp8/quE5hskkqP v/AQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20210112 header.b="ZpI/bfSY"; 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 s1-20020a170902ea0100b0017f5dfeb82fsi17715357plg.204.2022.10.18.22.05.34; Tue, 18 Oct 2022 22:05:46 -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=20210112 header.b="ZpI/bfSY"; 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 S229680AbiJSE5g (ORCPT + 99 others); Wed, 19 Oct 2022 00:57:36 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:38126 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229437AbiJSE5e (ORCPT ); Wed, 19 Oct 2022 00:57:34 -0400 Received: from mail-ej1-x629.google.com (mail-ej1-x629.google.com [IPv6:2a00:1450:4864:20::629]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 565DB6704F; Tue, 18 Oct 2022 21:57:31 -0700 (PDT) Received: by mail-ej1-x629.google.com with SMTP id y14so37163232ejd.9; Tue, 18 Oct 2022 21:57:31 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:from:to:cc:subject:date:message-id:reply-to; bh=35peG0IP4JiPLGxzfXqI/wQBb35mxDEhGOgvcGpqSyc=; b=ZpI/bfSYkwg3sOORo0rZ+97ajfBfrUv07EUG4Z6ePd39nqsw7CORsekgXvDesNnoyy 2qN+GHiYzSb9mNJIprV+uaUPVIqSRhEHPXQ6FdcUGqkPrY5A8JXXQGLfR6CxHzidA79/ JVvGDL/k6wZOVuE4TyyqZabwGlRsxkpBxyqFQWnfRL4seu/JrO436voU6pfqdF6evLmj St3fXSbxAFCCR36wOfJLcYQ/k6yUs7k783B83+qSKtw+2gRbufgm5D0Lpj7j9y6FXvZf f+MEBtMmR53AT+DBh7L2XfoPO6jg9KhGpsOMUR0TyDVwjP7v7GhL/8t4WyjcV6b5rdLp aVQw== 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:message-id :reply-to; bh=35peG0IP4JiPLGxzfXqI/wQBb35mxDEhGOgvcGpqSyc=; b=W+J8sagKtr4RuTkYulbAw7dgsut5JpF2NBpHUaSEoegnQCl9FdzgPEyQLeQeZVy+7Q H43At41LZsZz26NV8VWWCuPK1XZOajDnVzoFXnmqCXGQ5xZARlNEhTJeWaYM/AaShiOe qDk4ivTXKa1nx2uCKETlKEjRJUxI4J/nBxwtJbYvq10LcpVA999TPiCEUNE2Htv++lSi 4lfs9sWsVTrXPss7jUtCSr6RH3U0Vm3PVpYNta1KkFdJxEGx9pU7l1Q0l7zn8rpXTtCC Rg4ieeApQKYlZeuQo7y38OahsqRBvKMRZt1TE8P8SzQIKoMwgnSafTO0Heg/6XKQSNwp r5GQ== X-Gm-Message-State: ACrzQf0p1HE3jrvVDFVQDUQ8kDuVPYCs1099gx+PcxCm6SYDUEmecdMs i7vZ3pDNcmASA9NZVHlM5IRqAQ9vPsUuNYaR16E= X-Received: by 2002:a17:907:1c98:b0:78d:3b06:dc8f with SMTP id nb24-20020a1709071c9800b0078d3b06dc8fmr5006085ejc.58.1666155449729; Tue, 18 Oct 2022 21:57:29 -0700 (PDT) MIME-Version: 1.0 References: <20221007081327.1047552-1-sumanthk@linux.ibm.com> In-Reply-To: From: Alexei Starovoitov Date: Tue, 18 Oct 2022 21:57:18 -0700 Message-ID: Subject: Re: [PATCH] bpf: fix sample_flags for bpf_perf_event_output To: Peter Zijlstra , Linus Torvalds Cc: Jiri Olsa , Sumanth Korikkar , bpf , Vasily Gorbik , Heiko Carstens , Ilya Leoshkevich , LKML , Namhyung Kim , Sven Schnelle , Thomas Richter , X86 ML , Daniel Borkmann Content-Type: text/plain; charset="UTF-8" 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_NONE,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 Fri, Oct 7, 2022 at 8:31 AM Peter Zijlstra wrote: > > On Fri, Oct 07, 2022 at 11:45:36AM +0200, Jiri Olsa wrote: > > On Fri, Oct 07, 2022 at 10:13:27AM +0200, Sumanth Korikkar wrote: > > > * Raw data is also filled by bpf_perf_event_output. > > > * Add sample_flags to indicate raw data. > > > * This eliminates the segfaults as shown below: > > > Run ./samples/bpf/trace_output > > > BUG pid 9 cookie 1001000000004 sized 4 > > > BUG pid 9 cookie 1001000000004 sized 4 > > > BUG pid 9 cookie 1001000000004 sized 4 > > > Segmentation fault (core dumped) > > > > > > Fixes: 838d9bb62d13 ("perf: Use sample_flags for raw_data") > > > Acked-by: Namhyung Kim > > > Signed-off-by: Sumanth Korikkar > > > > Acked-by: Jiri Olsa > > > > Peter, > > I think this should go through your tree again? > > bpf-next/master does not have sample_flags merged yet > > Yep can do. I'll line it up in perf/urgent (Ingo just send out > perf/core). Peter, Could you please hurry up. 11 days have passed. This issue affects everyone the hard way now after merging all the trees: tip -> linus -> net-next -> bpf-next. The BPF CI is red right now with 5 tests failing because this fix is still missing. It's causing a headache to maintainers and developers.