mirror of
https://github.com/FreeRTOS/FreeRTOS-Kernel.git
synced 2025-04-20 05:21:59 -04:00
Ensure the SmartFusion2 interrupt driven UART drivers are not passed a zero length buffer.
This commit is contained in:
parent
94f178c8d1
commit
9b153b3e06
|
@ -50,7 +50,7 @@
|
||||||
</option>
|
</option>
|
||||||
<option id="gnu.c.compiler.option.misc.verbose.1351799799" name="Verbose (-v)" superClass="gnu.c.compiler.option.misc.verbose" value="true" valueType="boolean"/>
|
<option id="gnu.c.compiler.option.misc.verbose.1351799799" name="Verbose (-v)" superClass="gnu.c.compiler.option.misc.verbose" value="true" valueType="boolean"/>
|
||||||
<option id="gnu.c.compiler.option.optimization.flags.435998408" name="Other optimization flags" superClass="gnu.c.compiler.option.optimization.flags" value="-ffunction-sections -fdata-sections" valueType="string"/>
|
<option id="gnu.c.compiler.option.optimization.flags.435998408" name="Other optimization flags" superClass="gnu.c.compiler.option.optimization.flags" value="-ffunction-sections -fdata-sections" valueType="string"/>
|
||||||
<option id="gnu.c.compiler.option.misc.other.1001754914" superClass="gnu.c.compiler.option.misc.other" value="-c -fmessage-length=0 -Wextra" valueType="string"/>
|
<option id="gnu.c.compiler.option.misc.other.1001754914" name="Other flags" superClass="gnu.c.compiler.option.misc.other" value="-c -fmessage-length=0 -Wextra" valueType="string"/>
|
||||||
<inputType id="cdt.managedbuild.tool.gnu.c.compiler.input.2036217646" superClass="cdt.managedbuild.tool.gnu.c.compiler.input"/>
|
<inputType id="cdt.managedbuild.tool.gnu.c.compiler.input.2036217646" superClass="cdt.managedbuild.tool.gnu.c.compiler.input"/>
|
||||||
</tool>
|
</tool>
|
||||||
<tool id="cdt.managedbuild.tool.gnu.cpp.compiler.cross.cortexm3.exe.debug.612642130" name="GNU C++ Compiler" superClass="cdt.managedbuild.tool.gnu.cpp.compiler.cross.cortexm3.exe.debug">
|
<tool id="cdt.managedbuild.tool.gnu.cpp.compiler.cross.cortexm3.exe.debug.612642130" name="GNU C++ Compiler" superClass="cdt.managedbuild.tool.gnu.cpp.compiler.cross.cortexm3.exe.debug">
|
||||||
|
|
|
@ -240,6 +240,8 @@ static void prvSendBuffer( const uint8_t * pcBuffer, size_t xBufferLength )
|
||||||
{
|
{
|
||||||
const portTickType xVeryShortDelay = 2UL;
|
const portTickType xVeryShortDelay = 2UL;
|
||||||
|
|
||||||
|
if( xBufferLength > 0 )
|
||||||
|
{
|
||||||
MSS_UART_irq_tx( ( mss_uart_instance_t * ) pxUART, pcBuffer, xBufferLength );
|
MSS_UART_irq_tx( ( mss_uart_instance_t * ) pxUART, pcBuffer, xBufferLength );
|
||||||
|
|
||||||
/* Ensure any previous transmissions have completed. The default UART
|
/* Ensure any previous transmissions have completed. The default UART
|
||||||
|
@ -252,6 +254,7 @@ const portTickType xVeryShortDelay = 2UL;
|
||||||
{
|
{
|
||||||
vTaskDelay( xVeryShortDelay );
|
vTaskDelay( xVeryShortDelay );
|
||||||
}
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
/*-----------------------------------------------------------*/
|
/*-----------------------------------------------------------*/
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue