* }
* \endcode
*
+ * \note The KBlock interface is optimized for block reads. If you need a
+ * file-like access, you can use \ref kfile_block.
+ *
* \author Francesco Sacchi <batt@develer.com>
*
* $WIZ$ module_name = "kblock"
* \param start The index of the start block for the limiting window in logical addressing units.
* \param count The number of blocks to be used.
*
+ * \return 0 if all is OK, EOF on errors.
*/
-INLINE void kblock_trim(struct KBlock *b, block_idx_t start, block_idx_t count)
-{
- ASSERT(start + count <= b->blk_cnt);
- b->priv.blk_start += start;
- b->blk_cnt = count;
-}
+int kblock_trim(struct KBlock *b, block_idx_t start, block_idx_t count);
#define KB_ASSERT_METHOD(b, method) \