Finish removing reserved psram
This commit is contained in:
parent
fb840159fb
commit
b47e23c9c5
@ -41,9 +41,6 @@ NORETURN void mp_raise_espidf_MemoryError(void);
|
||||
void raise_esp_error(esp_err_t err) NORETURN;
|
||||
#define CHECK_ESP_RESULT(x) do { int res = (x); if (res != ESP_OK) raise_esp_error(res); } while (0)
|
||||
|
||||
void common_hal_espidf_reserve_psram(void);
|
||||
bool common_hal_espidf_set_reserved_psram(size_t amount);
|
||||
size_t common_hal_espidf_get_reserved_psram(void);
|
||||
size_t common_hal_espidf_get_total_psram(void);
|
||||
intptr_t common_hal_espidf_get_psram_start(void);
|
||||
intptr_t common_hal_espidf_get_psram_end(void);
|
||||
|
@ -54,21 +54,6 @@ static size_t psram_size_usable(void) {
|
||||
#endif
|
||||
}
|
||||
|
||||
bool common_hal_espidf_set_reserved_psram(size_t amount) {
|
||||
#ifdef CONFIG_SPIRAM
|
||||
if (!esp_psram_is_initialized()) {
|
||||
return false;
|
||||
}
|
||||
if (amount > psram_size_usable()) {
|
||||
return false;
|
||||
}
|
||||
reserved_psram = amount;
|
||||
return true;
|
||||
#else
|
||||
return false;
|
||||
#endif
|
||||
}
|
||||
|
||||
size_t common_hal_espidf_get_total_psram(void) {
|
||||
return psram_size_usable();
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user