refactor(spi): hal driver doesn't depend on sdkconfig.h

This commit is contained in:
morris
2024-12-03 11:25:43 +08:00
parent 7eb99d7bd6
commit 1316d7b741
20 changed files with 86 additions and 76 deletions
+2 -2
View File
@@ -275,10 +275,10 @@ __attribute__((weak)) void esp_perip_clk_init(void)
//a weird mode where clock to the peripheral is disabled but reset is also disabled, it 'hangs'
//in a state where it outputs a continuous 80MHz signal. Mask its bit here because we should
//not modify that state, regardless of what we calculated earlier.
if (spicommon_periph_in_use(HSPI_HOST)) {
if (spicommon_periph_in_use(SPI2_HOST)) {
common_perip_clk &= ~DPORT_SPI2_CLK_EN;
}
if (spicommon_periph_in_use(VSPI_HOST)) {
if (spicommon_periph_in_use(SPI3_HOST)) {
common_perip_clk &= ~DPORT_SPI3_CLK_EN;
}
#endif