1 /* SPDX-License-Identifier: GPL-2.0+ */
3 * Copyright (c) 2013, Henrik Nordstrom <henrik@henriknordstrom.net>
6 #ifndef __SANDBOX_BLOCK_DEV__
7 #define __SANDBOX_BLOCK_DEV__
9 /* Maximum number of host devices - see drivers/block/sandbox.c */
10 #define SANDBOX_HOST_MAX_DEVICES 4
12 struct host_block_dev {
14 struct blk_desc blk_dev;
21 * host_dev_bind() - Bind or unbind a device
23 * @dev: Device number (0=first slot)
24 * @filename: Host filename to use, or NULL to unbind
25 * @removable: true if the block device should mark itself as removable
27 int host_dev_bind(int dev, char *filename, bool removable);