From e2528368b3303d13b0c83f4c5c57a6fa80b0f772 Mon Sep 17 00:00:00 2001 From: Marcel Telka Date: Thu, 10 Oct 2002 20:49:59 +0000 Subject: [PATCH] Added bits() macro - bits range mask. git-svn-id: https://urjtag.svn.sourceforge.net/svnroot/urjtag/trunk@159 b68d4a1b-bc3d-0410-92ed-d4ac073336b7 --- include/common.h | 1 + 1 file changed, 1 insertion(+) diff --git a/include/common.h b/include/common.h index ed8d335c..fd3b52a0 100644 --- a/include/common.h +++ b/include/common.h @@ -52,5 +52,6 @@ #endif #define bit(x) (1 << x) +#define bits(h,l) (((1 << (h + 1)) - 1) & ~((1 << l) - 1)) #endif /* COMMON_H */