summaryrefslogtreecommitdiffstats
path: root/sys/sys/sf_buf.h
diff options
context:
space:
mode:
authorandre <andre@FreeBSD.org>2013-08-24 16:57:44 +0000
committerandre <andre@FreeBSD.org>2013-08-24 16:57:44 +0000
commitb148bf45e00854fc92a79e2434843fc0ced325ba (patch)
treed9cb73f9fc061a57daf8eba0e946e359dfddf04c /sys/sys/sf_buf.h
parentb7d376ce03e400fd642a642d69997ab017a9466e (diff)
downloadFreeBSD-src-b148bf45e00854fc92a79e2434843fc0ced325ba.zip
FreeBSD-src-b148bf45e00854fc92a79e2434843fc0ced325ba.tar.gz
Add an mbuf pointer parameter to (*ext_free) to give the external
free function access to the mbuf the external memory was attached to. Mechanically adjust all users to include the mbuf parameter. This fixes a long standing annoyance for external free functions. Before one had to sacrifice one of the argument pointers for this. Sponsored by: The FreeBSD Foundation
Diffstat (limited to 'sys/sys/sf_buf.h')
-rw-r--r--sys/sys/sf_buf.h3
1 files changed, 2 insertions, 1 deletions
diff --git a/sys/sys/sf_buf.h b/sys/sys/sf_buf.h
index 1b62fd3..32aa304 100644
--- a/sys/sys/sf_buf.h
+++ b/sys/sys/sf_buf.h
@@ -55,6 +55,7 @@ struct sfstat { /* sendfile statistics */
#ifdef _KERNEL
#include <machine/sf_buf.h>
#include <sys/counter.h>
+struct mbuf; /* for sf_buf_mext() */
extern counter_u64_t sfstat[sizeof(struct sfstat) / sizeof(uint64_t)];
#define SFSTAT_ADD(name, val) \
@@ -66,6 +67,6 @@ extern counter_u64_t sfstat[sizeof(struct sfstat) / sizeof(uint64_t)];
struct sf_buf *
sf_buf_alloc(struct vm_page *m, int flags);
void sf_buf_free(struct sf_buf *sf);
-void sf_buf_mext(void *addr, void *args);
+void sf_buf_mext(struct mbuf *mb, void *addr, void *args);
#endif /* !_SYS_SF_BUF_H_ */
OpenPOWER on IntegriCloud