Merge pull request #10781 from miri64/nrfmin/cleanup/long-addr

nrfmin: remove long address support
This commit is contained in:
Cenk Gündoğan 2019-01-17 20:04:03 +01:00 committed by GitHub
commit 1c712c79a4
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 0 additions and 21 deletions

View File

@ -162,16 +162,6 @@ uint16_t nrfmin_get_addr(void);
*/
void nrfmin_set_addr(uint16_t addr);
/**
* @brief Get a pseudo 64-bit long address (needed by IPv6 and 6LoWPAN)
*
* As we do not support 64-bit addresses, we just make one up, for this we
* simply return 4 times concatenated the 16-bit address.
*
* @param[out] addr 64-bit pseudo long address, as array of 4 * 16-bit
*/
void nrfmin_get_pseudo_long_addr(uint16_t *addr);
/**
* @brief Get the IID build from the 16-bit node address
*

View File

@ -188,13 +188,6 @@ uint16_t nrfmin_get_addr(void)
return my_addr;
}
void nrfmin_get_pseudo_long_addr(uint16_t *addr)
{
for (int i = 0; i < 4; i++) {
addr[i] = my_addr;
}
}
void nrfmin_get_iid(uint16_t *iid)
{
iid[0] = 0;
@ -487,10 +480,6 @@ static int nrfmin_get(netdev_t *dev, netopt_t opt, void *val, size_t max_len)
assert(max_len >= sizeof(uint16_t));
*((uint16_t *)val) = NRFMIN_PAYLOAD_MAX;
return sizeof(uint16_t);
case NETOPT_ADDRESS_LONG:
assert(max_len >= sizeof(uint64_t));
nrfmin_get_pseudo_long_addr((uint16_t *)val);
return sizeof(uint64_t);
case NETOPT_ADDR_LEN:
assert(max_len >= sizeof(uint16_t));
*((uint16_t *)val) = 2;