Skip to content

Commit

Permalink
Merge pull request #13335 from rajkan01/netsocket_dir_restructure
Browse files Browse the repository at this point in the history
Restructure netsocket directory
  • Loading branch information
0xc0170 authored Jul 27, 2020
2 parents 315b6bd + a4c1071 commit 6bd5271
Show file tree
Hide file tree
Showing 289 changed files with 252 additions and 285 deletions.
4 changes: 2 additions & 2 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -138,7 +138,7 @@ matrix:
- ./tools/test/travis-ci/doxy-spellchecker/spell.sh platform
- ./tools/test/travis-ci/doxy-spellchecker/spell.sh events
- ./tools/test/travis-ci/doxy-spellchecker/spell.sh rtos
- ./tools/test/travis-ci/doxy-spellchecker/spell.sh features/netsocket
- ./tools/test/travis-ci/doxy-spellchecker/spell.sh connectivity/netsocket

- <<: *docs-vm
name: "doxygen"
Expand Down Expand Up @@ -249,7 +249,7 @@ matrix:
- sed -n '/``` cpp/,/```/{/```$/Q;/```/d;p;}' ${EVENTS}/README.md > main.cpp
- |
rm -r rtos/source/TARGET_CORTEX drivers/source/usb connectivity/cellular connectivity/drivers/cellular \
connectivity/libraries/ppp features/netsocket features/nanostack features/lwipstack features/frameworks/greentea-client \
connectivity/libraries/ppp connectivity/netsocket features/nanostack features/lwipstack features/frameworks/greentea-client \
features/frameworks/utest features/frameworks/unity components BUILD
- python tools/make.py -t GCC_ARM -m NUCLEO_F103RB --source=. --build=BUILD/NUCLEO_F103RB/GCC_ARM -j0
# Run local equeue tests
Expand Down
2 changes: 1 addition & 1 deletion UNITTESTS/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -112,7 +112,6 @@ set(unittest-includes-base
"${PROJECT_SOURCE_DIR}/stubs"
"${PROJECT_SOURCE_DIR}/.."
"${PROJECT_SOURCE_DIR}/../features"
"${PROJECT_SOURCE_DIR}/../features/netsocket"
"${PROJECT_SOURCE_DIR}/../platform"
"${PROJECT_SOURCE_DIR}/../storage/filesystem/littlefs/include"
"${PROJECT_SOURCE_DIR}/../storage/filesystem/fat/include"
Expand All @@ -131,6 +130,7 @@ set(unittest-includes-base
"${PROJECT_SOURCE_DIR}/../features/frameworks/mbed-trace"
"${PROJECT_SOURCE_DIR}/../connectivity/libraries/nanostack-libservice"
"${PROJECT_SOURCE_DIR}/../connectivity/libraries/nanostack-libservice/mbed-client-libservice"
"${PROJECT_SOURCE_DIR}/../connectivity/netsocket/include"
"${PROJECT_SOURCE_DIR}/../features/filesystem/fat"
"${PROJECT_SOURCE_DIR}/../features/filesystem/fat/ChaN"
"${PROJECT_SOURCE_DIR}/../features/filesystem/bd"
Expand Down
44 changes: 0 additions & 44 deletions UNITTESTS/features/netsocket/DTLSSocket/unittest.cmake

This file was deleted.

2 changes: 1 addition & 1 deletion UNITTESTS/stubs/ATHandler_stub.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
*/

#include <ctype.h>
#include "nsapi_types.h"
#include "netsocket/nsapi_types.h"
#include "events/EventQueue.h"
#include "ATHandler_stub.h"

Expand Down
2 changes: 1 addition & 1 deletion UNITTESTS/stubs/ATHandler_stub.h
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
#include "stdint.h"
#include "stdbool.h"
#include <cstddef>
#include "nsapi_types.h"
#include "netsocket/nsapi_types.h"
#include "ATHandler.h"
#include "FileHandle_stub.h"
#include "Callback.h"
Expand Down
2 changes: 1 addition & 1 deletion UNITTESTS/stubs/AT_CellularInformation_stub.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
*/

#include "AT_CellularInformation.h"
#include "nsapi_types.h"
#include "netsocket/nsapi_types.h"

using namespace mbed;

Expand Down
2 changes: 1 addition & 1 deletion UNITTESTS/stubs/AT_CellularNetwork_stub.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@
#include "CellularUtil.h"
#include "CellularLog.h"
#include "FileHandle.h"
#include "nsapi_types.h"
#include "netsocket/nsapi_types.h"

using namespace mbed;
using namespace mbed_cellular_util;
Expand Down
2 changes: 1 addition & 1 deletion UNITTESTS/stubs/CellularInterface_stub.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
* limitations under the License.
*/

#include "CellularInterface.h"
#include "netsocket/CellularInterface.h"

MBED_WEAK CellularInterface *CellularInterface::get_target_default_instance()
{
Expand Down
2 changes: 1 addition & 1 deletion UNITTESTS/stubs/ControlPlane_netif_stub.h
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
* limitations under the License.
*/

#include "ControlPlane_netif.h"
#include "netsocket/ControlPlane_netif.h"
#include <list>

namespace mbed {
Expand Down
2 changes: 1 addition & 1 deletion UNITTESTS/stubs/EMAC_mock.h
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@

#include "gtest/gtest.h"
#include "gmock/gmock.h"
#include "features/netsocket/EMAC.h"
#include "netsocket/EMAC.h"

class MockEMAC : public EMAC {
public:
Expand Down
2 changes: 1 addition & 1 deletion UNITTESTS/stubs/MeshInterface_stub.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
* limitations under the License.
*/

#include "MeshInterface.h"
#include "netsocket/MeshInterface.h"

MBED_WEAK MeshInterface *MeshInterface::get_target_default_instance()
{
Expand Down
6 changes: 3 additions & 3 deletions UNITTESTS/stubs/NetworkInterfaceDefaults_stub.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -15,9 +15,9 @@
* limitations under the License.
*/
#include "netsocket/NetworkInterface.h"
#include "WiFiInterface.h"
#include "CellularInterface.h"
#include "MeshInterface.h"
#include "netsocket/WiFiInterface.h"
#include "netsocket/CellularInterface.h"
#include "netsocket/MeshInterface.h"

MBED_WEAK WiFiInterface *WiFiInterface::get_default_instance()
{
Expand Down
4 changes: 2 additions & 2 deletions UNITTESTS/stubs/NetworkStack_stub.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,8 @@
* limitations under the License.
*/

#include "NetworkStack.h"
#include "nsapi_dns.h"
#include "netsocket/NetworkStack.h"
#include "netsocket/nsapi_dns.h"
#include "mbed.h"
#include "stddef.h"
#include <new>
Expand Down
2 changes: 1 addition & 1 deletion UNITTESTS/stubs/SocketAddress_stub.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
* limitations under the License.
*/

#include "SocketAddress.h"
#include "netsocket/SocketAddress.h"


SocketAddress::SocketAddress(const nsapi_addr_t &addr, uint16_t port)
Expand Down
2 changes: 1 addition & 1 deletion UNITTESTS/stubs/SocketStats_Stub.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
* limitations under the License.
*/

#include "SocketStats.h"
#include "netsocket/SocketStats.h"

#if MBED_CONF_NSAPI_SOCKET_STATS_ENABLED
int SocketStats::get_entry_position(const Socket *const reference_id)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@
#include "platform/mbed_chrono.h"

#include "events/EventQueue.h"
#include "nsapi_types.h"
#include "netsocket/nsapi_types.h"

#include "Callback.h"
#include "rtos/Kernel.h"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,11 +17,11 @@
#ifndef _CELLULARCONTEXT_H_
#define _CELLULARCONTEXT_H_

#include "NetworkStack.h"
#include "CellularInterface.h"
#include "netsocket/NetworkStack.h"
#include "netsocket/CellularInterface.h"
#include "CellularDevice.h"
#include "CellularUtil.h"
#include "ControlPlane_netif.h"
#include "netsocket/ControlPlane_netif.h"
#include "PinNames.h"

/** @file CellularContext.h
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
#define CELLULAR_INFORMATION_H_

#include <stddef.h>
#include "nsapi_types.h"
#include "netsocket/nsapi_types.h"

const int MAX_IMSI_LENGTH = 15;
const int MAX_ICCID_LENGTH = 20 + 1; // +1 for zero termination
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@

#include "CellularList.h"
#include "Callback.h"
#include "nsapi_types.h"
#include "netsocket/nsapi_types.h"

namespace mbed {

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
#if MBED_CONF_CELLULAR_USE_SMS

#include "Callback.h"
#include "nsapi_types.h"
#include "netsocket/nsapi_types.h"

namespace mbed {

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
#define AT_CELLULAR_STACK_H_

#include "ATHandler.h"
#include "NetworkStack.h"
#include "netsocket/NetworkStack.h"
#include "PlatformMutex.h"
#include "AT_CellularDevice.h"

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
*/

#include "CellularList.h"
#include "ControlPlane_netif.h"
#include "netsocket/ControlPlane_netif.h"
#include "ATHandler.h"
#include "AT_CellularDevice.h"

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
#define CELLULAR_COMMON_

#include <stdint.h>
#include "nsapi_types.h"
#include "netsocket/nsapi_types.h"

const int CELLULAR_RETRY_ARRAY_SIZE = 10;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@

#include <stddef.h>
#include <inttypes.h>
#include "nsapi_types.h"
#include "netsocket/nsapi_types.h"

namespace mbed_cellular_util {

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@ set(unittest-includes ${unittest-includes}
../connectivity/cellular/include/cellular/framework/common
../connectivity/cellular/include/cellular/framework/AT
../connectivity/cellular/include/cellular/framework/device
../features/netsocket/cellular
)

# Source files
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,6 @@ set(unittest-includes ${unittest-includes}
../features/frameworks/mbed-client-randlib/mbed-client-randlib
../drivers
../hal
../features/netsocket/cellular
)

# Source files
Expand Down Expand Up @@ -60,4 +59,3 @@ set(unittest-test-flags
-DMBED_CONF_PLATFORM_DEFAULT_SERIAL_BAUD_RATE=115200
-DMBED_CONF_CELLULAR_USE_SMS=1
)

Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@ set(unittest-includes ${unittest-includes}
../connectivity/cellular/include/cellular/framework/common
../connectivity/cellular/include/cellular/framework/AT
../features/frameworks/mbed-client-randlib/mbed-client-randlib
../features/netsocket/cellular
)

# Source files
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@ set(unittest-includes ${unittest-includes}
../connectivity/cellular/include/cellular/framework/common
../connectivity/cellular/include/cellular/framework/AT
../features/frameworks/mbed-client-randlib/mbed-client-randlib
../features/netsocket/cellular
)

# Source files
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@ set(unittest-includes ${unittest-includes}
../connectivity/cellular/include/cellular/framework/common
../connectivity/cellular/include/cellular/framework/AT
../features/frameworks/mbed-client-randlib/mbed-client-randlib
../features/netsocket/cellular
)

# Source files
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@
#include "FileHandle_stub.h"
#include "CellularLog.h"
#include "ATHandler_stub.h"
#include "SocketAddress.h"
#include "netsocket/SocketAddress.h"
#include "CellularDevice_stub.h"
#include "AT_CellularDevice_stub.h"
#include "myCellularDevice.h"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@ set(unittest-includes ${unittest-includes}
../connectivity/cellular/include/cellular/framework/common
../connectivity/cellular/include/cellular/framework/AT
../features/frameworks/mbed-client-randlib/mbed-client-randlib
../features/netsocket/cellular
)

# Source files
Expand All @@ -20,7 +19,7 @@ set(unittest-sources
../connectivity/libraries/nanostack-libservice/source/libip4string/stoip4.c
../connectivity/libraries/nanostack-libservice/source/libip6string/stoip6.c
../connectivity/libraries/nanostack-libservice/source/libBits/common_functions.c
../features/netsocket/SocketAddress.cpp
../connectivity/netsocket/source/SocketAddress.cpp
)

# Test files
Expand Down Expand Up @@ -51,4 +50,3 @@ set(unittest-test-flags
-DDEVICE_INTERRUPTIN=1
-DMBED_CONF_PLATFORM_DEFAULT_SERIAL_BAUD_RATE=115200
)

Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,6 @@ set(unittest-includes ${unittest-includes}
../connectivity/cellular/include/cellular/framework/device/cellulardevice
../connectivity/cellular/include/cellular/framework/device
../connectivity/cellular/include/cellular/framework/common
../features/netsocket/cellular
)

# Source files
Expand All @@ -19,7 +18,7 @@ set(unittest-sources
../connectivity/libraries/nanostack-libservice/source/libip4string/stoip4.c
../connectivity/libraries/nanostack-libservice/source/libip6string/stoip6.c
../connectivity/libraries/nanostack-libservice/source/libBits/common_functions.c
../features/netsocket/SocketAddress.cpp
../connectivity/netsocket/source/SocketAddress.cpp
)

# Test files
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,6 @@ set(unittest-includes ${unittest-includes}
../connectivity/cellular/include/cellular/framework/device/cellulardevice
../connectivity/cellular/include/cellular/framework/device
../connectivity/cellular/include/cellular/framework/common
../features/netsocket/cellular
)

# Source files
Expand Down Expand Up @@ -49,4 +48,3 @@ set(unittest-test-flags
-DDEVICE_SERIAL=1
-DDEVICE_INTERRUPTIN=1
)

Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,6 @@ set(unittest-includes ${unittest-includes}
../connectivity/cellular/include/cellular/framework/device/cellularstatemachine
../connectivity/cellular/include/cellular/framework/device
../connectivity/cellular/include/cellular/framework/common
../features/netsocket/cellular
)

# Source files
Expand Down
Loading

0 comments on commit 6bd5271

Please sign in to comment.