+void buf_setlblkno(buf_t, daddr64_t);
+
+/*
+ * retrieve the count of valid bytes associated with buf_t
+ */
+uint32_t buf_count(buf_t);
+
+/*
+ * retrieve the size of the data store assoicated with buf_t
+ */
+uint32_t buf_size(buf_t);
+
+/*
+ * retrieve the residual I/O count assoicated with buf_t
+ * i.e. number of bytes that have not yet been completed
+ */
+uint32_t buf_resid(buf_t);
+
+/*
+ * set the count of bytes associated with buf_t
+ * typically used to set the size of the I/O to be performed
+ */
+void buf_setcount(buf_t, uint32_t);
+
+/*
+ * set the size of the buffer store associated with buf_t
+ * typically used when providing private storage to buf_t
+ */
+void buf_setsize(buf_t, uint32_t);
+
+/*
+ * set the size in bytes of the unfinished I/O associated with buf_t
+ */
+void buf_setresid(buf_t, uint32_t);
+
+/*
+ * associate kernel addressable storage with buf_t
+ */
+void buf_setdataptr(buf_t, uintptr_t);
+
+/*
+ * retrieve pointer to buffer associated with buf_t
+ * if non-null, than guaranteed to be kernel addressable
+ * size of buffer can be retrieved via buf_size
+ * size of valid data can be retrieved via buf_count
+ * if NULL, than use buf_map/buf_unmap to manage access to the underlying storage
+ */
+uintptr_t buf_dataptr(buf_t);
+
+/*
+ * return the vnode_t associated with buf_t
+ */
+vnode_t buf_vnode(buf_t);
+
+/*
+ * assign vnode_t to buf_t... the
+ * device currently associated with
+ * but_t is not changed.
+ */
+void buf_setvnode(buf_t, vnode_t);
+
+/*
+ * return the dev_t associated with buf_t
+ */
+dev_t buf_device(buf_t);
+
+/*
+ * assign the dev_t associated with vnode_t
+ * to buf_t
+ */
+errno_t buf_setdevice(buf_t, vnode_t);
+
+errno_t buf_strategy(vnode_t, void *);
+
+/*
+ * flags for buf_invalblkno
+ */
+#define BUF_WAIT 0x01
+
+errno_t buf_invalblkno(vnode_t, daddr64_t, int);
+
+
+/*
+ * return the callback function pointer
+ * if the callback is still valid
+ * returns NULL if a buffer that was not
+ * allocated via buf_alloc is specified
+ * or if a callback has not been set or
+ * it has already fired...
+ */
+void * buf_callback(buf_t);
+
+/*
+ * assign a one-shot callback function (driven from biodone)
+ * to a buf_t allocated via buf_alloc... a caller specified
+ * arg is passed to the callback function
+ */
+errno_t buf_setcallback(buf_t, void (*)(buf_t, void *), void *);
+
+/*
+ * add a upl_t to a buffer allocated via buf_alloc
+ * and set the offset into the upl_t (must be page
+ * aligned).
+ */
+errno_t buf_setupl(buf_t, upl_t, uint32_t);
+
+/*
+ * allocate a buf_t that is a clone of the buf_t
+ * passed in, but whose I/O range is a subset...
+ * if a callback routine is specified, it will
+ * be called from buf_biodone with the bp and
+ * arg specified.
+ * it must be freed via buf_free
+ */
+buf_t buf_clone(buf_t, int, int, void (*)(buf_t, void *), void *);
+
+/*
+ * allocate a buf_t associated with vnode_t
+ * that has NO storage associated with it
+ * but is suitable for use in issuing I/Os
+ * after storage has been assigned via buf_setdataptr
+ * or buf_addupl
+ */
+buf_t buf_alloc(vnode_t);
+
+/*
+ * free a buf_t that was allocated via buf_alloc
+ * any private storage associated with buf_t is the
+ * responsiblity of the caller to release
+ */
+void buf_free(buf_t);
+
+/*
+ * flags for buf_invalidateblks
+ */
+#define BUF_WRITE_DATA 0x0001 /* write data blocks first */
+#define BUF_SKIP_META 0x0002 /* skip over metadata blocks */
+
+int buf_invalidateblks(vnode_t, int, int, int);
+/*
+ * flags for buf_flushdirtyblks and buf_iterate
+ */
+#define BUF_SKIP_NONLOCKED 0x01
+#define BUF_SKIP_LOCKED 0x02
+#define BUF_SCAN_CLEAN 0x04 /* scan only the clean buffers */
+#define BUF_SCAN_DIRTY 0x08 /* scan only the dirty buffers */
+#define BUF_NOTIFY_BUSY 0x10 /* notify the caller about the busy pages during the scan */
+
+void buf_flushdirtyblks(vnode_t, int, int, const char *);
+void buf_iterate(vnode_t, int (*)(buf_t, void *), int, void *);
+
+#define BUF_RETURNED 0
+#define BUF_RETURNED_DONE 1
+#define BUF_CLAIMED 2
+#define BUF_CLAIMED_DONE 3
+
+/*
+ * zero the storage associated with buf_t
+ */
+void buf_clear(buf_t);
+
+errno_t buf_bawrite(buf_t);
+errno_t buf_bdwrite(buf_t);
+errno_t buf_bwrite(buf_t);
+
+void buf_biodone(buf_t);
+errno_t buf_biowait(buf_t);
+void buf_brelse(buf_t);
+
+errno_t buf_bread(vnode_t, daddr64_t, int, ucred_t, buf_t *);
+errno_t buf_breadn(vnode_t, daddr64_t, int, daddr64_t *, int *, int, ucred_t, buf_t *);
+errno_t buf_meta_bread(vnode_t, daddr64_t, int, ucred_t, buf_t *);
+errno_t buf_meta_breadn(vnode_t, daddr64_t, int, daddr64_t *, int *, int, ucred_t, buf_t *);
+
+u_int minphys(buf_t bp);
+int physio(void (*)(buf_t), buf_t, dev_t, int , u_int (*)(buf_t), struct uio *, int );
+
+
+/*
+ * Flags for operation type in getblk()
+ */
+#define BLK_READ 0x01 /* buffer for read */
+#define BLK_WRITE 0x02 /* buffer for write */
+#define BLK_META 0x10 /* buffer for metadata */
+/*
+ * modifier for above flags... if set, getblk will only return
+ * a bp that is already valid... i.e. found in the cache
+ */
+#define BLK_ONLYVALID 0x80000000
+
+/* timeout is in msecs */
+buf_t buf_getblk(vnode_t, daddr64_t, int, int, int, int);
+buf_t buf_geteblk(int);
+
+__END_DECLS
+
+
+/* Macros to clear/set/test flags. */
+#define SET(t, f) (t) |= (f)
+#define CLR(t, f) (t) &= ~(f)
+#define ISSET(t, f) ((t) & (f))
+