disk: delete the GET_DISK_SIZE IOCTL.
The argument is a u32_t which limits the maximum disk size to 4 GiB. Rather than fix this, delete the ioctl and switch the only use to GET_SECTOR_COUNT instead. Signed-off-by: Michael Hope <mlhx@google.com>
This commit is contained in:
parent
f3653b1a5c
commit
cff16051bb
4 changed files with 4 additions and 13 deletions
|
@ -268,9 +268,6 @@ int disk_access_ioctl(u8_t cmd, void *buff)
|
|||
case DISK_IOCTL_GET_ERASE_BLOCK_SZ: /* in sectors */
|
||||
*(u32_t *)buff = CONFIG_DISK_ERASE_BLOCK_SIZE / SECTOR_SIZE;
|
||||
return 0;
|
||||
case DISK_IOCTL_GET_DISK_SIZE:
|
||||
*(u32_t *)buff = CONFIG_DISK_VOLUME_SIZE;
|
||||
return 0;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
|
|
|
@ -71,9 +71,6 @@ int disk_access_ioctl(u8_t cmd, void *buff)
|
|||
case DISK_IOCTL_GET_ERASE_BLOCK_SZ:
|
||||
*(u32_t *)buff = 1;
|
||||
break;
|
||||
case DISK_IOCTL_GET_DISK_SIZE:
|
||||
*(u32_t *)buff = RAMDISK_VOLUME_SIZE;
|
||||
break;
|
||||
default:
|
||||
return -EINVAL;
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue