Commit 7176fa4
committed
pcn-k8switch: fix bad initialization logic
Before 09356c4c033 ("services: remove generate_code and generate_code_vector")
the k8switch was created with a stub program and then reloaded with the initial
configuration. That approach is far from optimal as the code is immediately
reloaded, then 09356c4c033 changed that to created the cube without any eBPF
program and then add it with the initial configuration.
However, the call to reload_program was still there, it fails because the
stub is not present anymore. This commits fix that by calling add_program
when the cube is created.
Fixes: e09356c ("services: remove generate_code and generate_code_vector")
Signed-off-by: Mauricio Vasquez B <mauriciovasquezbernal@gmail.com>1 parent e9b238b commit 7176fa4
2 files changed
Lines changed: 10 additions & 2 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
34 | 34 | | |
35 | 35 | | |
36 | 36 | | |
37 | | - | |
| 37 | + | |
38 | 38 | | |
39 | 39 | | |
40 | 40 | | |
| |||
170 | 170 | | |
171 | 171 | | |
172 | 172 | | |
173 | | - | |
| 173 | + | |
174 | 174 | | |
175 | 175 | | |
176 | 176 | | |
| |||
197 | 197 | | |
198 | 198 | | |
199 | 199 | | |
| 200 | + | |
| 201 | + | |
| 202 | + | |
| 203 | + | |
| 204 | + | |
| 205 | + | |
| 206 | + | |
200 | 207 | | |
201 | 208 | | |
202 | 209 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
143 | 143 | | |
144 | 144 | | |
145 | 145 | | |
| 146 | + | |
146 | 147 | | |
147 | 148 | | |
148 | 149 | | |
| |||
0 commit comments