net: rpl: Fix compilation if MRHOF is enabled

Make sure the RPL is compiled ok if CONFIG_NET_RPL_MRHOF is
enabled in the configuration.

Change-Id: I51fc0e20f854164c7e0374fa6a1ebf1d4e4dbc5b
Signed-off-by: Jukka Rissanen <jukka.rissanen@linux.intel.com>
This commit is contained in:
Jukka Rissanen 2017-04-11 15:34:47 +03:00
parent 43847e751d
commit d1ac3d6914
1 changed files with 2 additions and 2 deletions

View File

@ -304,7 +304,7 @@ static int net_rpl_mrhof_update_mc(struct net_rpl_instance *instance)
instance->mc.type = NET_RPL_MC_NONE;
return 0;
#else
rpl_path_metric_t path_metric;
uint16_t path_metric;
struct net_rpl_dag *dag;
#if defined(CONFIG_NET_RPL_MC_ENERGY)
@ -321,7 +321,7 @@ static int net_rpl_mrhof_update_mc(struct net_rpl_instance *instance)
dag = instance->current_dag;
if (!dag->joined) {
if (!net_rpl_dag_is_joined(dag)) {
NET_DBG("Cannot update the metric container when not joined.");
return -EINVAL;
}