add SYNC in function disk_ioctl
git-svn-id: https://rt-thread.googlecode.com/svn/trunk@2322 bbd45198-f89e-11dd-88c7-29a3b14d5316
This commit is contained in:
parent
4cb779d743
commit
c77e211d1d
|
@ -780,6 +780,10 @@ DRESULT disk_ioctl(BYTE drv, BYTE ctrl, void *buff)
|
||||||
rt_device_control(device, RT_DEVICE_CTRL_BLK_GETGEOME, &geometry);
|
rt_device_control(device, RT_DEVICE_CTRL_BLK_GETGEOME, &geometry);
|
||||||
|
|
||||||
*(DWORD *)buff = geometry.block_size/geometry.bytes_per_sector;
|
*(DWORD *)buff = geometry.block_size/geometry.bytes_per_sector;
|
||||||
|
}
|
||||||
|
else if (ctrl == CTRL_SYNC)
|
||||||
|
{
|
||||||
|
rt_device_control(device, RT_DEVICE_CTRL_BLK_SYNC, RT_NULL);
|
||||||
}
|
}
|
||||||
|
|
||||||
return RES_OK;
|
return RES_OK;
|
||||||
|
|
Loading…
Reference in New Issue