From: David Miller <davem@davemloft.net>
To: ast@fb.com
Cc: borkmann@iogearbox.net, netdev@vger.kernel.org
Subject: more on FP operations
Date: Thu, 20 Apr 2017 14:06:17 -0400 (EDT) [thread overview]
Message-ID: <20170420.140617.91794616324352770.davem@davemloft.net> (raw)
I'm running test_verifier for testing, and I notice in my JIT that a
32-bit move from the frame pointer (BPF_REG_10) ends up in the JIT.
It is from this test:
"unpriv: partial copy of pointer",
.insns = {
BPF_MOV32_REG(BPF_REG_1, BPF_REG_10),
BPF_MOV64_IMM(BPF_REG_0, 0),
BPF_EXIT_INSN(),
},
.errstr_unpriv = "R10 partial copy",
.result_unpriv = REJECT,
.result = ACCEPT,
It seems to suggest that privileged code is allowed to do this, but I
can't think of a legitimate usage.
I really want to be able to JIT anything the verifier accepts, but I
have a hard time justifying adding 32-bit FP register move support,
adjusting for the stack bias, etc.
Thanks.
next reply other threads:[~2017-04-20 18:06 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-04-20 18:06 David Miller [this message]
2017-04-20 21:52 ` more on FP operations Daniel Borkmann
2017-04-20 23:13 ` Alexei Starovoitov
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20170420.140617.91794616324352770.davem@davemloft.net \
--to=davem@davemloft.net \
--cc=ast@fb.com \
--cc=borkmann@iogearbox.net \
--cc=netdev@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).