search for: pgoff_t

Displaying 20 results from an estimated 58 matches for "pgoff_t".

Did you mean: off_t
2010 Jul 22
4
[PATCH 1/3] ext3/ext4: Factor out disk addressability check
...um_blocks) +{ + u64 last_fs_block = num_blocks - 1; + + BUG_ON(blocksize_bits < 9); + BUG_ON(blocksize_bits > PAGE_CACHE_SHIFT); + + if (unlikely(num_blocks == 0)) + return 0; + + printk(KERN_INFO "HERE %u %lu %u %u", blocksize_bits, last_fs_block, + sizeof(sector_t), sizeof(pgoff_t)); + + if ((last_fs_block > + (sector_t)(~0ULL) >> (blocksize_bits - 9)) || + (last_fs_block > + (pgoff_t)(~0ULL) >> (PAGE_CACHE_SHIFT - blocksize_bits))) { + return -EFBIG; + } + return 0; +} +EXPORT_SYMBOL(generic_check_addressable); + /* * No-op implementation...
2013 Oct 25
1
[PATCH] Btrfs: stop using vfs_read in send
...,6 +3558,72 @@ out: return ret; } +static ssize_t fill_read_buf(struct send_ctx *sctx, u64 offset, u32 len) +{ + struct btrfs_root *root = sctx->send_root; + struct btrfs_fs_info *fs_info = root->fs_info; + struct inode *inode; + struct page *page; + char *addr; + struct btrfs_key key; + pgoff_t index = offset >> PAGE_CACHE_SHIFT; + pgoff_t last_index; + unsigned pg_offset = offset & (PAGE_CACHE_SIZE - 1); + ssize_t ret = 0; + + key.objectid = sctx->cur_ino; + key.type = BTRFS_INODE_ITEM_KEY; + key.offset = 0; + + inode = btrfs_iget(fs_info->sb, &key, root, NULL); + if...
2024 Jan 22
2
[PATCH] mm: Remove double faults once write a device pfn
...ne or more page table entries pointing to the > * memory backing the buffer object, and then returns a return code > @@ -180,7 +181,8 @@ EXPORT_SYMBOL(ttm_bo_vm_reserve); > */ > vm_fault_t ttm_bo_vm_fault_reserved(struct vm_fault *vmf, > pgprot_t prot, > - pgoff_t num_prefault) > + pgoff_t num_prefault, > + bool mkwrite) > { > struct vm_area_struct *vma = vmf->vma; > struct ttm_buffer_object *bo = vma->vm_private_data; > @@ -263,7 +265,7 @@ vm_fault_t ttm_bo_vm_fault_reserved(struct vm_fault *vmf, > * at...
2024 Jan 24
1
[PATCH] mm: Remove double faults once write a device pfn
...T_SYMBOL(ttm_bo_vm_reserve); >> >>>>> */ >> >>>>> vm_fault_t ttm_bo_vm_fault_reserved(struct vm_fault *vmf, >> >>>>> pgprot_t prot, >> >>>>> - pgoff_t num_prefault) >> >>>>> + pgoff_t num_prefault, >> >>>>> + bool mkwrite) >> >>>>> { >> >>>>> struct vm_area_struct *vma = vmf->vma; >> &g...
2024 Jan 23
2
[PATCH] mm: Remove double faults once write a device pfn
..., and then returns a return code >>> @@ -180,7 +181,8 @@ EXPORT_SYMBOL(ttm_bo_vm_reserve); >>> */ >>> vm_fault_t ttm_bo_vm_fault_reserved(struct vm_fault *vmf, >>> pgprot_t prot, >>> - pgoff_t num_prefault) >>> + pgoff_t num_prefault, >>> + bool mkwrite) >>> { >>> struct vm_area_struct *vma = vmf->vma; >>> struct ttm_buffer_object *bo = vma->vm_private_data; @@ -263...
2024 Jan 24
2
[PATCH] mm: Remove double faults once write a device pfn
...;> code @@ -180,7 +181,8 @@ EXPORT_SYMBOL(ttm_bo_vm_reserve); >>>>> */ >>>>> vm_fault_t ttm_bo_vm_fault_reserved(struct vm_fault *vmf, >>>>> pgprot_t prot, >>>>> - pgoff_t num_prefault) >>>>> + pgoff_t num_prefault, >>>>> + bool mkwrite) >>>>> { >>>>> struct vm_area_struct *vma = vmf->vma; >>>>> struct ttm_buffer_ob...
2011 Mar 31
4
[PATCH] Btrfs: fix free space cache when there are pinned extents and clusters
..._BITMAP (PAGE_CACHE_SIZE * 8) #define MAX_CACHE_BYTES_PER_GIG (32 * 1024) @@ -222,6 +223,7 @@ int load_free_space_cache(struct btrfs_fs_info *fs_info, u64 num_entries; u64 num_bitmaps; u64 generation; + u64 used = btrfs_block_group_used(&block_group->item); u32 cur_crc = ~(u32)0; pgoff_t index = 0; unsigned long first_page_offset; @@ -467,6 +469,17 @@ next: index++; } + spin_lock(&block_group->tree_lock); + if (btrfs_block_group_free_space(block_group) != + (block_group->key.offset - used - block_group->bytes_super)) { + spin_unlock(&block_group->t...
2010 Jul 11
2
[PATCH 1/2] JBD2: Allow feature checks before journal recovery
Before we start accessing a huge (> 16 TiB) OCFS2 volume, we need to confirm that its journal supports 64-bit offsets. So we need to check the journal's feature bits before recovering the journal. This is not possible with JBD2 at present, because the journal superblock (where the feature bits reside) is not loaded from disk until the journal is recovered. This patch loads the journal
2012 Oct 02
3
[Btrfs-next] bulid failure at fs/btrfs/ctree.h
Hello Josef, FYI build failure occured in fs/btrfs/ctree.h. CC fs/btrfs/super.o In file included from fs/btrfs/delayed-inode.h:30:0, from fs/btrfs/super.c:45: fs/btrfs/ctree.h:3235:1: error: expected identifier or ‘(’ before ‘<<’ token make[3]: *** [fs/btrfs/super.o] Error 1 make[2]: *** [fs/btrfs] Error 2 make[1]: *** [fs] Error 2 make[1]: Leaving directory ` make:
2010 Jul 12
1
[PATCH] ocfs2: Don't duplicate page passes i_size during CoW.
...3 100644 --- a/fs/ocfs2/refcounttree.c +++ b/fs/ocfs2/refcounttree.c @@ -2921,7 +2921,7 @@ static int ocfs2_duplicate_clusters_by_page(handle_t *handle, struct super_block *sb = ocfs2_metadata_cache_get_super(ci); u64 new_block = ocfs2_clusters_to_blocks(sb, new_cluster); struct page *page; - pgoff_t page_index; + pgoff_t page_index, last_page; unsigned int from, to; loff_t offset, end, map_end; struct address_space *mapping = context->inode->i_mapping; @@ -2932,12 +2932,20 @@ static int ocfs2_duplicate_clusters_by_page(handle_t *handle, offset = ((loff_t)cpos) << OCFS2_SB(s...
2005 Jan 03
2
(no subject)
...56: error: parse error before '}' token In file included from /home/balducci/tmp/install-us-d/syslinux/linux-2.6.10/include/linux/fs.h:19, from extlinux.c:37: /home/balducci/tmp/install-us-d/syslinux/linux-2.6.10/include/linux/prio_tree.h:22: error: parse error before "pgoff_t" /home/balducci/tmp/install-us-d/syslinux/linux-2.6.10/include/linux/prio_tree.h:27: error: parse error before "pgoff_t" /home/balducci/tmp/install-us-d/syslinux/linux-2.6.10/include/linux/prio_tree.h: In function `prio_tree_iter_init': /home/balducci/tmp/install-us-d/syslinux/li...
2007 Apr 18
2
[patch 4/9] Guest page hinting: volatile swap cache.
...include/linux/pagemap.h --- linux-2.6/include/linux/pagemap.h 2006-09-01 12:50:23.000000000 +0200 +++ linux-2.6-patched/include/linux/pagemap.h 2006-09-01 12:50:23.000000000 +0200 @@ -85,6 +85,13 @@ unsigned find_get_pages_contig(struct ad unsigned find_get_pages_tag(struct address_space *mapping, pgoff_t *index, int tag, unsigned int nr_pages, struct page **pages); +#if defined(CONFIG_PAGE_STATES) +extern struct page * find_get_page_nodiscard(struct address_space *mapping, + unsigned long index); +#else +#define find_get_page_nodiscard(mapping, index) find_get_page(mapping, index) +#...
2007 Apr 18
2
[patch 4/9] Guest page hinting: volatile swap cache.
...include/linux/pagemap.h --- linux-2.6/include/linux/pagemap.h 2006-09-01 12:50:23.000000000 +0200 +++ linux-2.6-patched/include/linux/pagemap.h 2006-09-01 12:50:23.000000000 +0200 @@ -85,6 +85,13 @@ unsigned find_get_pages_contig(struct ad unsigned find_get_pages_tag(struct address_space *mapping, pgoff_t *index, int tag, unsigned int nr_pages, struct page **pages); +#if defined(CONFIG_PAGE_STATES) +extern struct page * find_get_page_nodiscard(struct address_space *mapping, + unsigned long index); +#else +#define find_get_page_nodiscard(mapping, index) find_get_page(mapping, index) +#...
2011 Jan 06
3
Offline Deduplication for Btrfs V2
Just a quick update, I''ve dropped the hashing stuff in favor of doing a memcmp in the kernel to make sure the data is still the same. The thing that takes a while is reading the data up from disk, so doing a memcmp of the entire buffer isn''t that big of a deal, not to mention there''s a possiblity for malicious users if there is a problem with the hashing algorithms we
2020 Nov 06
0
[PATCH v3 3/6] mm: support THP migration to device private memory
...int tail, * pages to show after the currently processed elements - e.g. * migrate_pages */ - lru_add_page_tail(head, page_tail, lruvec, list); + if (remap) + lru_add_page_tail(head, page_tail, lruvec, list); } static void __split_huge_page(struct page *page, struct list_head *list, - pgoff_t end, unsigned long flags) + pgoff_t end, unsigned long flags, bool remap) { struct page *head = compound_head(page); pg_data_t *pgdat = page_pgdat(head); @@ -2447,7 +2470,7 @@ static void __split_huge_page(struct page *page, struct list_head *list, } for (i = nr - 1; i >= 1; i--) { -...
2012 Jan 05
4
[RFC][PATCH 3/3] Btrfs: improve truncation of btrfs
...truct inode *inode = mapping->host; - struct btrfs_root *root = BTRFS_I(inode)->root; struct extent_io_tree *io_tree = &BTRFS_I(inode)->io_tree; struct btrfs_ordered_extent *ordered; struct extent_state *cached_state = NULL; char *kaddr; - u32 blocksize = root->sectorsize; pgoff_t index = from >> PAGE_CACHE_SHIFT; unsigned offset = from & (PAGE_CACHE_SIZE-1); struct page *page; @@ -3261,8 +3268,6 @@ static int btrfs_truncate_page(struct address_space *mapping, loff_t from) u64 page_start; u64 page_end; - if ((offset & (blocksize - 1)) == 0) - goto ou...
2023 Jun 18
11
[PATCH v1 0/5] clean up block_commit_write
*** BLURB HERE *** Bean Huo (5): fs/buffer: clean up block_commit_write fs/buffer.c: convert block_commit_write to return void ext4: No need to check return value of block_commit_write() fs/ocfs2: No need to check return value of block_commit_write() udf: No need to check return value of block_commit_write() fs/buffer.c | 24 +++++++-----------------
2020 Sep 01
0
[PATCH 3/3] drm/ttm: remove io_reserve_lru handling v2
...map->page = NULL; } diff --git a/drivers/gpu/drm/ttm/ttm_bo_vm.c b/drivers/gpu/drm/ttm/ttm_bo_vm.c index 0b805f72d18e..d3dc0682425c 100644 --- a/drivers/gpu/drm/ttm/ttm_bo_vm.c +++ b/drivers/gpu/drm/ttm/ttm_bo_vm.c @@ -281,8 +281,6 @@ vm_fault_t ttm_bo_vm_fault_reserved(struct vm_fault *vmf, pgoff_t i; vm_fault_t ret = VM_FAULT_NOPAGE; unsigned long address = vmf->address; - struct ttm_resource_manager *man = - ttm_manager_type(bdev, bo->mem.mem_type); /* * Refuse to fault imported pages. This should be handled @@ -321,24 +319,17 @@ vm_fault_t ttm_bo_vm_fault_reserved(struct...
2019 Nov 20
2
Move io_reserve_lru handling into the driver
Just a gentle ping on this. Already got the Acked-by from Daniel, but I need some of the nouveau guys to test this since I can only compile test it. Regards, Christian.
2013 Oct 29
0
[PATCH 07/23] block: Convert bio_for_each_segment() to bvec_iter
...te/lloop.c index 5b8c8c2..3488bb6 100644 --- a/drivers/staging/lustre/lustre/llite/lloop.c +++ b/drivers/staging/lustre/lustre/llite/lloop.c @@ -194,10 +194,10 @@ static int do_bio_lustrebacked(struct lloop_device *lo, struct bio *head) struct cl_object *obj = ll_i2info(inode)->lli_clob; pgoff_t offset; int ret; - int i; int rw; obd_count page_count = 0; - struct bio_vec *bvec; + struct bio_vec bvec; + struct bvec_iter iter; struct bio *bio; ssize_t bytes; @@ -221,14 +221,14 @@ static int do_bio_lustrebacked(struct lloop_device *l...