aboutsummaryrefslogtreecommitdiffstats
path: root/lib/test_bitmap.c
diff options
context:
space:
mode:
authorDmitry Torokhov <dmitry.torokhov@gmail.com>2020-07-21 19:02:33 -0700
committerDmitry Torokhov <dmitry.torokhov@gmail.com>2020-07-21 19:02:33 -0700
commit9b031c86506cef9acae45e61339fcf9deaabb793 (patch)
tree9095d638ba9384f86df8d61dcf1f129c082481e1 /lib/test_bitmap.c
parentInput: synaptics-rmi4 - drop a duplicated word (diff)
parentInput: elan_i2c - add support for high resolution reports (diff)
downloadlinux-dev-9b031c86506cef9acae45e61339fcf9deaabb793.tar.xz
linux-dev-9b031c86506cef9acae45e61339fcf9deaabb793.zip
Merge branch 'elan-i2c' into next
Bring in update to Elan touchpad driver to support newer touchpads with higher resolution.
Diffstat (limited to 'lib/test_bitmap.c')
-rw-r--r--lib/test_bitmap.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/lib/test_bitmap.c b/lib/test_bitmap.c
index 61ed71c1daba..6b13150667f5 100644
--- a/lib/test_bitmap.c
+++ b/lib/test_bitmap.c
@@ -278,6 +278,8 @@ static void __init test_replace(void)
unsigned int nlongs = DIV_ROUND_UP(nbits, BITS_PER_LONG);
DECLARE_BITMAP(bmap, 1024);
+ BUILD_BUG_ON(EXP2_IN_BITS < nbits * 2);
+
bitmap_zero(bmap, 1024);
bitmap_replace(bmap, &exp2[0 * nlongs], &exp2[1 * nlongs], exp2_to_exp3_mask, nbits);
expect_eq_bitmap(bmap, exp3_0_1, nbits);