summaryrefslogtreecommitdiff
path: root/drivers/md/md.h
diff options
context:
space:
mode:
authorNeilBrown <neilb@suse.de>2010-06-01 19:37:33 +1000
committerNeilBrown <neilb@suse.de>2010-07-26 13:21:32 +1000
commitef4256733506f2459a0c436b62267d22a3f0cec6 (patch)
treec73e1849052f56a8f6033498f7fbd65c6259c776 /drivers/md/md.h
parentb63d7c2e29bf9cc94989806f2df0cfca4976b830 (diff)
downloadlinux-3.10-ef4256733506f2459a0c436b62267d22a3f0cec6.tar.gz
linux-3.10-ef4256733506f2459a0c436b62267d22a3f0cec6.tar.bz2
linux-3.10-ef4256733506f2459a0c436b62267d22a3f0cec6.zip
md/bitmap: optimise scanning of empty bitmaps.
A bitmap is stored as one page per 2048 bits. If none of the bits are set, the page is not allocated. When bitmap_get_counter finds that a page isn't allocate, it just reports that one bit work of space isn't flagged, rather than reporting that 2048 bits worth of space are unflagged. This can cause searches for flagged bits (e.g. bitmap_close_sync) to do more work than is really necessary. So change bitmap_get_counter (when creating) to report a number of blocks that more accurately reports the range of the device for which no counter currently exists. Signed-off-by: NeilBrown <neilb@suse.de>
Diffstat (limited to 'drivers/md/md.h')
0 files changed, 0 insertions, 0 deletions