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 86B27C433F5 for ; Thu, 3 Mar 2022 02:29:50 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231730AbiCCCad (ORCPT ); Wed, 2 Mar 2022 21:30:33 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:47104 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231702AbiCCCab (ORCPT ); Wed, 2 Mar 2022 21:30:31 -0500 Received: from mail-pj1-x102c.google.com (mail-pj1-x102c.google.com [IPv6:2607:f8b0:4864:20::102c]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 4C46D3EF3C; Wed, 2 Mar 2022 18:29:47 -0800 (PST) Received: by mail-pj1-x102c.google.com with SMTP id z12-20020a17090ad78c00b001bf022b69d6so2432055pju.2; Wed, 02 Mar 2022 18:29:47 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=t11rGjeJbaPKo4iIzfdlK+BfedmdNwblLmmUNHyIl/s=; b=LaBwsIw262WVf/mDTL0709lGkwF46Jcxad+J+nwwx7JjWd4qP096eOqaCM2VAmSIht wGxm4Dsv9k9gRui1sH4PxWNSfMr07ZeSTBdu1yvsxFYMayiLCpAJGOXhwznx97zPCd2W 1t93LsQ18l0E1hu4RqFZVvUk1p86GbTKRhnUeH8akfZt/XrDqNqDkrZzcOipXqJ+L7ml uIVGnzLKp3MVN2HSwJwj+7wpJxJiyPXq4Gi12UuFMWI8IOxJkUUBRD2AkEogjNA0i68d 4BpnbqaKb2RkRn1asKsRKgctWPsFugfnLi8nIQ9HUAfJDJzzJrhcSFNGHxuV2Zed0enA 0qTQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=t11rGjeJbaPKo4iIzfdlK+BfedmdNwblLmmUNHyIl/s=; b=mQoPCob4Vj1yweEyvBDCP5q2qtkq++HQfSMtCjgelS2ECRD9k6oiIeRz44yY6kDumr I/KaOHo8HP5WQTyRZHhCqGqOTOGVKvIYSx3MbgxsA+6fOWw38Va3Z4IEAJiEGRc5V3sb YNC4U+B/zFMRXqO4c4qSquCRA2+AjDEI8pu7KaVUGsHIiV85CzJjfMqPG2O1EWTNmqXT Mc9lnyxpp/xcfItQyaB5KfVmaSqnbd+qMJUY+b2upW7ZmftqtrcVraXudYYahhQkffu5 09brjf4FUUHSzt2quyJwIrbA9VJFLHllEpQ5dHky7WOhx+Ym7EKA9ZjlWtLi74N/H9NB pKiQ== X-Gm-Message-State: AOAM532n0/RKzPPrqxiA99a2ilNmiwA/dWG2ay35cli26MaWCFV3lwxB c9vIHzh1qKCGdKlVuSK4RbdU9lVqwwaHvli/JgGe60Cm X-Google-Smtp-Source: ABdhPJy+6x4bAj139bTUUQWuKIgLLPNL9DSC9ipZnEz5zg+b/vDIpT/n1lv2gwAmOJsh8qZWpnxAfkTDbypHY+zBp3E= X-Received: by 2002:a17:902:76c5:b0:14e:e325:9513 with SMTP id j5-20020a17090276c500b0014ee3259513mr33748266plt.55.1646274586726; Wed, 02 Mar 2022 18:29:46 -0800 (PST) MIME-Version: 1.0 References: <20220225234339.2386398-1-haoluo@google.com> <20220225234339.2386398-5-haoluo@google.com> <93c3fc30-ad38-96fa-cf8e-20e55b267a3b@fb.com> In-Reply-To: <93c3fc30-ad38-96fa-cf8e-20e55b267a3b@fb.com> From: Alexei Starovoitov Date: Wed, 2 Mar 2022 18:29:35 -0800 Message-ID: Subject: Re: [PATCH bpf-next v1 4/9] bpf: Introduce sleepable tracepoints To: Yonghong Song Cc: Hao Luo , Alexei Starovoitov , Andrii Nakryiko , Daniel Borkmann , Martin KaFai Lau , Song Liu , KP Singh , Shakeel Butt , Joe Burton , Tejun Heo , Josh Don , Stanislav Fomichev , bpf , LKML Content-Type: text/plain; charset="UTF-8" Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, Mar 2, 2022 at 5:09 PM Yonghong Song wrote: > > > > On 3/2/22 1:30 PM, Alexei Starovoitov wrote: > > On Wed, Mar 2, 2022 at 1:23 PM Yonghong Song wrote: > >> > >> > >> > >> On 2/25/22 3:43 PM, Hao Luo wrote: > >>> Add a new type of bpf tracepoints: sleepable tracepoints, which allows > >>> the handler to make calls that may sleep. With sleepable tracepoints, a > >>> set of syscall helpers (which may sleep) may also be called from > >>> sleepable tracepoints. > >> > >> There are some old discussions on sleepable tracepoints, maybe > >> worthwhile to take a look. > >> > >> https://lore.kernel.org/bpf/20210218222125.46565-5-mjeanson@efficios.com/T/ > > > > Right. It's very much related, but obsolete too. > > We don't need any of that for sleeptable _raw_ tps. > > I prefer to stay with "sleepable" name as well to > > match the rest of the bpf sleepable code. > > In all cases it's faultable. > > sounds good to me. Agree that for the bpf user case, Hao's > implementation should be enough. Just remembered that we can also do trivial noinline __weak nop function and mark it sleepable on the verifier side. That's what we were planning to do to trace map update/delete ops in Joe Burton's series. Then we don't need to extend tp infra. I'm fine whichever way. I see pros and cons in both options.