Thread (15 messages) flat view 15 messages, 2 authors, 2021-07-15

Re: [PATCH v6 bpf-next 03/11] bpf: Introduce bpf timers.

From: Alexei Starovoitov <hidden>
Date: 2021-07-15 00:44:19
Also in: bpf

On Wed, Jul 14, 2021 at 5:00 PM Andrii Nakryiko
[off-list ref] wrote:
quoted
+       }
+       /* allocate hrtimer via map_kmalloc to use memcg accounting */
+       t = bpf_map_kmalloc_node(map, sizeof(*t), GFP_ATOMIC, NUMA_NO_NODE);
I wonder if it would make sense to use map->numa_node here to keep map
value and timer data in the same NUMA node?
quoted
+       if (!t) {
+               ret = -ENOMEM;
+               goto out;
+       }
[...]
quoted
+
+/* This function is called by map_delete/update_elem for individual element.
+ * By ops->map_release_uref when the user space reference to a map reaches zero
+ * and by ops->map_free when the kernel reference reaches zero.
is ops->map_free part still valid?
Both good points. Will respin.
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help