Skip to content

Commit

Permalink
net: l2: Move the layer 2 code into subsys/net/
Browse files Browse the repository at this point in the history
The subsys/net/ directory is more logical place for L2 code instead
of ip/ directory. No functionality changes by this commit.

Signed-off-by: Jukka Rissanen <jukka.rissanen@linux.intel.com>
  • Loading branch information
jukkar committed Jun 27, 2018
1 parent 099fe7b commit 8ae6bad
Show file tree
Hide file tree
Showing 41 changed files with 14 additions and 13 deletions.
2 changes: 1 addition & 1 deletion drivers/ethernet/CMakeLists.txt
@@ -1,4 +1,4 @@
zephyr_library_include_directories(${ZEPHYR_BASE}/subsys/net/ip/l2)
zephyr_library_include_directories(${ZEPHYR_BASE}/subsys/net/l2)

zephyr_sources_ifdef(CONFIG_ETH_SAM_GMAC
eth_sam_gmac.c
Expand Down
2 changes: 2 additions & 0 deletions subsys/net/CMakeLists.txt
Expand Up @@ -3,6 +3,8 @@ zephyr_library_sources_ifdef(CONFIG_NET_BUF buf.c)
zephyr_library_sources_ifdef(CONFIG_NET_HOSTNAME_ENABLE hostname.c)

if(CONFIG_NETWORKING)
add_subdirectory(l2)

if(CONFIG_NET_RAW_MODE)
zephyr_library_sources(ip/net_pkt.c)
else()
Expand Down
2 changes: 2 additions & 0 deletions subsys/net/Kconfig
Expand Up @@ -93,6 +93,8 @@ if NETWORKING

source "subsys/net/Kconfig.hostname"

source "subsys/net/l2/Kconfig"

source "subsys/net/ip/Kconfig"

source "subsys/net/lib/Kconfig"
Expand Down
2 changes: 0 additions & 2 deletions subsys/net/ip/CMakeLists.txt
Expand Up @@ -28,8 +28,6 @@ zephyr_library_sources_ifdef(CONFIG_NET_TCP connection.c tcp.c)
zephyr_library_sources_ifdef(CONFIG_NET_TRICKLE trickle.c)
zephyr_library_sources_ifdef(CONFIG_NET_UDP connection.c udp.c)

add_subdirectory(l2)

if(CONFIG_NET_SHELL)
zephyr_link_interface_ifdef(CONFIG_MBEDTLS mbedTLS)
zephyr_library_link_libraries_ifdef(CONFIG_MBEDTLS mbedTLS)
Expand Down
2 changes: 0 additions & 2 deletions subsys/net/ip/Kconfig
Expand Up @@ -439,8 +439,6 @@ config NET_PKT_TIMESTAMP_STACK_SIZE

source "subsys/net/ip/Kconfig.stack"

source "subsys/net/ip/l2/Kconfig"

source "subsys/net/ip/Kconfig.mgmt"

source "subsys/net/ip/Kconfig.rpl"
Expand Down
Expand Up @@ -4,7 +4,7 @@ if(CONFIG_NET_L2_BT OR
CONFIG_NET_L2_WIFI_MGMT)

zephyr_library()
zephyr_library_include_directories(. ..)
zephyr_library_include_directories(. ${ZEPHYR_BASE}/subsys/net/ip)
zephyr_library_compile_definitions_ifdef(
CONFIG_NEWLIB_LIBC __LINUX_ERRNO_EXTENSIONS__
)
Expand Down
6 changes: 3 additions & 3 deletions subsys/net/ip/l2/Kconfig → subsys/net/l2/Kconfig
Expand Up @@ -91,11 +91,11 @@ config NET_L2_BT_SHELL
This can be used for testing Bluetooth management commands through the
console via a shell module named "net_bt".

source "subsys/net/ip/l2/ethernet/Kconfig"
source "subsys/net/l2/ethernet/Kconfig"

source "subsys/net/ip/l2/ieee802154/Kconfig"
source "subsys/net/l2/ieee802154/Kconfig"

source "subsys/net/ip/l2/openthread/Kconfig"
source "subsys/net/l2/openthread/Kconfig"

config NET_L2_WIFI_MGMT
bool "Enable WiFi Management support"
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
@@ -1,5 +1,5 @@
zephyr_library()
zephyr_library_include_directories(. ../..)
zephyr_library_include_directories(. ${ZEPHYR_BASE}/subsys/net/ip)
zephyr_library_compile_definitions_ifdef(
CONFIG_NEWLIB_LIBC __LINUX_ERRNO_EXTENSIONS__
)
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
@@ -1,5 +1,5 @@
zephyr_library()
zephyr_library_include_directories(. ../..)
zephyr_library_include_directories(. ${ZEPHYR_BASE}/subsys/net/ip)
zephyr_library_compile_definitions_ifdef(
CONFIG_NEWLIB_LIBC __LINUX_ERRNO_EXTENSIONS__
)
Expand Down
Expand Up @@ -150,6 +150,6 @@ config NET_L2_IEEE802154_SECURITY_CRYPTO_DEV_NAME
IEEE 802.15.4 soft MAC will use to run authentication, encryption and
decryption operations on incoming/outgoing frames.

source "subsys/net/ip/l2/ieee802154/Kconfig.radio"
source "subsys/net/l2/ieee802154/Kconfig.radio"

endif
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
@@ -1,5 +1,6 @@
zephyr_library_named(subsys__net__ip__l2__openthread)
zephyr_library_include_directories(. ../.. ../../../lib/openthread/platform)
zephyr_library_include_directories(. ../../lib/openthread/platform
${ZEPHYR_BASE}/subsys/net/ip)
zephyr_library_compile_definitions_ifdef(
CONFIG_NEWLIB_LIBC __LINUX_ERRNO_EXTENSIONS__
)
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.

0 comments on commit 8ae6bad

Please sign in to comment.