Changeset 5da04d6 in rtems-libbsd


Ignore:
Timestamp:
May 13, 2019, 7:31:17 AM (2 years ago)
Author:
Sebastian Huber <sebastian.huber@…>
Branches:
5, master
Children:
36e8ad4
Parents:
60e7537
git-author:
Sebastian Huber <sebastian.huber@…> (05/13/19 07:31:17)
git-committer:
Sebastian Huber <sebastian.huber@…> (05/13/19 07:32:37)
Message:

Fix zero-copy mbuf support

In 2017 there was a change in the mbuf API.

Files:
3 edited

Legend:

Unmodified
Added
Removed
  • rtemsbsd/include/rtems/bsd/zerocopy.h

    r60e7537 r5da04d6  
    5454
    5555void rtems_bsd_m_extaddref(struct mbuf *m, void *buf, size_t size,
    56     u_int *ref_cnt, void (*freef)(void *, void *), void *arg1,
    57     void *arg2);
     56    u_int *ref_cnt, m_ext_free_t *freef, void *arg1, void *arg2);
    5857
    5958void rtems_bsd_m_free(struct mbuf *m);
  • rtemsbsd/rtems/rtems-kernel-mbuf.c

    r60e7537 r5da04d6  
    5656void
    5757rtems_bsd_m_extaddref(struct mbuf *m, void *buf, size_t size,
    58     u_int *ref_cnt, void (*freef)(void *, void *), void *arg1,
    59     void *arg2)
     58    u_int *ref_cnt, m_ext_free_t *freef, void *arg1, void *arg2)
    6059{
    6160        m_extaddref(m, buf, size, ref_cnt, freef, arg1, arg2);
  • testsuite/zerocopy01/test_main.c

    r60e7537 r5da04d6  
    8383
    8484static void
    85 buffer_free(void *arg1, void *arg2)
    86 {
    87         struct buffer_control *bc = arg1;
    88         struct buffer *buf = arg2;
     85buffer_free(struct mbuf *m)
     86{
     87        struct buffer_control *bc = m->m_ext.ext_arg1;
     88        struct buffer *buf = m->m_ext.ext_arg2;
    8989        rtems_status_code sc;
    9090        rtems_interrupt_lock_context lock_context;
Note: See TracChangeset for help on using the changeset viewer.