[PATCH] switch brd
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
This commit is contained in:
Родитель
60ad234007
Коммит
2b9ecd0333
|
@ -340,11 +340,10 @@ static int brd_direct_access (struct block_device *bdev, sector_t sector,
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
static int brd_ioctl(struct inode *inode, struct file *file,
|
static int brd_ioctl(struct block_device *bdev, fmode_t mode,
|
||||||
unsigned int cmd, unsigned long arg)
|
unsigned int cmd, unsigned long arg)
|
||||||
{
|
{
|
||||||
int error;
|
int error;
|
||||||
struct block_device *bdev = inode->i_bdev;
|
|
||||||
struct brd_device *brd = bdev->bd_disk->private_data;
|
struct brd_device *brd = bdev->bd_disk->private_data;
|
||||||
|
|
||||||
if (cmd != BLKFLSBUF)
|
if (cmd != BLKFLSBUF)
|
||||||
|
@ -376,7 +375,7 @@ static int brd_ioctl(struct inode *inode, struct file *file,
|
||||||
|
|
||||||
static struct block_device_operations brd_fops = {
|
static struct block_device_operations brd_fops = {
|
||||||
.owner = THIS_MODULE,
|
.owner = THIS_MODULE,
|
||||||
.__ioctl = brd_ioctl,
|
.locked_ioctl = brd_ioctl,
|
||||||
#ifdef CONFIG_BLK_DEV_XIP
|
#ifdef CONFIG_BLK_DEV_XIP
|
||||||
.direct_access = brd_direct_access,
|
.direct_access = brd_direct_access,
|
||||||
#endif
|
#endif
|
||||||
|
|
Загрузка…
Ссылка в новой задаче