Lines Matching refs:storage
185 } storage; member
227 return bitmap->storage.filemap && in __bitmap_enabled()
430 struct bitmap_storage *store = &bitmap->storage; in __write_sb_page()
431 unsigned long num_pages = bitmap->storage.file_pages; in __write_sb_page()
639 struct bitmap_storage *store = &bitmap->storage; in filemap_write_page()
660 if (bitmap->storage.file) in md_bitmap_wait_writes()
685 if (!bitmap->storage.sb_page) /* no superblock */ in bitmap_update_sb()
687 sb = kmap_local_page(bitmap->storage.sb_page); in bitmap_update_sb()
709 if (bitmap->storage.file) in bitmap_update_sb()
710 write_file_page(bitmap, bitmap->storage.sb_page, 1); in bitmap_update_sb()
712 write_sb_page(bitmap, bitmap->storage.sb_index, in bitmap_update_sb()
713 bitmap->storage.sb_page, 1); in bitmap_update_sb()
720 if (!bitmap || !bitmap->storage.sb_page) in bitmap_print_sb()
722 sb = kmap_local_page(bitmap->storage.sb_page); in bitmap_print_sb()
760 bitmap->storage.sb_page = alloc_page(GFP_KERNEL | __GFP_ZERO); in md_bitmap_new_disk_sb()
761 if (bitmap->storage.sb_page == NULL) in md_bitmap_new_disk_sb()
763 bitmap->storage.sb_index = 0; in md_bitmap_new_disk_sb()
765 sb = kmap_local_page(bitmap->storage.sb_page); in md_bitmap_new_disk_sb()
826 if (!bitmap->storage.file && !bitmap->mddev->bitmap_info.offset) { in md_bitmap_read_sb()
838 bitmap->storage.sb_page = sb_page; in md_bitmap_read_sb()
856 if (bitmap->storage.file) { in md_bitmap_read_sb()
857 loff_t isize = i_size_read(bitmap->storage.file->f_mapping->host); in md_bitmap_read_sb()
860 err = read_file_page(bitmap->storage.file, 0, in md_bitmap_read_sb()
1098 if (bitmap->storage.file) { in md_bitmap_file_kick()
1100 bmname(bitmap), bitmap->storage.file); in md_bitmap_file_kick()
1118 set_bit((pnum<<2) + attr, bitmap->storage.filemap_attr); in set_page_attr()
1124 clear_bit((pnum<<2) + attr, bitmap->storage.filemap_attr); in clear_page_attr()
1130 return test_bit((pnum<<2) + attr, bitmap->storage.filemap_attr); in test_page_attr()
1137 bitmap->storage.filemap_attr); in test_and_clear_page_attr()
1152 struct bitmap_storage *store = &bitmap->storage; in md_bitmap_file_set_bit()
1160 page = filemap_get_page(&bitmap->storage, chunk); in md_bitmap_file_set_bit()
1163 bit = file_page_offset(&bitmap->storage, chunk); in md_bitmap_file_set_bit()
1183 struct bitmap_storage *store = &bitmap->storage; in md_bitmap_file_clear_bit()
1191 page = filemap_get_page(&bitmap->storage, chunk); in md_bitmap_file_clear_bit()
1194 bit = file_page_offset(&bitmap->storage, chunk); in md_bitmap_file_clear_bit()
1215 page = filemap_get_page(&bitmap->storage, chunk); in md_bitmap_file_test_bit()
1218 bit = file_page_offset(&bitmap->storage, chunk); in md_bitmap_file_test_bit()
1242 for (i = 0; i < bitmap->storage.file_pages; i++) { in __bitmap_unplug()
1324 struct bitmap_storage *store = &bitmap->storage; in md_bitmap_init_from_disk()
1406 struct page *page = filemap_get_page(&bitmap->storage, i); in md_bitmap_init_from_disk()
1407 unsigned long bit = file_page_offset(&bitmap->storage, i); in md_bitmap_init_from_disk()
1447 if (!bitmap || !bitmap->storage.filemap) in bitmap_write_all()
1451 if (bitmap->storage.file) in bitmap_write_all()
1454 for (i = 0; i < bitmap->storage.file_pages; i++) in bitmap_write_all()
1538 for (j = 0; j < bitmap->storage.file_pages; j++) in bitmap_daemon_work()
1550 if (bitmap->storage.filemap) { in bitmap_daemon_work()
1551 sb = kmap_local_page(bitmap->storage.sb_page); in bitmap_daemon_work()
1606 j < bitmap->storage.file_pages in bitmap_daemon_work()
1613 if (bitmap->storage.filemap && in bitmap_daemon_work()
2034 md_bitmap_file_unmap(&bitmap->storage); in md_bitmap_free()
2159 bitmap->storage.file = file; in __bitmap_create()
2331 for (i = 0; i < bitmap->storage.file_pages; i++) in bitmap_copy_from_slot()
2353 struct bitmap_storage *storage; in bitmap_get_stats() local
2361 !bitmap->storage.sb_page) in bitmap_get_stats()
2363 sb = kmap_local_page(bitmap->storage.sb_page); in bitmap_get_stats()
2371 storage = &bitmap->storage; in bitmap_get_stats()
2372 stats->file_pages = storage->file_pages; in bitmap_get_stats()
2373 stats->file = storage->file; in bitmap_get_stats()
2404 if (bitmap->storage.file && !init) { in __bitmap_resize()
2464 store.file = bitmap->storage.file; in __bitmap_resize()
2465 bitmap->storage.file = NULL; in __bitmap_resize()
2467 if (store.sb_page && bitmap->storage.sb_page) in __bitmap_resize()
2469 page_address(bitmap->storage.sb_page), in __bitmap_resize()
2472 md_bitmap_file_unmap(&bitmap->storage); in __bitmap_resize()
2473 bitmap->storage = store; in __bitmap_resize()
2574 for (i = 0; i < bitmap->storage.file_pages; i++) in __bitmap_resize()
2728 if (bitmap && sectors < (bitmap->storage.bytes + 511) >> 9) in space_store()