Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1289772 > unrolled thread
| Started by | Julia Lawall <Julia.Lawall@lip6.fr> |
|---|---|
| First post | 2015-12-11 18:50 +0100 |
| Last post | 2015-12-11 19:20 +0100 |
| Articles | 5 — 4 participants |
Back to article view | Back to linux.kernel
[PATCH] bpf: constify bpf_verifier_ops structure Julia Lawall <Julia.Lawall@lip6.fr> - 2015-12-11 18:50 +0100
Re: [PATCH] bpf: constify bpf_verifier_ops structure Steven Rostedt <rostedt@goodmis.org> - 2015-12-11 19:20 +0100
Re: [PATCH] bpf: constify bpf_verifier_ops structure Alexei Starovoitov <alexei.starovoitov@gmail.com> - 2015-12-11 19:20 +0100
Re: [PATCH] bpf: constify bpf_verifier_ops structure Alexei Starovoitov <alexei.starovoitov@gmail.com> - 2015-12-11 19:20 +0100
Re: [PATCH] bpf: constify bpf_verifier_ops structure Daniel Borkmann <daniel@iogearbox.net> - 2015-12-11 19:20 +0100
| From | Julia Lawall <Julia.Lawall@lip6.fr> |
|---|---|
| Date | 2015-12-11 18:50 +0100 |
| Subject | [PATCH] bpf: constify bpf_verifier_ops structure |
| Message-ID | <qEzZn-7Cr-5@gated-at.bofh.it> |
This bpf_verifier_ops structure is never modified, like the other
bpf_verifier_ops structures, so declare it as const.
Done with the help of Coccinelle.
Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr>
---
kernel/trace/bpf_trace.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/kernel/trace/bpf_trace.c b/kernel/trace/bpf_trace.c
index 4228fd3..45dd798 100644
--- a/kernel/trace/bpf_trace.c
+++ b/kernel/trace/bpf_trace.c
@@ -316,7 +316,7 @@ static bool kprobe_prog_is_valid_access(int off, int size, enum bpf_access_type
return true;
}
-static struct bpf_verifier_ops kprobe_prog_ops = {
+static const struct bpf_verifier_ops kprobe_prog_ops = {
.get_func_proto = kprobe_prog_func_proto,
.is_valid_access = kprobe_prog_is_valid_access,
};
--
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 | Steven Rostedt <rostedt@goodmis.org> |
|---|---|
| Date | 2015-12-11 19:20 +0100 |
| Message-ID | <qEAsq-81R-17@gated-at.bofh.it> |
| In reply to | #1289772 |
On Fri, 11 Dec 2015 18:35:59 +0100
Julia Lawall <Julia.Lawall@lip6.fr> wrote:
> This bpf_verifier_ops structure is never modified, like the other
> bpf_verifier_ops structures, so declare it as const.
>
> Done with the help of Coccinelle.
Thanks, I'll add this to my 4.5 queue.
-- Steve
>
> Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr>
>
> ---
> kernel/trace/bpf_trace.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/kernel/trace/bpf_trace.c b/kernel/trace/bpf_trace.c
> index 4228fd3..45dd798 100644
> --- a/kernel/trace/bpf_trace.c
> +++ b/kernel/trace/bpf_trace.c
> @@ -316,7 +316,7 @@ static bool kprobe_prog_is_valid_access(int off, int size, enum bpf_access_type
> return true;
> }
>
> -static struct bpf_verifier_ops kprobe_prog_ops = {
> +static const struct bpf_verifier_ops kprobe_prog_ops = {
> .get_func_proto = kprobe_prog_func_proto,
> .is_valid_access = kprobe_prog_is_valid_access,
> };
--
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 | Alexei Starovoitov <alexei.starovoitov@gmail.com> |
|---|---|
| Date | 2015-12-11 19:20 +0100 |
| Message-ID | <qEAsq-81R-31@gated-at.bofh.it> |
| In reply to | #1289801 |
On Fri, Dec 11, 2015 at 01:12:56PM -0500, Steven Rostedt wrote: > On Fri, 11 Dec 2015 18:35:59 +0100 > Julia Lawall <Julia.Lawall@lip6.fr> wrote: > > > This bpf_verifier_ops structure is never modified, like the other > > bpf_verifier_ops structures, so declare it as const. > > > > Done with the help of Coccinelle. > > Thanks, I'll add this to my 4.5 queue. emails crossed. this is also fine with me. -- 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 | Alexei Starovoitov <alexei.starovoitov@gmail.com> |
|---|---|
| Date | 2015-12-11 19:20 +0100 |
| Message-ID | <qEAsq-81R-15@gated-at.bofh.it> |
| In reply to | #1289772 |
On Fri, Dec 11, 2015 at 06:35:59PM +0100, Julia Lawall wrote: > This bpf_verifier_ops structure is never modified, like the other > bpf_verifier_ops structures, so declare it as const. > > Done with the help of Coccinelle. > > Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr> Acked-by: Alexei Starovoitov <ast@kernel.org> Ingo, can you take it into tip ? Thanks! -- 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 | Daniel Borkmann <daniel@iogearbox.net> |
|---|---|
| Date | 2015-12-11 19:20 +0100 |
| Message-ID | <qEAsq-81R-37@gated-at.bofh.it> |
| In reply to | #1289772 |
On 12/11/2015 06:35 PM, Julia Lawall wrote: > This bpf_verifier_ops structure is never modified, like the other > bpf_verifier_ops structures, so declare it as const. > > Done with the help of Coccinelle. > > Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr> Thanks Julia! Acked-by: Daniel Borkmann <daniel@iogearbox.net> -- 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