diff --git a/include/nuttx/wireless/ieee802154/ieee802154_mac.h b/include/nuttx/wireless/ieee802154/ieee802154_mac.h index 13191bfa405..1299fe98569 100644 --- a/include/nuttx/wireless/ieee802154/ieee802154_mac.h +++ b/include/nuttx/wireless/ieee802154/ieee802154_mac.h @@ -448,7 +448,8 @@ struct ieee802154_data_req_s uint8_t msdu_handle; /* Handle assoc. with MSDU */ - struct { + struct + { uint8_t ack_tx : 1; /* Acknowledge TX? */ uint8_t gts_tx : 1; /* 1=GTS used for TX, 0=CAP used for TX */ uint8_t indirect_tx : 1; /* Should indirect transmission be used? */ @@ -467,7 +468,8 @@ struct ieee802154_data_req_s /* The UWB preamble symbol repititions * Should be one of: - * 0, 16, 64, 1024, 4096 */ + * 0, 16, 64, 1024, 4096 + */ uint16_t uwb_presym_rep; @@ -480,10 +482,12 @@ struct ieee802154_data_req_s /* The MAC service data unit array that is to be transmitted * This must be at the end of the struct to allow the array - * to continue and make the struct "variable length" */ + * to continue and make the struct "variable length" + */ uint8_t msdu[1]; }; + #define SIZEOF_IEEE802154_DATA_REQ_S(n) \ (sizeof(struct ieee802154_data_req_s) + (n)) @@ -501,22 +505,26 @@ struct ieee802154_data_conf_s bool rng_rcvd; /* Ranging indicated by MSDU */ /* A count of the time units corresponding to an RMARKER at the antenna at - * the beginning of the ranging exchange */ + * the beginning of the ranging exchange + */ uint32_t rng_counter_start; /* A count of the time units corresponding to an RMARKER at the antenna at - * end of the ranging exchange */ + * end of the ranging exchange + */ uint32_t rng_counter_stop; /* A count of the time units in a message exchange over which the tracking - * offset was measured */ + * offset was measured + */ uint34_t rng_tracking_interval; /* A count of the time units slipped or advanced by the radio tracking - * system over the course of the entire tracking interval */ + * system over the course of the entire tracking interval + */ uint32_t rng_offset; @@ -645,7 +653,8 @@ struct ieee802154_assoc_rsp_s struct ieee802154_assoc_conf_s { /* Associated device address ALWAYS passed in short address mode. The - * address will be IEEE802154_SADDR_UNSPEC if association was unsuccessful */ + * address will be IEEE802154_SADDR_UNSPEC if association was unsuccessful. + */ struct ieee802154_addr_s dev_addr; @@ -726,6 +735,7 @@ struct ieee802154_beaconnotify_ind_s uint8_t sdu[IEEE802154_MAX_BEACON_PAYLOAD_LENGTH]; }; + #define SIZEOF_IEEE802154_BEACONNOTIFY_IND_S(n) \ (sizeof(struct ieee802154_beaconnotify_ind_s) \ - IEEE802154_MAX_BEACON_PAYLOAD_LENGTH + (n)) diff --git a/wireless/ieee802154/mac802154_device.c b/wireless/ieee802154/mac802154_device.c index d89e9c9b456..d2bc2489801 100644 --- a/wireless/ieee802154/mac802154_device.c +++ b/wireless/ieee802154/mac802154_device.c @@ -433,7 +433,8 @@ static ssize_t mac802154dev_write(FAR struct file *filep, /* The unlinking of the wait struct happens inside the callback. This * is more efficient since it will already have to find the struct in - * the list in order to perform the sem_post. */ + * the list in order to perform the sem_post. + */ return dwait.status; } @@ -491,8 +492,9 @@ void mac802154dev_conf_data(FAR struct ieee802154_mac_s *mac, FAR struct mac802154dev_dwait_s *prev; int ret; - /* Get the dev from the callback context. This should have been set when the - * char driver was registered */ + /* Get the dev from the callback context. This should have been set when + * the char driver was registered. + */ dev = mac->cbs.cb_context; @@ -510,12 +512,8 @@ void mac802154dev_conf_data(FAR struct ieee802154_mac_s *mac, for (prev = NULL, curr = dev->md_dwait; curr && curr->mw_handle != conf->msdu_handle; prev = curr, curr = curr->mw_flink); - - - } - /**************************************************************************** * Public Functions ****************************************************************************/