Commit Graph

11260 Commits (f57cc80ecc15ba7ee08c74eb0b0c9fb276374421)

Author SHA1 Message Date
Vincent Coubard f57cc80ecc event: Make the event queue non copyable. 2017-06-20 16:23:45 +01:00
Vincent Coubard 3119c4238d rtos Thread: Remove private copy constructor and assignment operators in favor of the NonCopyable traits. 2017-06-20 16:23:44 +01:00
Vincent Coubard 4d5f805cde rtos: Tag non value type as NonCopyable.
The types marked are: Mail, MemoryPool, Mutex, Queue, RtosTimer and Semaphore.
2017-06-20 16:23:44 +01:00
Vincent Coubard 7a1e2cfc9a platform: Replace private copy constructor and copy assignement operator by a NonCopyable tag.
The class concerned by this change are: ATCmdParser, CallChain, FileBase and Stream.
2017-06-20 16:23:43 +01:00
Vincent Coubard dcbcf64830 platform: Tag classes DirHandle, FileHandle, FileLike, FileSystemHandle, FileSystemLike, LocalFileHandle, LocalFileSystem and PlatformMutex as non copyable.
This avoid unwanted copy of these type which is a programming error.
2017-06-20 16:23:43 +01:00
Vincent Coubard 4f7943860a platform: Add NonCopyable class.
The NonCopyable template class avoid autogeneration of copy assignement
and copy construction function for classes inheriting from it.
2017-06-20 15:49:16 +01:00
Jimmy Brisson c08864b588 Merge pull request #4444 from Archcady/lwip_issue
resolve lwip init twice issue
2017-06-19 18:28:49 -05:00
Jimmy Brisson 77b6127a71 Merge pull request #4579 from geky/rtos-unbreak-semaphore
RTOS: Fix semaphore
2017-06-19 15:32:48 -05:00
Jimmy Brisson 2e87f56a55 Merge pull request #4541 from theotherjimmy/fix-large-string
Fix a bug in print_large_string
2017-06-19 12:00:07 -05:00
Jimmy Brisson b56d9f3df3 Merge pull request #4540 from theotherjimmy/export-app-config
Support app config option for export
2017-06-19 11:59:38 -05:00
Jimmy Brisson 1ffbdfc048 Merge pull request #4364 from mazimkhan/mbed-tls-test
Add C API for Greentea client
2017-06-19 11:58:47 -05:00
Jimmy Brisson d8061216fe Merge pull request #4563 from c1728p9/fix_stack_overflow
Increase background stack size to fix overflow
2017-06-19 11:04:51 -05:00
Jimmy Brisson 3f464217f1 Merge pull request #4554 from LMESTM/L476RG_ld_file
Fix NUCLEO_L476RG linker scripts
2017-06-19 11:04:10 -05:00
Jimmy Brisson a6695ae5a8 Merge pull request #4504 from geky/gt-add-reserved-memory-reporting
greentea: Add reporting of reserved heap
2017-06-19 11:03:30 -05:00
Jimmy Brisson e4bdedc7c2 Merge pull request #4562 from geky/fat-init-bd
fatfs: Fixed initialization of block device in mount/unmount functions
2017-06-19 11:02:52 -05:00
Jimmy Brisson 737a64c988 Merge pull request #4502 from LMESTM/issue_899
STM32: serial: clear Overrun flag if it is set when checking if readable
2017-06-19 11:00:23 -05:00
Christopher Haster 6b02ceab5d rtos: Unbreak semaphore, trade assert for saturation with original limit
Before rtx 5, the max count on semaphores was UINT16_MAX, aftewards it
was decreased to 1024 with an assert on overflow.

This is especially problematic for semaphores used for signaling, since
there is no replacement currently available in C++.
2017-06-16 17:18:40 -05:00
Vincent Coubard 970ee38079 NRF52840: Adjust idle thread stack size.
A stack size of 256 bytes is not enough on the NRF52840, this patch
changes it to a size of 512 bytes.
2017-06-16 10:15:03 +01:00
Vincent Coubard fd7eff202c RTOS: Allow per target definition of OS_IDLE_THREAD_STACK_SIZE.
The stack required for the idle thread is highly dependent on the
target because it will call the sleep function which is target
specific.

While 256 bytes of stack is enough for most targets, others like the
NRF52840 might require more.

With this change, target maintainers can specify the idle thread stack
size in their mbed_rtx.h file.
2017-06-16 10:11:12 +01:00
Sam Grove 226af545a4 Merge pull request #4510 from kegilbert/rearrange-odin-target-rebase
u-blox rearrange ODIN target
2017-06-15 11:20:48 -05:00
Sam Grove f16ca562db Merge pull request #4516 from theotherjimmy/filname-ci
Check for correct library naming in Travis CI
2017-06-15 11:20:32 -05:00
Sam Grove 109269da9c Merge pull request #4414 from tkaman/master
Enable CM3DS_MPS2 target
2017-06-15 11:20:09 -05:00
Sam Grove 74b6e8cc4c Merge pull request #4530 from bridadan/verbose_example_build
Enable verbose builds when running example build tests
2017-06-15 11:19:08 -05:00
Sam Grove 9787c5aff7 Merge pull request #4542 from NXPmicro/Update_K82_UART_Clock_Init
Issue#4528 K82F: Move the UART clock inititialization to board specif…
2017-06-15 11:18:47 -05:00
Sam Grove d7c5be26ef Merge pull request #4544 from theotherjimmy/export-static-files
Export static files from mbed export
2017-06-15 11:18:28 -05:00
Sam Grove c3f4130e99 Merge pull request #4545 from theotherjimmy/uvision-whitelist
Filter support with a white list of post-bin hooks in uvision
2017-06-15 11:17:38 -05:00
Anna Bridge a6828bbc6b Merge pull request #4566 from 0xc0170/fix_mbed2_failures
Fix mbed2 failures
2017-06-15 14:54:16 +01:00
Martin Kojtal dad71c4268 cmsis: add core_ca9 for backward compatibility
cmsis 5 does not include it but as mbed 2 requires this, we will bring this file
back. This brings back few other dependencies, that we add only for cortex-a.

Once cortex-a gets cmsis5 and rtx2 support it will be updated.
2017-06-15 13:08:48 +01:00
Martin Kojtal 0f61af58a2 ncs36510: timer.h rename
This fixes an issue as Timer.h is mbed file, thus if this file gets included first,
causes failures.
2017-06-15 12:15:00 +01:00
Martin Kojtal db71029eb7 targets: micronfcboard should add macros, not overwrite 2017-06-15 12:09:05 +01:00
Russ Butler fc18250b1f Increase background stack size to fix overflow
Bump the background stack size to 512 bytes to fix stack overflows on
the NRF52 and so it is the same size as it was before the switch to
RTX5.
2017-06-14 17:31:52 -05:00
Christopher Haster d7fe4ff599 fatfs: Fixed initialization of block device in mount/unmount functions
At some point the "mount" parameter for "f_mount" was name "force". This
led to a bit of confusion that ended with the default mount function
never calling block device init.

This is fine, since the block device can be manually initialized, but
a better user experience is where the filesystem initializes the block
device for the user.

This is backwards compatible due to the repeatability of the block
device init functions.
2017-06-14 16:35:15 -05:00
Andreas Larsson 6a270fb348 Moved ODIN target files into STM32F439xI folder to avoid duplicate code 2017-06-14 13:21:04 -05:00
Sam Grove ee864cdd7b Merge pull request #4543 from c1728p9/fix_stm_nvic
Fix STM32 crashes on boot due to unset VTOR
2017-06-14 10:47:53 -05:00
Laurent MEUNIER 73eebaad19 NUCLEO_L476RG: FLASH size of 1MB, not 2MB
MBED_APP_SIZE was erroneously defined to 2MB for this target,
while it's only 1MB.
2017-06-14 16:52:08 +02:00
Laurent MEUNIER 1d802028cf NUCLEO_L476RG: GCC_ARM ld file fix
Following
Merge pull request #4063 from LMESTM/17q2_L4_bootloader
the NUCLEO_L476RG binairies could not boot anymore.

The change done in #4063 was derived from work on NUCLEO_L429ZI target
which supports uvisor. The VECTORS defintiion is introduced as part of
uvisor support and requires further changes in ld file which were missing.
As uvisor is not considered yet, we remove VECTORS for now and will
introduce only when needed.
2017-06-14 16:48:29 +02:00
Jimmy Brisson 60fea42fdb Filter supported devices with a post-bin whitelist in uvision 2017-06-13 15:55:36 -05:00
Jimmy Brisson f81444d4f8 Export static files from mbed export 2017-06-13 13:40:30 -05:00
Russ Butler 47b78a2d17 Fix STM32 crashes on boot due to unset VTOR
Remove HAL_Init and related code from SystemInit and move it to
mbed_sdk_init. The function SystemInit is called early in the boot
sequence before RAM is initialized or the VTOR is setup, so it should
not be used to perform the HAL initialization.

This fixes crashes due the vector table being used before it has been
relocated.
2017-06-13 12:12:20 -05:00
Mahadevan Mahesh ef00edf934 Issue#4528 K82F: Move the UART clock inititialization to board specific file
Signed-off-by: Mahadevan Mahesh <Mahesh.Mahadevan@nxp.com>
2017-06-13 12:10:16 -05:00
Jimmy Brisson 724112586d Fix a bug in print_large_string 2017-06-13 11:43:25 -05:00
Jimmy Brisson c4a6163ce5 Accept app config option for export 2017-06-13 10:30:05 -05:00
Yuguo Zou b1ca77b6b8 A better approach to flip "netif_inited" 2017-06-13 18:04:00 +08:00
Azim Khan 0b929199e4 Remove multiple definition of GREENTEA_SETUP added due to rebase 2017-06-13 10:02:55 +01:00
Martin Kojtal 35999be018 Merge pull request #4536 from c1728p9/fix_st_socket_problem
STM32 - fix bug where sockets stop receiving data
2017-06-13 09:09:35 +01:00
Russ Butler 9620b0fc7f STM32 - fix bug were sockets stop receiving data
The function _eth_arch_low_level_input() is meant to pass data into
LWIP and to prepare the ethernet buffers to receive more data.
If the LWIP heap is empty and the call to pbuf_alloc() in
_eth_arch_low_level_input returns null, the ethernet receive buffers
are not updated to receive data. Because of this the ethernet RX
interrupt will not fire. Since the RX interrupt is the only thing that
triggers a call to _eth_arch_low_level_input(), the receive buffers
will never get cleared, and the device stops receiving data.

To prevent this from happening, this patch ensures that the function
_eth_arch_low_level_input() clears the receive buffers even if a new
pbuf for the data couldn't be allocated.

This issue can be reproduce by running the test
"features-feature_lwip-tests-mbedmicro-net-udp_echo_parallel"
and on the same machine running the below python script to flood the
device with UDP broadcast packets:

MY_IP = #ADD your local IP here
from socket import *
s = socket(AF_INET, SOCK_DGRAM)
s.bind((MY_IP, 1234))
s.setsockopt(SOL_SOCKET, SO_REUSEADDR, 1)
s.setsockopt(SOL_SOCKET, SO_BROADCAST, 1)
for _ in range(1000):
    s.sendto("test data", ('255.255.255.255', 1234))
print("Message sent")
2017-06-12 22:18:04 -05:00
Brian Daniels fd4cd43043 Enable verbose builds when running example build tests 2017-06-12 11:25:01 -05:00
Jimmy Brisson 946d160c0f Check for IAR libraries as well 2017-06-12 11:10:23 -05:00
Azim Khan b3cbb07566 Merge greentea-client/test_env_c.h into greentea-client/test_env.h 2017-06-12 13:46:22 +01:00
Azim Khan 82d948de6b Revert greentea_getc() to return 'int' 2017-06-12 13:46:22 +01:00