Skip to content

Commit ab5f47c

Browse files
iabdalkaderdpgeorge
authored andcommitted
alif/ospi_flash: Remove workaround for P10_7 OSPI pinmux issue.
P5_6 doesn't have that alt function, and only has 7 alt functions. This workaround was never really needed, it was introduced in DFP because the wrong P10_7 alt function was used, in original DFP sources. This has been removed from DFP starting with 1.3.4, so remove it here also. Signed-off-by: iabdalkader <i.abdalkader@gmail.com>
1 parent 2554e41 commit ab5f47c

2 files changed

Lines changed: 1 addition & 7 deletions

File tree

ports/alif/mcu/ensemble_pin_alt.csv

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -45,8 +45,7 @@ P5_2,GPIO,OSPI1_SCLKN,UART5_RX,PDM_C3,SPI0_SS0,LPI2C_SCL,UT1_T0,SD_D2
4545
P5_3,GPIO,OSPI1_SCLK,UART5_TX,SPI0_SCLK,LPI2C_SDA,UT1_T1,SD_D3,CDC_PCLK
4646
P5_4,GPIO,OSPI1_SS1,UART3_CTS,PDM_D2,SPI0_SS3,UT2_T0,SD_D4,CDC_DE
4747
P5_5,GPIO,OSPI1_SCLK,UART3_RTS,PDM_D3,UT2_T1,SD_D5,ETH_RXD0,CDC_HSYNC
48-
# P5_6 doesn't really have OSPI on AF1 but it's needed for P10_7 to be in OSPI1_RXDS mode
49-
P5_6,GPIO,OSPI1_RXDS,UART1_CTS,I2C2_SCL,UT3_T0,SD_D6,ETH_RXD1,CDC_VSYNC
48+
P5_6,GPIO,,UART1_CTS,I2C2_SCL,UT3_T0,SD_D6,ETH_RXD1,CDC_VSYNC
5049
P5_7,GPIO,OSPI1_SS0,UART1_RTS,I2C2_SDA,UT3_T1,SD_D7,ETH_RST,
5150
P6_0,GPIO,OSPI0_D0,UART4_DE,PDM_D0,UT4_T0,SD_D0,ETH_TXD0,
5251
P6_1,GPIO,OSPI0_D1,UART5_DE,PDM_C0,UT4_T1,SD_D1,ETH_TXD1,

ports/alif/ospi_flash.c

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -274,11 +274,6 @@ int ospi_flash_init(void) {
274274
if (pin->pin_rwds != NULL) {
275275
mp_hal_pin_config(pin->pin_rwds, MP_HAL_PIN_MODE_ALT, MP_HAL_PIN_PULL_NONE,
276276
MP_HAL_PIN_SPEED_HIGH, MP_HAL_PIN_DRIVE_12MA, MP_HAL_PIN_ALT(OSPI_RXDS, unit), true);
277-
if (pin->pin_rwds->port == PORT_10 && pin->pin_rwds->pin == PIN_7) {
278-
// Alif: P5_6 is needed to support proper alt function selection of P10_7.
279-
mp_hal_pin_config(pin_P5_6, MP_HAL_PIN_MODE_ALT, MP_HAL_PIN_PULL_NONE,
280-
MP_HAL_PIN_SPEED_HIGH, MP_HAL_PIN_DRIVE_12MA, MP_HAL_PIN_ALT(OSPI_RXDS, unit), true);
281-
}
282277
}
283278
mp_hal_pin_config(pin->pin_d0, MP_HAL_PIN_MODE_ALT, MP_HAL_PIN_PULL_NONE,
284279
MP_HAL_PIN_SPEED_HIGH, MP_HAL_PIN_DRIVE_12MA, MP_HAL_PIN_ALT(OSPI_D0, unit), true);

0 commit comments

Comments
 (0)