Remove obsolete support for broadcast DAOs.

This commit is contained in:
nvt 2012-04-17 23:04:20 +02:00
parent ed37e983f6
commit 6071b5aee7

View file

@ -701,26 +701,17 @@ dao_output(rpl_parent_t *n, uint8_t lifetime)
rpl_instance_t *instance;
unsigned char *buffer;
uint8_t prefixlen;
uip_ipaddr_t addr;
uip_ipaddr_t prefix;
int pos;
/* Destination Advertisement Object */
if(get_global_addr(&prefix) == 0) {
PRINTF("RPL: No global address set for this node - suppressing DAO\n");
return;
}
if(n == NULL) {
dag = rpl_get_any_dag();
if(dag == NULL) {
PRINTF("RPL: Did not join a DAG before sending DAO\n");
return;
}
} else {
dag = n->dag;
}
instance = dag->instance;
#ifdef RPL_DEBUG_DAO_OUTPUT
@ -765,23 +756,13 @@ dao_output(rpl_parent_t *n, uint8_t lifetime)
buffer[pos++] = 0; /* path seq - ignored */
buffer[pos++] = lifetime;
if(n == NULL) {
uip_create_linklocal_rplnodes_mcast(&addr);
} else {
uip_ipaddr_copy(&addr, &n->addr);
}
PRINTF("RPL: Sending DAO with prefix ");
PRINT6ADDR(&prefix);
PRINTF(" to ");
if(n != NULL) {
PRINT6ADDR(&n->addr);
} else {
PRINTF("multicast address");
}
PRINTF("\n");
uip_icmp6_send(&addr, ICMP6_RPL, RPL_CODE_DAO, pos);
uip_icmp6_send(&n->addr, ICMP6_RPL, RPL_CODE_DAO, pos);
}
/*---------------------------------------------------------------------------*/
static void