Skip to contentSkip to conversation

af_iucv: wrong mapping of sent and confirmed skbs

PATCH Applied Frank Blaschka 2 participants 2 messages May 13, 2014 – May 14, 2014

Subsystems (4)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 af_iucv: wrong mapping of sent and confirmed skbs

From: Ursula Braun <[email protected]>

When sending data through IUCV a MESSAGE COMPLETE interrupt signals that sent data memory can be freed or reused again. With commit f9c41a62bba3f3f7ef3541b2a025e3371bcbba97 "af_iucv: fix recvmsg by replacing skb_pull() function" the MESSAGE COMPLETE callback iucv_callback_txdone() identifies the wrong skb as being confirmed, which leads to data corruption. This patch fixes the skb mapping logic in iucv_callback_txdone().

---
 net/iucv/af_iucv.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
net/iucv/af_iucv.c +1 -1
@@ -1830,7 +1830,7 @@ static void iucv_callback_txdone(struct
 		spin_lock_irqsave(&list->lock, flags);
 
 		while (list_skb != (struct sk_buff *)list) {
-			if (msg->tag != IUCV_SKB_CB(list_skb)->tag) {
+			if (msg->tag == IUCV_SKB_CB(list_skb)->tag) {
 				this = list_skb;
 				break;
 			}
maintainer Applied
#1 lore raw

From: Frank Blaschka <[email protected]>
Date: Tue, 13 May 2014 14:38:02 +0200

Quoted 10 lines

From: Ursula Braun <[email protected]>

When sending data through IUCV a MESSAGE COMPLETE interrupt signals that sent data memory can be freed or reused again. With commit f9c41a62bba3f3f7ef3541b2a025e3371bcbba97 "af_iucv: fix recvmsg by replacing skb_pull() function" the MESSAGE COMPLETE callback iucv_callback_txdone() identifies the wrong skb as being confirmed, which leads to data corruption. This patch fixes the skb mapping logic in iucv_callback_txdone().

Quoted 2 lines

Applied, thank you.