From: Cyril Hrubis <chrubis@suse.cz>
To: ltp@lists.linux.it
Subject: [LTP] [PATCH v2 2/5] bpf: Add map_array helper functions
Date: Fri, 30 Apr 2021 10:31:17 +0200 [thread overview]
Message-ID: <YIvAVaPNyunDHxaF@yuki> (raw)
In-Reply-To: <20210429150510.21585-3-rpalethorpe@suse.com>
Hi!
> +long bpf_map_array_get(const int map_fd,
> + const uint32_t *const array_indx,
> + uint64_t *const array_val)
Wouldn't the API be nicer if we passed just index value and returned the
map value? We do TBROK if something goes wrong anyways, so there is no
point in passing the return value from the bpf() syscall.
--
Cyril Hrubis
chrubis@suse.cz
next prev parent reply other threads:[~2021-04-30 8:31 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-04-29 15:05 [LTP] [PATCH v2 0/5] BPF refactor and add bpf_prog05 Richard Palethorpe
2021-04-29 15:05 ` [LTP] [PATCH v2 1/5] lapi/bpf: Add /=, %= and BPF_MAXINSNS Richard Palethorpe
2021-04-29 15:05 ` [LTP] [PATCH v2 2/5] bpf: Add map_array helper functions Richard Palethorpe
2021-04-30 8:31 ` Cyril Hrubis [this message]
2021-05-05 10:27 ` Richard Palethorpe
2021-04-29 15:05 ` [LTP] [PATCH v2 3/5] bpf: Add helper to run socket programs Richard Palethorpe
2021-04-30 8:38 ` Cyril Hrubis
2021-04-29 15:05 ` [LTP] [PATCH v2 4/5] bpf: Add bpf_insn_buf, map and instruction concatenation helpers Richard Palethorpe
2021-04-30 8:44 ` Cyril Hrubis
2021-04-29 15:05 ` [LTP] [PATCH v2 5/5] bpf: Check truncation on 32bit div/mod by zero Richard Palethorpe
2021-04-30 8:46 ` Cyril Hrubis
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=YIvAVaPNyunDHxaF@yuki \
--to=chrubis@suse.cz \
--cc=ltp@lists.linux.it \
/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