diff options
Diffstat (limited to 'firmware')
-rw-r--r-- | firmware/usbstack/usb_storage.c | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/firmware/usbstack/usb_storage.c b/firmware/usbstack/usb_storage.c index 0d06221750..b498311014 100644 --- a/firmware/usbstack/usb_storage.c +++ b/firmware/usbstack/usb_storage.c | |||
@@ -53,10 +53,16 @@ | |||
53 | * wouldn't buy us anything. | 53 | * wouldn't buy us anything. |
54 | * Due to being the double-buffering system used, using a smaller write buffer | 54 | * Due to being the double-buffering system used, using a smaller write buffer |
55 | * ends up being more efficient. Measurements have shown that 24k to 28k is | 55 | * ends up being more efficient. Measurements have shown that 24k to 28k is |
56 | * optimal | 56 | * optimal, except for sd devices that apparently don't gain anything from |
57 | * double-buffering | ||
57 | */ | 58 | */ |
58 | #define READ_BUFFER_SIZE (1024*64) | 59 | #define READ_BUFFER_SIZE (1024*64) |
60 | |||
61 | #if (CONFIG_STORAGE & STORAGE_SD) | ||
62 | #define WRITE_BUFFER_SIZE (1024*64) | ||
63 | #else | ||
59 | #define WRITE_BUFFER_SIZE (1024*24) | 64 | #define WRITE_BUFFER_SIZE (1024*24) |
65 | #endif | ||
60 | 66 | ||
61 | #define ALLOCATE_BUFFER_SIZE (2*MAX(READ_BUFFER_SIZE,WRITE_BUFFER_SIZE)) | 67 | #define ALLOCATE_BUFFER_SIZE (2*MAX(READ_BUFFER_SIZE,WRITE_BUFFER_SIZE)) |
62 | 68 | ||