Skip to content

Commit

Permalink
net: openthread: rpc: don't bring interface up in IF_ENABLE command
Browse files Browse the repository at this point in the history
The OpenThread RPC server starts the network interface
automatically on boot because otherwise no frames are
delivered to the OpenThread stack.

Therefore, don't bring the interface up or down when
IF_ENABLE RPC command is received. Instead, assume that
IF_ENABLE command only indicates that the client has
brought its interface up or down, and that it is
interested (or not) in receiving all incoming packets.

Signed-off-by: Damian Krolik <[email protected]>
  • Loading branch information
Damian-Nordic authored and nordicjm committed Nov 7, 2024
1 parent de74230 commit fccaa08
Showing 1 changed file with 0 additions and 6 deletions.
6 changes: 0 additions & 6 deletions subsys/net/openthread/rpc/server/ot_rpc_if.c
Original file line number Diff line number Diff line change
Expand Up @@ -91,12 +91,6 @@ static void ot_rpc_cmd_if_enable(const struct nrf_rpc_group *group, struct nrf_r
goto out;
}

ret = enable ? net_if_up(iface) : net_if_down(iface);
if (ret) {
NET_ERR("Failed to bring interface %s", enable ? "up" : "down");
goto out;
}

if (recv_net_context != NULL) {
net_context_put(recv_net_context);
recv_net_context = NULL;
Expand Down

0 comments on commit fccaa08

Please sign in to comment.