Commit c69d190f authored by Patrick Menschel's avatar Patrick Menschel Committed by Marc Kleine-Budde

can: isotp: Add error message if txqueuelen is too small

This patch adds an additional error message in case that txqueuelen is
set too small and advices the user to increase txqueuelen.

This is likely to happen even with small transfers if txqueuelen is at
default value 10 frames.

Link: https://lore.kernel.org/r/20210427052150.2308-4-menschel.p@posteo.deSigned-off-by: default avatarPatrick Menschel <menschel.p@posteo.de>
Signed-off-by: default avatarMarc Kleine-Budde <mkl@pengutronix.de>
parent 6a5ddae5
...@@ -797,10 +797,12 @@ static enum hrtimer_restart isotp_tx_timer_handler(struct hrtimer *hrtimer) ...@@ -797,10 +797,12 @@ static enum hrtimer_restart isotp_tx_timer_handler(struct hrtimer *hrtimer)
can_skb_set_owner(skb, sk); can_skb_set_owner(skb, sk);
can_send_ret = can_send(skb, 1); can_send_ret = can_send(skb, 1);
if (can_send_ret) if (can_send_ret) {
pr_notice_once("can-isotp: %s: can_send_ret %pe\n", pr_notice_once("can-isotp: %s: can_send_ret %pe\n",
__func__, ERR_PTR(can_send_ret)); __func__, ERR_PTR(can_send_ret));
if (can_send_ret == -ENOBUFS)
pr_notice_once("can-isotp: tx queue is full, increasing txqueuelen may prevent this error\n");
}
if (so->tx.idx >= so->tx.len) { if (so->tx.idx >= so->tx.len) {
/* we are done */ /* we are done */
so->tx.state = ISOTP_IDLE; so->tx.state = ISOTP_IDLE;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment