Skip to contentSkip to conversation

comx-proto-lapb: update last_rx after netif_rx

PATCH New Arnaldo Carvalho de Melo 1 participant 1 message Feb 27, 2001 Network drivers

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 comx-proto-lapb: update last_rx after netif_rx

Hi,

Please consider applying.

- Arnaldo

drivers/net/wan/comx-proto-lapb.c +4 -2
@@ -306,11 +306,12 @@
 		p = skb_put(skb,1);
 		*p = 0x01;		// link established
 		skb->dev = ch->dev;
-		skb->protocol = htons(ETH_P_X25);
+		skb->protocol = __constant_htons(ETH_P_X25);
 		skb->mac.raw = skb->data;
 		skb->pkt_type = PACKET_HOST;
 
 		netif_rx(skb);
+		ch->dev->last_rx = jiffies;
 	}
 
 	for (; comxdir; comxdir = comxdir->next) {
@@ -345,11 +346,12 @@
 		p = skb_put(skb,1);
 		*p = 0x02;		// link disconnected
 		skb->dev = ch->dev;
-		skb->protocol = htons(ETH_P_X25);
+		skb->protocol = __constant_htons(ETH_P_X25);
 		skb->mac.raw = skb->data;
 		skb->pkt_type = PACKET_HOST;
 
 		netif_rx(skb);
+		ch->dev->last_rx = jiffies;
 	}
 
 	for (; comxdir; comxdir = comxdir->next) {