mirror of
https://gitlab.rtems.org/rtems/rtos/rtems.git
synced 2025-12-16 04:44:45 +08:00
bsps/riscv/.../altera_epcq_driver.c: Address type-limits warnings
This change was made to address GCC -Wtype-limits warnings. In this case, the counter variable was uint16_t but the value of ALTERA_EPCQ_CONTROLLER2_1US_TIMEOUT_VALUE was too large for uint16_t.
This commit is contained in:
committed by
Gedare Bloom
parent
32122555de
commit
69ab3140f8
@@ -872,7 +872,7 @@ static int alt_epcq_poll_for_write_in_progress (
|
|||||||
/* we'll want to implement timeout if a timeout value is specified */
|
/* we'll want to implement timeout if a timeout value is specified */
|
||||||
#if ALTERA_EPCQ_CONTROLLER2_1US_TIMEOUT_VALUE > 0
|
#if ALTERA_EPCQ_CONTROLLER2_1US_TIMEOUT_VALUE > 0
|
||||||
uint32_t timeout = ALTERA_EPCQ_CONTROLLER2_1US_TIMEOUT_VALUE;
|
uint32_t timeout = ALTERA_EPCQ_CONTROLLER2_1US_TIMEOUT_VALUE;
|
||||||
uint16_t counter = 0;
|
uint32_t counter = 0;
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
/* return -EINVAL if epcq_flash_info is NULL */
|
/* return -EINVAL if epcq_flash_info is NULL */
|
||||||
|
|||||||
Reference in New Issue
Block a user