Received: by 2002:a05:7412:798b:b0:fc:a2b0:25d7 with SMTP id fb11csp700012rdb; Thu, 22 Feb 2024 17:45:22 -0800 (PST) X-Forwarded-Encrypted: i=3; AJvYcCXNkbwA2vJPDEsU+UIKN5psxT+ADm9ibPeCjoEDMv0JSavudgRd5dSDD2eIe8CPn9BxAi5+PUjZUaR4Esw/8tI260pZVOC53bVVdii0WQ== X-Google-Smtp-Source: AGHT+IFAqEMElQvgnoCWzvDJL+Mt9nHTbTWvhIN8WpiCWKdfH+41t4JepoZdAQDSFb/TFcgAfzkh X-Received: by 2002:a05:6a00:d65:b0:6e0:dc68:409d with SMTP id n37-20020a056a000d6500b006e0dc68409dmr559788pfv.2.1708652722084; Thu, 22 Feb 2024 17:45:22 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1708652722; cv=pass; d=google.com; s=arc-20160816; b=XRNyPXW1UxD7nyxZ2Nge7tTAfwe9yqIC5/khq6ZeQJmeMm4U01L2wAGO5I+R0Ddsye Qc70vQal5rw//96VO5zLUwc6B2qSfQHnGbalR3zEB275pHa7QuriIG8+hcgJVGkMwhDz wcHREVdZnDI35d/E8u11l18qP4+Lp3LQ2/c4Lt1V6BT3LExGQfwHyvncXqSYZodXU1X2 bHRV/0l5fUH5WPEDtpCwBu7rN/Mmd9inJ9aFl9lt+PRLYZh8qGm7Dc5zs2rgmA7Elw4U jgtAb1kRB8BuYT3N+iDFJELQAVcfnEqmvPNc9MIdOIcm2jdTouNPQxk0GgD4OoyYKo5j OdEg== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:references:in-reply-to:message-id :subject:cc:to:from:date; bh=sS8+ESx/OF66KT+NauvlkSNHbU3LwWIzM1zq3NBA+dw=; fh=hy2Gx5YsJlzzzUllceSwV/VJ/pVTx7gDIjRmL8kMpRo=; b=nd/SDW3wl+QpqlqTlhrNYse+Z5pQ95mUfjvQETBPAjDh0nyHj0X1bxntrUD/bvo/5b Cci9FApZ4WJ57MRT4nbOYG1NPPTcumMVu0hmTKEZiFe1IQyFakc2J/vbhj7ecO1HSFo2 fAcFCgl4NS3tyKR4INFY+SNim9K++jh8JbgreBJ6bAcqnJRkR4X8qM8Fy+0/MLOXn8Uw GWGqRHWt94sLLZW4vvXBMGqcYxwE5xplrrKG3yBbD2eOHqHAQURQ0SGt+o+0DjyEef6J uOpzPpofmeZMnl8oRv2tsqQ/GLBwyCCqqaBSV7YupEc/CEs+TTSd9m7g+yDuGJtgObgD p2TQ==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; arc=pass (i=1); spf=pass (google.com: domain of linux-kernel+bounces-77647-linux.lists.archive=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) smtp.mailfrom="linux-kernel+bounces-77647-linux.lists.archive=gmail.com@vger.kernel.org" Return-Path: Received: from sv.mirrors.kernel.org (sv.mirrors.kernel.org. [139.178.88.99]) by mx.google.com with ESMTPS id a187-20020a6366c4000000b005d8c55d9669si11462926pgc.366.2024.02.22.17.45.21 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 22 Feb 2024 17:45:22 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-77647-linux.lists.archive=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) client-ip=139.178.88.99; Authentication-Results: mx.google.com; arc=pass (i=1); spf=pass (google.com: domain of linux-kernel+bounces-77647-linux.lists.archive=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) smtp.mailfrom="linux-kernel+bounces-77647-linux.lists.archive=gmail.com@vger.kernel.org" Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by sv.mirrors.kernel.org (Postfix) with ESMTPS id C2367285D5B for ; Fri, 23 Feb 2024 01:45:21 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 54EBABA28; Fri, 23 Feb 2024 01:45:13 +0000 (UTC) Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id C01ABAD53; Fri, 23 Feb 2024 01:45:12 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1708652712; cv=none; b=cQgycTtw5w7fMyH80AD+0P8SguxmDZn6eirE0EaTVUZ26fRv9nLHKXJA04uUyO8KJVBSqK8kt0grthnvZ0bUp88L+PZ/fqAeHCiBfRRHZDykZicuIEGnZ9Q8GhGdzvQ3EsZ374k6k574lfN6TMwHEZrJU2a3yF33qCMoPwh6Vn8= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1708652712; c=relaxed/simple; bh=n6RPnC6yufWY3n3pn0vWSMZ9igCtwEYuAlgxz4yas28=; h=Date:From:To:Cc:Subject:Message-ID:In-Reply-To:References: MIME-Version:Content-Type; b=pnqhgnz1FFbs/Gt/Px/+2ZrSoWvMQh7e2wdf3hsBOeoBZM+EbdFmxnaAPOnh6fjgJN6ievapZ1JC/aWhXzgvswbr9vCj9HUck8/v2ECVemLJhda2X/hvnIvhMqlrcSKG791Ep8fGs0+YprOtq4scPGZR8wuzOzARrHeTCth2tVQ= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 Received: by smtp.kernel.org (Postfix) with ESMTPSA id 6F8AFC433C7; Fri, 23 Feb 2024 01:45:10 +0000 (UTC) Date: Thu, 22 Feb 2024 20:47:01 -0500 From: Steven Rostedt To: Huang Yiwei Cc: , , , , , , , , , , , , , , , , Ross Zwisler , Joel Fernandes Subject: Re: [PATCH v5] tracing: Support to dump instance traces by ftrace_dump_on_oops Message-ID: <20240222204701.6b9de71e@gandalf.local.home> In-Reply-To: <20240208131814.614691-1-quic_hyiwei@quicinc.com> References: <20240208131814.614691-1-quic_hyiwei@quicinc.com> X-Mailer: Claws Mail 3.19.1 (GTK+ 2.24.33; x86_64-pc-linux-gnu) Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable On Thu, 8 Feb 2024 21:18:14 +0800 Huang Yiwei wrote: > Currently ftrace only dumps the global trace buffer on an OOPs. For > debugging a production usecase, instance trace will be helpful to > check specific problems since global trace buffer may be used for > other purposes. >=20 > This patch extend the ftrace_dump_on_oops parameter to dump a specific > or multiple trace instances: >=20 > - ftrace_dump_on_oops=3D0: as before -- don't dump > - ftrace_dump_on_oops[=3D1]: as before -- dump the global trace buffer > on all CPUs > - ftrace_dump_on_oops=3D2 or =3Dorig_cpu: as before -- dump the global > trace buffer on CPU that triggered the oops > - ftrace_dump_on_oops=3D: new behavior -- dump the > tracing instance matching > - ftrace_dump_on_oops[=3D2/orig_cpu],[=3D2/orig_cpu], > [=3D2/orig_cpu]: new behavior -- dump the global trace > buffer and multiple instance buffer on all CPUs, or only dump on CPU > that triggered the oops if =3D2 or =3Dorig_cpu is given >=20 > Also, the sysctl node can handle the input accordingly. >=20 > Cc: Ross Zwisler > Signed-off-by: Joel Fernandes (Google) > Signed-off-by: Huang Yiwei This patch failed with the following warning: kernel/trace/trace.c:10029:6: warning: no previous prototype for =E2=80= =98ftrace_dump_one=E2=80=99 [-Wmissing-prototypes] -- Steve