[X9E] Massstorage OK?
This commit is contained in:
@@ -29,8 +29,6 @@
|
||||
#include "opentx.h"
|
||||
#include "sdio_sd.h"
|
||||
|
||||
#define BLOCK_SIZE 512 /* Block Size in Bytes */
|
||||
|
||||
/*-----------------------------------------------------------------------*/
|
||||
/* Lock / unlock functions */
|
||||
/*-----------------------------------------------------------------------*/
|
||||
@@ -134,9 +132,9 @@ DRESULT __disk_read (
|
||||
return RES_NOTRDY;
|
||||
}
|
||||
|
||||
if ((DWORD)buff < 0x20000000 /*|| (DWORD)buff >= 0x20030000*/ || ((DWORD)buff & 3)) {
|
||||
if ((DWORD)buff < 0x20000000 || ((DWORD)buff & 3)) {
|
||||
TRACE("disk_read bad alignment (%p)", buff);
|
||||
while(count--) {
|
||||
while (count--) {
|
||||
res = disk_read(drv, (BYTE *)scratch, sector++, 1);
|
||||
|
||||
if (res != RES_OK) {
|
||||
@@ -211,7 +209,7 @@ DRESULT __disk_write (
|
||||
if (SD_Detect() != SD_PRESENT)
|
||||
return(RES_NOTRDY);
|
||||
|
||||
if ((DWORD)buff < 0x20000000 /*|| (DWORD)buff >= 0x20030000*/ || ((DWORD)buff & 3)) {
|
||||
if ((DWORD)buff < 0x20000000 || ((DWORD)buff & 3)) {
|
||||
TRACE("disk_write bad alignment (%p)", buff);
|
||||
while(count--) {
|
||||
memcpy(scratch, buff, BLOCK_SIZE);
|
||||
|
||||
Reference in New Issue
Block a user