Appears when complied with -O3 optimization level
Compile: UARTSerial.cpp
../drivers/UARTSerial.cpp: In member function 'void mbed::UARTSerial::tx_irq()':
../drivers/UARTSerial.cpp:314:31: warning: 'data' may be used uninitialized in this function [-Wmaybe-uninitialized]
SerialBase::_base_putc(data);
Some platforms have interface chips with hardware flow control
enabled by default. This commit adds configurable flow control to
STDOUT.
Usage:
* Define pin names STDIO_UART_RTS for Rx-flow-control and
STDIO_UART_CTS for Tx-flow-control.
* Set target.console-uart-flow-control. Valid options are:
null, RTS, CTS, and RTSCTS.
Replace looping construct with actual block writes.
Transaction in spi_master_block_write funtion is protected by critical
section to ensure it is completed without interruption. A hardware
limitation may cause data corruption if the TX fifo is allowed to run
empty.
Compiler reminded that a variable declaration was left behind when
the code using it was put behind #ifdef. Add the missing #ifdef.
Warning being fixed:
---8<---8<----
[Warning] ns_event_loop.c@44,0: #177-D: variable "event_thread_id"
was declared but never referenced
nanostack-hal.critical-section-usable-from-interrupt -tunable was
previously added to optionally make critical section code interrupt safe.
The IRQ safe critical section is a prequisite for interrupt safe timer
callbacks.
The same flag can be used to enable calling of the timer callbacks
directly from the timer interrupt context, without bouncing them via
event thread. This removes the code and RAM consumed by EventQueue
and the thread serving the high priority events.
If the system does not have any dependencies on mbed_shared_queues,
by setting this flag the static RAM usage is now further reduced
by ~1600 bytes and code size by 4KB.
Note: the default behavior is not changed, one needs to override the
"nanostack-hal.critical-section-usable-from-interrupt" to have "true".
Any data structure used in LoRaWANBase class should be available
in a separate header in order to make the code easy to port and
easy to read as the developer doesn't need to know about all the
internal data structures being used in Mbed LoRaWAN stack.
Fix hundreds of excessive compiler warnings due to out of enum type range
Examples shown as follows:
mbed-os.lib/targets/TARGET_Realtek/TARGET_AMEBA/sdk/soc/realtek/8195a/fwlib/hal_i2c.h", Line: 329, Col: 34
mbed-os.lib/targets/TARGET_Realtek/TARGET_AMEBA/TARGET_RTL8195A/PinNames.h", Line: 172, Col: 11
Signed-off-by: Tony Wu <tonywu@realtek.com>
Simplify tickers to stop emulating 1us ticks by using native timer resolutions.
Implement ticker get info functions.
Separate rtc and lp ticker init status by implementing separate functions.
Compile: lwip_stack.c
In file included from ../features/FEATURE_LWIP/lwip-interface/lwip_stack.c:41:0:
../features/FEATURE_LWIP/lwip-interface/lwip_stack.c: In function 'mbed_lwip_bringup_2':
../features/FEATURE_LWIP/lwip-interface/ppp_lwip.h:58:44: warning: statement with no effect [-Wunused-value]
#define ppp_lwip_disconnect() ERR_IF
^
../features/FEATURE_LWIP/lwip-interface/lwip_stack.c:858:21: note: in expansion of macro 'ppp_lwip_disconnect'
ppp_lwip_disconnect();
^~~~~~~~~~~~~~~~~~~
../features/FEATURE_LWIP/lwip-interface/ppp_lwip.h:58:44: warning: statement with no effect [-Wunused-value]
#define ppp_lwip_disconnect() ERR_IF
^
../features/FEATURE_LWIP/lwip-interface/lwip_stack.c:875:21: note: in expansion of macro 'ppp_lwip_disconnect'
ppp_lwip_disconnect();
^~~~~~~~~~~~~~~~~~~
Compile: stm32f7xx_hal_pcd.c
../targets/TARGET_STM/TARGET_STM32F7/device/stm32f7xx_hal_pcd.c: In function 'PCD_WriteEmptyTxFifo':
../targets/TARGET_STM/TARGET_STM32F7/device/stm32f7xx_hal_pcd.c:1310:11: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
if (len > ep->maxpacket)
^
../targets/TARGET_STM/TARGET_STM32F7/device/stm32f7xx_hal_pcd.c:1325:13: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
if (len > ep->maxpacket)
^