lcnalloc.c (e5451c8f8330e03ad3cfa16048b4daf961af434f) | lcnalloc.c (09cbfeaf1a5a67bfb3201e0c83c810cecb2efa5a) |
---|---|
1/* 2 * lcnalloc.c - Cluster (de)allocation code. Part of the Linux-NTFS project. 3 * 4 * Copyright (c) 2004-2005 Anton Altaparmakov 5 * 6 * This program/include file is free software; you can redistribute it and/or 7 * modify it under the terms of the GNU General Public License as published 8 * by the Free Software Foundation; either version 2 of the License, or --- 269 unchanged lines hidden (view full) --- 278 ntfs_debug("Marking page dirty."); 279 flush_dcache_page(page); 280 set_page_dirty(page); 281 need_writeback = 0; 282 } 283 ntfs_unmap_page(page); 284 } 285 page = ntfs_map_page(mapping, last_read_pos >> | 1/* 2 * lcnalloc.c - Cluster (de)allocation code. Part of the Linux-NTFS project. 3 * 4 * Copyright (c) 2004-2005 Anton Altaparmakov 5 * 6 * This program/include file is free software; you can redistribute it and/or 7 * modify it under the terms of the GNU General Public License as published 8 * by the Free Software Foundation; either version 2 of the License, or --- 269 unchanged lines hidden (view full) --- 278 ntfs_debug("Marking page dirty."); 279 flush_dcache_page(page); 280 set_page_dirty(page); 281 need_writeback = 0; 282 } 283 ntfs_unmap_page(page); 284 } 285 page = ntfs_map_page(mapping, last_read_pos >> |
286 PAGE_CACHE_SHIFT); | 286 PAGE_SHIFT); |
287 if (IS_ERR(page)) { 288 err = PTR_ERR(page); 289 ntfs_error(vol->sb, "Failed to map page."); 290 goto out; 291 } | 287 if (IS_ERR(page)) { 288 err = PTR_ERR(page); 289 ntfs_error(vol->sb, "Failed to map page."); 290 goto out; 291 } |
292 buf_size = last_read_pos & ~PAGE_CACHE_MASK; | 292 buf_size = last_read_pos & ~PAGE_MASK; |
293 buf = page_address(page) + buf_size; | 293 buf = page_address(page) + buf_size; |
294 buf_size = PAGE_CACHE_SIZE - buf_size; | 294 buf_size = PAGE_SIZE - buf_size; |
295 if (unlikely(last_read_pos + buf_size > i_size)) 296 buf_size = i_size - last_read_pos; 297 buf_size <<= 3; 298 lcn = bmp_pos & 7; 299 bmp_pos &= ~(LCN)7; 300 ntfs_debug("Before inner while loop: buf_size %i, lcn 0x%llx, " 301 "bmp_pos 0x%llx, need_writeback %i.", buf_size, 302 (unsigned long long)lcn, --- 712 unchanged lines hidden --- | 295 if (unlikely(last_read_pos + buf_size > i_size)) 296 buf_size = i_size - last_read_pos; 297 buf_size <<= 3; 298 lcn = bmp_pos & 7; 299 bmp_pos &= ~(LCN)7; 300 ntfs_debug("Before inner while loop: buf_size %i, lcn 0x%llx, " 301 "bmp_pos 0x%llx, need_writeback %i.", buf_size, 302 (unsigned long long)lcn, --- 712 unchanged lines hidden --- |