Merge pull request #1494 from simonduq/pr/uip6-debug

Minor debug output fixes
This commit is contained in:
Nicolas Tsiftes 2016-02-04 13:09:21 +01:00
commit 4dce5f6765
2 changed files with 7 additions and 7 deletions

View file

@ -1428,7 +1428,7 @@ uip_process(uint8_t flag)
UIP_STAT(++uip_stat.icmp.drop); UIP_STAT(++uip_stat.icmp.drop);
UIP_STAT(++uip_stat.icmp.chkerr); UIP_STAT(++uip_stat.icmp.chkerr);
UIP_LOG("icmpv6: bad checksum."); UIP_LOG("icmpv6: bad checksum.");
PRINTF("icmpv6: bad checksum."); PRINTF("icmpv6: bad checksum.\n");
goto drop; goto drop;
} }
#endif /*UIP_CONF_IPV6_CHECKS*/ #endif /*UIP_CONF_IPV6_CHECKS*/

View file

@ -1274,10 +1274,10 @@ rpl_process_dio(uip_ipaddr_t *from, rpl_dio_t *dio)
if(dag != NULL && instance != NULL) { if(dag != NULL && instance != NULL) {
if(lollipop_greater_than(dio->version, dag->version)) { if(lollipop_greater_than(dio->version, dag->version)) {
if(dag->rank == ROOT_RANK(instance)) { if(dag->rank == ROOT_RANK(instance)) {
PRINTF("RPL: Root received inconsistent DIO version number\n"); PRINTF("RPL: Root received inconsistent DIO version number (current: %u, received: %u)\n", dag->version, dio->version);
dag->version = dio->version; dag->version = dio->version;
RPL_LOLLIPOP_INCREMENT(dag->version); RPL_LOLLIPOP_INCREMENT(dag->version);
rpl_reset_dio_timer(instance); rpl_reset_dio_timer(instance);
} else { } else {
PRINTF("RPL: Global repair\n"); PRINTF("RPL: Global repair\n");
if(dio->prefix_info.length != 0) { if(dio->prefix_info.length != 0) {
@ -1286,7 +1286,7 @@ rpl_process_dio(uip_ipaddr_t *from, rpl_dio_t *dio)
rpl_set_prefix(dag, &dio->prefix_info.prefix, dio->prefix_info.length); rpl_set_prefix(dag, &dio->prefix_info.prefix, dio->prefix_info.length);
} }
} }
global_repair(from, dag, dio); global_repair(from, dag, dio);
} }
return; return;
} }
@ -1302,7 +1302,7 @@ rpl_process_dio(uip_ipaddr_t *from, rpl_dio_t *dio)
} }
if(instance == NULL) { if(instance == NULL) {
PRINTF("RPL: New instance detected: Joining...\n"); PRINTF("RPL: New instance detected (ID=%u): Joining...\n", dio->instance_id);
rpl_join_instance(from, dio); rpl_join_instance(from, dio);
return; return;
} }