Skip to content

Commit

Permalink
gnrc_mac: move l2_add to gnrc_netdev2.
Browse files Browse the repository at this point in the history
  • Loading branch information
zhuoshuguo committed Oct 28, 2016
1 parent 450a1c8 commit 36e7a0c
Show file tree
Hide file tree
Showing 3 changed files with 14 additions and 48 deletions.
39 changes: 0 additions & 39 deletions sys/include/net/gnrc/gnrc_mac/gnrc_mac.h

This file was deleted.

8 changes: 0 additions & 8 deletions sys/include/net/gnrc/mac/types.h
Original file line number Diff line number Diff line change
Expand Up @@ -31,19 +31,11 @@
#include <net/gnrc/netdev2.h>
#include <net/gnrc/netif/hdr.h>
#include <net/gnrc.h>
#include <gnrc_mac.h>

#ifdef __cplusplus
extern "C" {
#endif

/******************************************************************************/
typedef struct {
uint8_t addr[GNRC_NETIF_HDR_L2ADDR_MAX_LEN];
uint8_t len;
} l2_addr_t;
#define GNRC_MAC_L2_ADDR_INIT { {0}, 0 }

/******************************************************************************/
typedef enum {
TX_FEEDBACK_UNDEF = 0,
Expand Down
15 changes: 14 additions & 1 deletion sys/include/net/gnrc/netdev2.h
Original file line number Diff line number Diff line change
Expand Up @@ -98,7 +98,20 @@ typedef struct gnrc_netdev2 {
kernel_pid_t pid;

#ifdef MODULE_GNRC_MAC
uint16_t mac_info; /**< general information for the MAC protocol */
/**
* @brief general information for the MAC protocol
*/
uint16_t mac_info;

/**
* @brief device's l2 address
*/
uint8_t l2_addr[GNRC_NETIF_HDR_L2ADDR_MAX_LEN];

/**
* @brief device's l2 address length
*/
uint8_t l2_addr_len;
#endif
} gnrc_netdev2_t;

Expand Down

0 comments on commit 36e7a0c

Please sign in to comment.