Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit dc2d47cd authored by Arun Kumar Neelakantam's avatar Arun Kumar Neelakantam
Browse files

net: qrtr: Only update pkts with broadcast node ID



Forwarding of control packets are not reaching the destination because
of replacing all control packets node id with node_id instead of
packet destination node_id.

Replace dst_node_id only when node id is broadcast node ID.

Change-Id: I544f52613fbf8b0973f3188d2acc03f5487d6bac
Signed-off-by: default avatarArun Kumar Neelakantam <aneela@codeaurora.org>
parent 409af4b4
Loading
Loading
Loading
Loading
+3 −5
Original line number Diff line number Diff line
@@ -527,14 +527,12 @@ static int qrtr_node_enqueue(struct qrtr_node *node, struct sk_buff *skb,
	hdr->type = cpu_to_le32(type);
	hdr->src_node_id = cpu_to_le32(from->sq_node);
	hdr->src_port_id = cpu_to_le32(from->sq_port);
	if (to->sq_port == QRTR_PORT_CTRL) {
	if (to->sq_node == QRTR_NODE_BCAST)
		hdr->dst_node_id = cpu_to_le32(node->nid);
		hdr->dst_port_id = cpu_to_le32(QRTR_NODE_BCAST);
	} else {
	else
		hdr->dst_node_id = cpu_to_le32(to->sq_node);
		hdr->dst_port_id = cpu_to_le32(to->sq_port);
	}

	hdr->dst_port_id = cpu_to_le32(to->sq_port);
	hdr->size = cpu_to_le32(len);
	hdr->confirm_rx = !!confirm_rx;