Skip to content

Commit

Permalink
[NET]: ROUND_UP macro cleanup in drivers/net/ppp_generic.c
Browse files Browse the repository at this point in the history
ROUND_UP macro cleanup use DIV_ROUND_UP

Signed-off-by: Milind Arun Choudhary <milindchoudhary@gmail.com>
Acked-by: Paul Mackerras <paulus@samba.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
  • Loading branch information
Milind Arun Choudhary authored and David S. Miller committed Apr 26, 2007
1 parent 36226a8 commit 57cd5f7
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions drivers/net/ppp_generic.c
Original file line number Diff line number Diff line change
Expand Up @@ -88,8 +88,6 @@ struct ppp_file {
#define PF_TO_PPP(pf) PF_TO_X(pf, struct ppp)
#define PF_TO_CHANNEL(pf) PF_TO_X(pf, struct channel)

#define ROUNDUP(n, x) (((n) + (x) - 1) / (x))

/*
* Data structure describing one ppp unit.
* A ppp unit corresponds to a ppp network interface device
Expand Down Expand Up @@ -1297,7 +1295,7 @@ static int ppp_mp_explode(struct ppp *ppp, struct sk_buff *skb)
*/
fragsize = len;
if (nfree > 1)
fragsize = ROUNDUP(fragsize, nfree);
fragsize = DIV_ROUND_UP(fragsize, nfree);
/* nbigger channels get fragsize bytes, the rest get fragsize-1,
except if nbigger==0, then they all get fragsize. */
nbigger = len % nfree;
Expand Down

0 comments on commit 57cd5f7

Please sign in to comment.