Skip to content

Commit

Permalink
sky2: use roundup() macro
Browse files Browse the repository at this point in the history
Use roundup() macro to size receive buffer.

Signed-off-by: Stephen Hemminger <shemminger@linux-foundation.org>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
  • Loading branch information
Stephen Hemminger authored and Jeff Garzik committed Jul 10, 2007
1 parent 7174953 commit f957da2
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions drivers/net/sky2.c
Original file line number Diff line number Diff line change
Expand Up @@ -1180,8 +1180,7 @@ static int sky2_rx_start(struct sky2_port *sky2)
rx_set_checksum(sky2);

/* Space needed for frame data + headers rounded up */
size = ALIGN(sky2->netdev->mtu + ETH_HLEN + VLAN_HLEN, 8)
+ 8;
size = roundup(sky2->netdev->mtu + ETH_HLEN + VLAN_HLEN, 8);

/* Stopping point for hardware truncation */
thresh = (size - 8) / sizeof(u32);
Expand Down

0 comments on commit f957da2

Please sign in to comment.