diff options
| author | Pedro F. Giffuni <pfg@FreeBSD.org> | 2016-04-26 15:03:15 +0000 |
|---|---|---|
| committer | Pedro F. Giffuni <pfg@FreeBSD.org> | 2016-04-26 15:03:15 +0000 |
| commit | 057b4402bf634907fd03590e2757e09e975d04c7 (patch) | |
| tree | df1bb710ebf946f1a7c1b38464ef836fddfee71c /sys/dev/patm | |
| parent | 768f89e0788ab1ab7ea5df9d57082f53567007ec (diff) | |
Notes
Diffstat (limited to 'sys/dev/patm')
| -rw-r--r-- | sys/dev/patm/if_patm_tx.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/sys/dev/patm/if_patm_tx.c b/sys/dev/patm/if_patm_tx.c index d38d07895d0d..1b9a8a50a1db 100644 --- a/sys/dev/patm/if_patm_tx.c +++ b/sys/dev/patm/if_patm_tx.c @@ -119,8 +119,8 @@ cbr2slots(struct patm_softc *sc, struct patm_vcc *vcc) { /* compute the number of slots we need, make sure to get at least * the specified PCR */ - return ((u_int)(((uint64_t)(sc->mmap->tst_size - 1) * - vcc->vcc.tparam.pcr + IFP2IFATM(sc->ifp)->mib.pcr - 1) / IFP2IFATM(sc->ifp)->mib.pcr)); + return ((u_int)howmany((uint64_t)(sc->mmap->tst_size - 1) * + vcc->vcc.tparam.pcr, IFP2IFATM(sc->ifp)->mib.pcr)); } static __inline u_int |
