svn commit: r257894 - projects/altix2/sys/ia64/sgisn
Marcel Moolenaar
marcel at FreeBSD.org
Sat Nov 9 19:52:03 UTC 2013
Author: marcel
Date: Sat Nov 9 19:52:03 2013
New Revision: 257894
URL: http://svnweb.freebsd.org/changeset/base/257894
Log:
Use the right operator to get the bit shift form the entry. We were
mistakenly clearing bit 0 in the corresponding 64-bit integral.
Modified:
projects/altix2/sys/ia64/sgisn/sgisn_pcib.c
Modified: projects/altix2/sys/ia64/sgisn/sgisn_pcib.c
==============================================================================
--- projects/altix2/sys/ia64/sgisn/sgisn_pcib.c Sat Nov 9 19:43:16 2013 (r257893)
+++ projects/altix2/sys/ia64/sgisn/sgisn_pcib.c Sat Nov 9 19:52:03 2013 (r257894)
@@ -781,7 +781,7 @@ sgisn_pcib_iommu_unmap(device_t bus, dev
KASSERT(count <= 64, ("foo: count"));
KASSERT((entry + count) <= PCIB_REG_ATE_SIZE, ("foo"));
- bitshft = entry & 64;
+ bitshft = entry % 64;
KASSERT(bitshft <= (64 - count), ("foo: bitshft"));
bits = (count < 64) ? ((1UL << count) - 1UL) << bitshft : ~0UL;
ate = entry / 64;
More information about the svn-src-projects
mailing list