URL
https://opencores.org/ocsvn/or1k/or1k/trunk
Subversion Repositories or1k
[/] [or1k/] [trunk/] [linux/] [linux-2.4/] [arch/] [x86_64/] [lib/] [bitstr.c] - Rev 1781
Go to most recent revision | Compare with Previous | Blame | View Log
#include <asm/bitops.h> /* Find string of zero bits in a bitmap */ unsigned long find_next_zero_string(unsigned long *bitmap, long start, long nbits, int len) { unsigned long n, end, i; again: n = find_next_zero_bit(bitmap, nbits, start); if (n == -1) return -1; /* could test bitsliced, but it's hardly worth it */ end = n+len; if (end >= nbits) return -1; for (i = n+1; i < end; i++) { if (test_bit(i, bitmap)) { start = i+1; goto again; } } return n; }
Go to most recent revision | Compare with Previous | Blame | View Log