summary refs log tree commit diff stats
path: root/ebpf/ebpf_rss-stub.c
diff options
context:
space:
mode:
authorDaniel P. Berrangé <berrange@redhat.com>2024-10-23 09:51:00 +0100
committerJason Wang <jasowang@redhat.com>2024-10-28 14:37:25 +0800
commit00b69f1d867ddcf8884c92f5647b424088e754e4 (patch)
tree3f53103f187c3861380a18fba5fa216f6937037d /ebpf/ebpf_rss-stub.c
parent31efce1e311830431718536c6461815b04e08bf9 (diff)
downloadfocaccia-qemu-00b69f1d867ddcf8884c92f5647b424088e754e4.tar.gz
focaccia-qemu-00b69f1d867ddcf8884c92f5647b424088e754e4.zip
ebpf: add formal error reporting to all APIs
The eBPF code is currently reporting error messages through trace
events. Trace events are fine for debugging, but they are not to be
considered the primary error reporting mechanism, as their output
is inaccessible to callers.

This adds an "Error **errp" parameter to all methods which have
important error scenarios to report to the caller.

Signed-off-by: Daniel P. Berrangé <berrange@redhat.com>
Signed-off-by: Jason Wang <jasowang@redhat.com>
Diffstat (limited to 'ebpf/ebpf_rss-stub.c')
-rw-r--r--ebpf/ebpf_rss-stub.c8
1 files changed, 5 insertions, 3 deletions
diff --git a/ebpf/ebpf_rss-stub.c b/ebpf/ebpf_rss-stub.c
index 8d7fae2ad9..d0e7f99fb9 100644
--- a/ebpf/ebpf_rss-stub.c
+++ b/ebpf/ebpf_rss-stub.c
@@ -23,19 +23,21 @@ bool ebpf_rss_is_loaded(struct EBPFRSSContext *ctx)
     return false;
 }
 
-bool ebpf_rss_load(struct EBPFRSSContext *ctx)
+bool ebpf_rss_load(struct EBPFRSSContext *ctx, Error **errp)
 {
     return false;
 }
 
 bool ebpf_rss_load_fds(struct EBPFRSSContext *ctx, int program_fd,
-                       int config_fd, int toeplitz_fd, int table_fd)
+                       int config_fd, int toeplitz_fd, int table_fd,
+                       Error **errp)
 {
     return false;
 }
 
 bool ebpf_rss_set_all(struct EBPFRSSContext *ctx, struct EBPFRSSConfig *config,
-                      uint16_t *indirections_table, uint8_t *toeplitz_key)
+                      uint16_t *indirections_table, uint8_t *toeplitz_key,
+                      Error **errp)
 {
     return false;
 }