Fix potential integer overflow in shifts (cppcheck)

pull/508/head
Daniele Lacamera 2024-10-11 09:19:46 +02:00
parent 95d58244a9
commit cb77e4273c
1 changed files with 3 additions and 3 deletions

View File

@ -705,11 +705,11 @@ static void dbgu_init(void) {
PMC_CLOCK_EN(GPIOB_PMCID);
/* Disable Pull */
GPIO_PPUDR(DBGU_GPIO) = (1 << DBGU_PIN_TX) | (1 << DBGU_PIN_RX);
GPIO_PPDDR(DBGU_GPIO) = (1 << DBGU_PIN_TX) | (1 << DBGU_PIN_RX);
GPIO_PPUDR(DBGU_GPIO) = (1U << DBGU_PIN_TX) | (1U << DBGU_PIN_RX);
GPIO_PPDDR(DBGU_GPIO) = (1U << DBGU_PIN_TX) | (1U << DBGU_PIN_RX);
/* Set "Peripheral A" */
GPIO_ASR(DBGU_GPIO) = (1 << DBGU_PIN_TX) | (1 << DBGU_PIN_RX);
GPIO_ASR(DBGU_GPIO) = (1U << DBGU_PIN_TX) | (1U << DBGU_PIN_RX);
/* Enable the peripheral clock for the DBGU */
PMC_CLOCK_EN(DBGU_PMCID);