11/*-----------------------------------------------------------------------/
2- / Low level disk interface modlue include file (C)ChaN, 2014 /
2+ / Low level disk interface modlue include file (C)ChaN, 2019 /
33/-----------------------------------------------------------------------*/
44
55#ifndef _DISKIO_DEFINED
99extern "C" {
1010#endif
1111
12- #include "integer.h"
13-
14-
1512/* Status of Disk Functions */
1613typedef BYTE DSTATUS ;
1714
@@ -31,8 +28,8 @@ typedef enum {
3128
3229DSTATUS disk_initialize (BYTE pdrv );
3330DSTATUS disk_status (BYTE pdrv );
34- DRESULT disk_read (BYTE pdrv , BYTE * buff , DWORD sector , UINT count );
35- DRESULT disk_write (BYTE pdrv , const BYTE * buff , DWORD sector , UINT count );
31+ DRESULT disk_read (BYTE pdrv , BYTE * buff , LBA_t sector , UINT count );
32+ DRESULT disk_write (BYTE pdrv , const BYTE * buff , LBA_t sector , UINT count );
3633DRESULT disk_ioctl (BYTE pdrv , BYTE cmd , void * buff );
3734
3835
@@ -46,11 +43,11 @@ DRESULT disk_ioctl (BYTE pdrv, BYTE cmd, void* buff);
4643/* Command code for disk_ioctrl fucntion */
4744
4845/* Generic command (Used by FatFs) */
49- #define CTRL_SYNC 0 /* Complete pending write process (needed at _FS_READONLY == 0) */
50- #define GET_SECTOR_COUNT 1 /* Get media size (needed at _USE_MKFS == 1) */
51- #define GET_SECTOR_SIZE 2 /* Get sector size (needed at _MAX_SS != _MIN_SS ) */
52- #define GET_BLOCK_SIZE 3 /* Get erase block size (needed at _USE_MKFS == 1) */
53- #define CTRL_TRIM 4 /* Inform device that the data on the block of sectors is no longer used (needed at _USE_TRIM == 1) */
46+ #define CTRL_SYNC 0 /* Complete pending write process (needed at FF_FS_READONLY == 0) */
47+ #define GET_SECTOR_COUNT 1 /* Get media size (needed at FF_USE_MKFS == 1) */
48+ #define GET_SECTOR_SIZE 2 /* Get sector size (needed at FF_MAX_SS != FF_MIN_SS ) */
49+ #define GET_BLOCK_SIZE 3 /* Get erase block size (needed at FF_USE_MKFS == 1) */
50+ #define CTRL_TRIM 4 /* Inform device that the data on the block of sectors is no longer used (needed at FF_USE_TRIM == 1) */
5451
5552/* Generic command (Not used by FatFs) */
5653#define CTRL_POWER 5 /* Get/Set power status */
0 commit comments