]> git.proxmox.com Git - qemu.git/blobdiff - slirp/mbuf.h
slirp: cleanup leftovers from misc.h
[qemu.git] / slirp / mbuf.h
index 97729e24b00b4021fe7dd296001b17053665eb56..3f3ab095b1030eb61d5e9f14116bd6179440d08c 100644 (file)
@@ -33,9 +33,6 @@
 #ifndef _MBUF_H_
 #define _MBUF_H_
 
-#define m_freem m_free
-
-
 #define MINCSIZE 4096  /* Amount to increase mbuf if too small */
 
 /*
@@ -85,6 +82,9 @@ struct m_hdr {
 struct mbuf {
        struct  m_hdr m_hdr;
        Slirp *slirp;
+       bool    arp_requested;
+       uint64_t expiration_date;
+       /* start of dynamic buffer area, must be last element */
        union M_dat {
                char    m_dat_[1]; /* ANSI don't like 0 sized arrays */
                char    *m_ext_;
@@ -116,6 +116,7 @@ struct mbuf {
                                         * it rather than putting it on the free list */
 
 void m_init(Slirp *);
+void m_cleanup(Slirp *slirp);
 struct mbuf * m_get(Slirp *);
 void m_free(struct mbuf *);
 void m_cat(register struct mbuf *, register struct mbuf *);
@@ -124,4 +125,9 @@ void m_adj(struct mbuf *, int);
 int m_copy(struct mbuf *, struct mbuf *, int, int);
 struct mbuf * dtom(Slirp *, void *);
 
+static inline void ifs_init(struct mbuf *ifm)
+{
+    ifm->ifs_next = ifm->ifs_prev = ifm;
+}
+
 #endif