Add _emit sufffix in ovni_ev and ovni_ev_jumbo

The new names avoid problems in C++ as the struct ovni_ev collided with
the ovni_ev function.
This commit is contained in:
Rodrigo Arias 2021-10-29 17:04:42 +02:00
parent 3a30f25413
commit fe3b408157
3 changed files with 5 additions and 5 deletions

4
ovni.c
View File

@ -543,14 +543,14 @@ ovni_ev_add(struct ovni_ev *ev)
} }
void void
ovni_ev_jumbo(struct ovni_ev *ev, uint8_t *buf, uint32_t bufsize) ovni_ev_jumbo_emit(struct ovni_ev *ev, uint8_t *buf, uint32_t bufsize)
{ {
ovni_ev_set_clock(ev); ovni_ev_set_clock(ev);
ovni_ev_add_jumbo(ev, buf, bufsize); ovni_ev_add_jumbo(ev, buf, bufsize);
} }
void void
ovni_ev(struct ovni_ev *ev) ovni_ev_emit(struct ovni_ev *ev)
{ {
ovni_ev_set_clock(ev); ovni_ev_set_clock(ev);
ovni_ev_add(ev); ovni_ev_add(ev);

4
ovni.h
View File

@ -163,8 +163,8 @@ int ovni_payload_size(struct ovni_ev *ev);
void ovni_add_cpu(int index, int phyid); void ovni_add_cpu(int index, int phyid);
/* Set the current clock in the event and queue it */ /* Set the current clock in the event and queue it */
void ovni_ev(struct ovni_ev *ev); void ovni_ev_emit(struct ovni_ev *ev);
void ovni_ev_jumbo(struct ovni_ev *ev, uint8_t *buf, uint32_t bufsize); void ovni_ev_jumbo_emit(struct ovni_ev *ev, uint8_t *buf, uint32_t bufsize);
int ovni_flush(void); int ovni_flush(void);

View File

@ -66,7 +66,7 @@ int main(int argc, char *argv[])
for(i=0; i<n; i++) for(i=0; i<n; i++)
{ {
ovni_clock_update(); ovni_clock_update();
ovni_ev(&ev); ovni_ev_emit(&ev);
} }
ovni_flush(); ovni_flush();