diff --git a/subsys/usb/device/class/msc.c b/subsys/usb/device/class/msc.c index 1971c942af87e0..1c79ed79e941e3 100644 --- a/subsys/usb/device/class/msc.c +++ b/subsys/usb/device/class/msc.c @@ -442,7 +442,7 @@ static bool readFormatCapacity(void) static bool readCapacity(void) { - uint8_t capacity[8]; + static uint8_t capacity[8]; sys_put_be32(block_count - 1, &capacity[0]); sys_put_be32(BLOCK_SIZE, &capacity[4]);