#include <oskit/dev/linux.h>oskit_error_t oskit_linux_block_open(const char *name, unsigned flags, [out] oskit_blkio_t **out_io);
This function takes a Linux name of a disk, e.g., ``sd0'' or ``wd1'', and returns an oskit_blkio_t that can be used to access the device.The oskit_blkio interface is described in Chapter 5.
- name
- The Linux name of the device e.g., ``sd0'' or ``wd1''.
- flags
- Formed by or'ing the following values:
- OSKIT_DEV_OPEN_READ
- OSKIT_DEV_OPEN_WRITE
- OSKIT_DEV_OPEN_ALL
- out_io
- Upon success, is set to point to an oskit_blkio_t that can be used to access the device.
Returns 0 on success, or an error code specified in <oskit/error.h>, on error.