patch-2.4.19 linux-2.4.19/drivers/net/hamradio/mkiss.c
Next file: linux-2.4.19/drivers/net/hamradio/mkiss.h
Previous file: linux-2.4.19/drivers/net/hamradio/baycom_ser_fdx.c
Back to the patch index
Back to the overall index
- Lines: 42
- Date:
Fri Aug 2 17:39:44 2002
- Orig file:
linux-2.4.18/drivers/net/hamradio/mkiss.c
- Orig date:
Mon Feb 25 11:37:59 2002
diff -urN linux-2.4.18/drivers/net/hamradio/mkiss.c linux-2.4.19/drivers/net/hamradio/mkiss.c
@@ -347,6 +347,7 @@
skb->protocol = htons(ETH_P_AX25);
netif_rx(skb);
tmp_ax->rx_packets++;
+ tmp_ax->rx_bytes+=count;
}
/* Encapsulate one AX.25 packet and stuff into a TTY queue. */
@@ -386,6 +387,7 @@
ax->tty->flags |= (1 << TTY_DO_WRITE_WAKEUP);
actual = ax->tty->driver.write(ax->tty, 0, ax->xbuff, count);
ax->tx_packets++;
+ ax->tx_bytes+=actual;
ax->dev->trans_start = jiffies;
ax->xleft = count - actual;
ax->xhead = ax->xbuff + actual;
@@ -394,6 +396,7 @@
ax->mkiss->tty->flags |= (1 << TTY_DO_WRITE_WAKEUP);
actual = ax->mkiss->tty->driver.write(ax->mkiss->tty, 0, ax->mkiss->xbuff, count);
ax->tx_packets++;
+ ax->tx_bytes+=actual;
ax->mkiss->dev->trans_start = jiffies;
ax->mkiss->xleft = count - actual;
ax->mkiss->xhead = ax->mkiss->xbuff + actual;
@@ -709,6 +712,8 @@
stats.rx_packets = ax->rx_packets;
stats.tx_packets = ax->tx_packets;
+ stats.rx_bytes = ax->rx_bytes;
+ stats.tx_bytes = ax->tx_bytes;
stats.rx_dropped = ax->rx_dropped;
stats.tx_dropped = ax->tx_dropped;
stats.tx_errors = ax->tx_errors;
@@ -936,7 +941,7 @@
memcpy(dev->dev_addr, ax25_test, AX25_ADDR_LEN);
/* New-style flags. */
- dev->flags = 0;
+ dev->flags = IFF_BROADCAST | IFF_MULTICAST;
return 0;
}
FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen (who was at: slshen@lbl.gov)