1
0
Fork 0
forked from len0rd/rockbox

fat: Ensure bounce buffer is a multiple of MAX_PHYS_SECTOR_SIZE

* if MAX_VARIABLE_LOG_SECTOR is defined, use that
 * if MAX_PHYS_SECTOR_SIZE is defined, use that
 * use SECTOR_SIZE

Change-Id: Ia314f590fdb300e99df2c60587657c9563b9ce80
This commit is contained in:
Solomon Peachy 2024-11-26 08:15:07 -05:00
parent ff9da12763
commit b8d2ba3fc4

View file

@ -280,6 +280,8 @@ static struct bpb
#ifdef STORAGE_NEEDS_BOUNCE_BUFFER
#if defined(MAX_VARIABLE_LOG_SECTOR)
#define BOUNCE_SECTOR_SIZE MAX_VARIABLE_LOG_SECTOR
#elif defined(MAX_PHYS_SECTOR_SIZE)
#define BOUNCE_SECTOR_SIZE MAX_PHYS_SECTOR_SIZE
#else
#define BOUNCE_SECTOR_SIZE SECTOR_SIZE
#endif