summaryrefslogtreecommitdiff
path: root/supervisor/shared
diff options
context:
space:
mode:
authorScott Shawcroft <scott@tannewt.org>2020-04-27 16:45:10 -0700
committerScott Shawcroft <scott@tannewt.org>2020-04-27 16:45:10 -0700
commit755d404edf00ab99bb8497d2e4a36ba18dd17a69 (patch)
treea705a06789c0d9b182633ff669380e241b1acc59 /supervisor/shared
parentf13de32208716387ca822fd25625325162b5c2f1 (diff)
parentfaa50df05fa11c3903934419a2ad7d7063cf23c7 (diff)
Merge remote-tracking branch 'adafruit/master' into lower_power
Diffstat (limited to 'supervisor/shared')
-rw-r--r--supervisor/shared/external_flash/devices.h19
-rw-r--r--supervisor/shared/usb/usb_desc.c2
2 files changed, 20 insertions, 1 deletions
diff --git a/supervisor/shared/external_flash/devices.h b/supervisor/shared/external_flash/devices.h
index fd9224f56..57c52e2ea 100644
--- a/supervisor/shared/external_flash/devices.h
+++ b/supervisor/shared/external_flash/devices.h
@@ -481,6 +481,25 @@ typedef struct {
.single_status_byte = true, \
}
+// Settings for the Macronix MX25R1635F 8MiB SPI flash.
+// Datasheet: https://www.macronix.com/Lists/Datasheet/Attachments/7595/MX25R1635F,%20Wide%20Range,%2016Mb,%20v1.6.pdf
+// In low power mode, quad operations can only run at 8 MHz.
+#define MX25R1635F {\
+ .total_size = (1 << 21), /* 2 MiB */ \
+ .start_up_time_us = 800, \
+ .manufacturer_id = 0xc2, \
+ .memory_type = 0x28, \
+ .capacity = 0x18, \
+ .max_clock_speed_mhz = 33, /* 8 mhz for dual/quad */ \
+ .quad_enable_bit_mask = 0x80, \
+ .has_sector_protection = false, \
+ .supports_fast_read = true, \
+ .supports_qspi = true, \
+ .supports_qspi_writes = true, \
+ .write_status_register_split = false, \
+ .single_status_byte = true, \
+}
+
// Settings for the Macronix MX25L51245G 64MiB SPI flash.
// Datasheet: https://www.macronix.com/Lists/Datasheet/Attachments/7437/MX25L51245G,%203V,%20512Mb,%20v1.6.pdf
#define MX25L51245G {\
diff --git a/supervisor/shared/usb/usb_desc.c b/supervisor/shared/usb/usb_desc.c
index 9b333d6fe..080187ebc 100644
--- a/supervisor/shared/usb/usb_desc.c
+++ b/supervisor/shared/usb/usb_desc.c
@@ -52,7 +52,7 @@ uint8_t const * tud_hid_descriptor_report_cb(void) {
// Invoked when received GET STRING DESCRIPTOR request
// Application return pointer to descriptor, whose contents must exist long enough for transfer to complete
-uint16_t const* tud_descriptor_string_cb(uint8_t index) {
+uint16_t const* tud_descriptor_string_cb(uint8_t index, uint16_t langid) {
uint8_t const max_index = sizeof(string_desc_arr)/sizeof(string_desc_arr[0]);
return (index < max_index) ? string_desc_arr[index] : NULL;
}