Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1256360 > unrolled thread
| Started by | Yang Shi <yang.shi@linaro.org> |
|---|---|
| First post | 2015-10-27 01:30 +0100 |
| Last post | 2015-10-28 03:40 +0100 |
| Articles | 3 — 3 participants |
Back to article view | Back to linux.kernel
[PATCH] bpf: sample: define aarch64 specific registers Yang Shi <yang.shi@linaro.org> - 2015-10-27 01:30 +0100
Re: [PATCH] bpf: sample: define aarch64 specific registers Alexei Starovoitov <alexei.starovoitov@gmail.com> - 2015-10-27 04:30 +0100
Re: [PATCH] bpf: sample: define aarch64 specific registers David Miller <davem@davemloft.net> - 2015-10-28 03:40 +0100
| From | Yang Shi <yang.shi@linaro.org> |
|---|---|
| Date | 2015-10-27 01:30 +0100 |
| Subject | [PATCH] bpf: sample: define aarch64 specific registers |
| Message-ID | <qo0jg-6CI-13@gated-at.bofh.it> |
Define aarch64 specific registers for building bpf samples correctly. Signed-off-by: Yang Shi <yang.shi@linaro.org> --- samples/bpf/bpf_helpers.h | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/samples/bpf/bpf_helpers.h b/samples/bpf/bpf_helpers.h index 3a44d3a..af44e56 100644 --- a/samples/bpf/bpf_helpers.h +++ b/samples/bpf/bpf_helpers.h @@ -86,5 +86,17 @@ static int (*bpf_l4_csum_replace)(void *ctx, int off, int from, int to, int flag #define PT_REGS_RC(x) ((x)->gprs[2]) #define PT_REGS_SP(x) ((x)->gprs[15]) +#elif defined(__aarch64__) + +#define PT_REGS_PARM1(x) ((x)->regs[0]) +#define PT_REGS_PARM2(x) ((x)->regs[1]) +#define PT_REGS_PARM3(x) ((x)->regs[2]) +#define PT_REGS_PARM4(x) ((x)->regs[3]) +#define PT_REGS_PARM5(x) ((x)->regs[4]) +#define PT_REGS_RET(x) ((x)->regs[30]) +#define PT_REGS_FP(x) ((x)->regs[29]) /* Works only with CONFIG_FRAME_POINTER */ +#define PT_REGS_RC(x) ((x)->regs[0]) +#define PT_REGS_SP(x) ((x)->sp) + #endif #endif -- 2.0.2 -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
[toc] | [next] | [standalone]
| From | Alexei Starovoitov <alexei.starovoitov@gmail.com> |
|---|---|
| Date | 2015-10-27 04:30 +0100 |
| Message-ID | <qo37r-8tR-3@gated-at.bofh.it> |
| In reply to | #1256360 |
On Mon, Oct 26, 2015 at 05:02:19PM -0700, Yang Shi wrote: > Define aarch64 specific registers for building bpf samples correctly. > > Signed-off-by: Yang Shi <yang.shi@linaro.org> looks good to me. Acked-by: Alexei Starovoitov <ast@kernel.org> -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
[toc] | [prev] | [next] | [standalone]
| From | David Miller <davem@davemloft.net> |
|---|---|
| Date | 2015-10-28 03:40 +0100 |
| Message-ID | <qooOC-50K-5@gated-at.bofh.it> |
| In reply to | #1256360 |
From: Yang Shi <yang.shi@linaro.org> Date: Mon, 26 Oct 2015 17:02:19 -0700 > Define aarch64 specific registers for building bpf samples correctly. > > Signed-off-by: Yang Shi <yang.shi@linaro.org> Applied. -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
[toc] | [prev] | [standalone]
Back to top | Article view | linux.kernel
csiph-web