From mboxrd@z Thu Jan 1 00:00:00 1970 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 549D817744 for ; Thu, 20 Jul 2023 11:36:05 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 53CACC433C7; Thu, 20 Jul 2023 11:36:02 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1689852965; bh=d7+hmam9/TesJxs4w+SMUGKpL20xYWIxXk3Rgy9dj/Y=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=phHmWU1zIMcWZMOrLBYyj2Fg/087dmMbWGB34LtGFax0Sy2bSJZSdr5wnawVbzlat VH+/x4SXFRHL2feUVYLubo/Sz9nIKxvbjeuW6/N2MF2NljA2UGDXJ/B1ykdThiAoOn Fq+M+BJxwAFef6y/8/BzDF0+FtsbRNIw8Z4HVAWU99ZgP7ssdxg/J6VH3nvqoTDJks nsTrQA6rSiGeg9Bm4ekh7sCmoRHmDs4XrlTSbADxJ8TTYToMcBiVwdEK/X5ttZnjAl jWW956RKiionJBy5mBKgl9Fu8WEZg3uj790JBsjgMABshta2/TIHw+q7dc99pNBkZc syGLSb0DrUfcA== From: Jiri Olsa To: Alexei Starovoitov , Daniel Borkmann , Andrii Nakryiko Cc: bpf@vger.kernel.org, Martin KaFai Lau , Song Liu , Yonghong Song , John Fastabend , KP Singh , Stanislav Fomichev , Hao Luo Subject: [PATCHv4 bpf-next 01/28] bpf: Switch BPF_F_KPROBE_MULTI_RETURN macro to enum Date: Thu, 20 Jul 2023 13:35:23 +0200 Message-ID: <20230720113550.369257-2-jolsa@kernel.org> X-Mailer: git-send-email 2.41.0 In-Reply-To: <20230720113550.369257-1-jolsa@kernel.org> References: <20230720113550.369257-1-jolsa@kernel.org> Precedence: bulk X-Mailing-List: bpf@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Switching BPF_F_KPROBE_MULTI_RETURN macro to anonymous enum, so it'd show up in vmlinux.h. There's not functional change compared to having this as macro. Suggested-by: Andrii Nakryiko Signed-off-by: Jiri Olsa --- include/uapi/linux/bpf.h | 4 +++- tools/include/uapi/linux/bpf.h | 4 +++- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/include/uapi/linux/bpf.h b/include/uapi/linux/bpf.h index 9ed59896ebc5..730c0ec99a11 100644 --- a/include/uapi/linux/bpf.h +++ b/include/uapi/linux/bpf.h @@ -1178,7 +1178,9 @@ enum bpf_perf_event_type { /* link_create.kprobe_multi.flags used in LINK_CREATE command for * BPF_TRACE_KPROBE_MULTI attach type to create return probe. */ -#define BPF_F_KPROBE_MULTI_RETURN (1U << 0) +enum { + BPF_F_KPROBE_MULTI_RETURN = (1U << 0) +}; /* When BPF ldimm64's insn[0].src_reg != 0 then this can have * the following extensions: diff --git a/tools/include/uapi/linux/bpf.h b/tools/include/uapi/linux/bpf.h index 600d0caebbd8..f1ce5c149eee 100644 --- a/tools/include/uapi/linux/bpf.h +++ b/tools/include/uapi/linux/bpf.h @@ -1178,7 +1178,9 @@ enum bpf_perf_event_type { /* link_create.kprobe_multi.flags used in LINK_CREATE command for * BPF_TRACE_KPROBE_MULTI attach type to create return probe. */ -#define BPF_F_KPROBE_MULTI_RETURN (1U << 0) +enum { + BPF_F_KPROBE_MULTI_RETURN = (1U << 0) +}; /* When BPF ldimm64's insn[0].src_reg != 0 then this can have * the following extensions: -- 2.41.0