The disk_read function reads sector(s) from the disk drive.
DRESULT disk_read ( BYTE Drive, /* Physical drive number */ BYTE* Buffer, /* Pointer to the read data buffer */ DWORD SectorNumber, /* Start sector number */ BYTE SectorCount /* Number of sectros to read */ );
The specified memory address is not that always aligned to word boundary because the type of pointer is defined as BYTE. The misaligned read/write request can occure at direct transfer. If the bus architecture, especially DMA controller, does not allow misaligned memory access, it should be solved in this function. There are some workarounds below to avoid this problem.