search for: page_count

Displaying 20 results from an estimated 114 matches for "page_count".

2008 Jan 02
1
page_count x number_of_copies
Hi all! I have a samba print server which stores information about each job. To accomplish this, I have set 'printing = sysv' so I can use print command. Print command passes to a script some info including '%c' (page_count). The problem is that if someone sends more than one copy of the document, %c doesn't tell me so. It means that %c tells exactly the number of pages sent to the printer without doing the necessary math. How can I know the real amount of pages sent to the printer? Thanks in advance! -- Fabi...
2008 Feb 27
2
page_count x number_of_copies
Hi all! I have a samba print server which stores information about each job. To accomplish this, I have set 'printing = sysv' so I can use print command. Print command passes to a script some info including '%c' (page_count). The problem is that if someone sends more than one copy of the document, %c doesn't tell me so. It means that %c tells exactly the number of pages sent to the printer without doing the necessary math. How can I know the real amount of pages sent to the printer? Thanks in advance! -- Fabi...
2005 Nov 06
2
Bug in use of grant tables in blkback.c error path?
In dispatch_rw_block_io after a call to HYPERVISOR_grant_table_op, there is the following code which calls fast_flush_area and breaks out of the loop early if one of the handles returned from HYPERVISOR_grant_table_op is negative: for (i = 0; i < nseg; i++) { if (unlikely(map[i].handle < 0)) { DPRINTK("invalid buffer -- could not remap it\n"); fast_flush_area(pending_idx,
2017 Sep 23
0
[PATCH] drm/nouveau/bo: remove duplicated variable initialization
The page_count variable in nv04_bo_move_m2mf was redundantly initialized twice with the same value. Signed-off-by: Sergi Granell <xerpi.g.12 at gmail.com> --- drivers/gpu/drm/nouveau/nouveau_bo.c | 1 - 1 file changed, 1 deletion(-) diff --git a/drivers/gpu/drm/nouveau/nouveau_bo.c b/drivers/gpu/drm/nouv...
2008 Jul 07
1
link_to_remote multiple :with =>
...39;')", :loaded => "Element.hide(''a_z_indicator'')", :url => {:action => ''a_z_search'', :ltr => "#{element}"}, :with => "''a_z_language=''+$(''selectbox'').value && ''page_count=''+$(''page_count'').value" %>| Rails 2.0.2, both arguments are individually valid expressions and i can get them to do what i want, but i don''t know how to concatenate them into a single expression Thanks, Richard www.slangasaur.us -- Posted via http://...
2013 Jul 25
0
How to get the PFN of a vmalloc'ed address in a domU ?
..._SIZE)); printk(KERN_INFO "PFN 1 : %lu\n", pfn); // The returned PFN is "0", it''s therefore useless if(pfn_valid(pfn)){ printk(KERN_INFO "PFN 1 est valide\n"); } struct page * shPage = vmalloc_to_page((void *)(x->buffer_addr+recv_offset*PAGE_SIZE)); if(!page_count(shPage)){ printk(KERN_INFO "Error in page_count\n"); // I get a page, but the function page_count fails } I also tried to apply the operation >> PAGE_SHIFT to "manually" get the PFN but the PFN I get is not a valid PFN. Does someone please know how to get the PFN or...
2020 Sep 15
0
[PATCH RFC v1 09/18] x86/hyperv: provide a bunch of helper functions
.../* > + * Deposits exact number of pages > + * Must be called with interrupts enabled > + * Max 256 pages > + */ > +int hv_call_deposit_pages(int node, u64 partition_id, u32 num_pages) > +{ > + struct page **pages; > + int *counts; > + int num_allocations; > + int i, j, page_count; > + int order; > + int desired_order; > + int status; > + int ret; > + u64 base_pfn; > + struct hv_deposit_memory *input_page; > + unsigned long flags; > + > + if (num_pages > HV_DEPOSIT_MAX) > + return -EINVAL; > + if (!num_pages) > + return 0; > + >...
2013 Sep 02
0
[PATCH] drm/nv50-: fix tiled memory layout checks
...page_shift)); - *align = max((1 << nvbo->page_shift), *align); + *align = 1 << nvbo->page_shift; + *size = roundup(*size, *align); } *size = roundup(*size, PAGE_SIZE); @@ -713,6 +713,8 @@ nvc0_bo_move_m2mf(struct nouveau_channel *chan, struct ttm_buffer_object *bo, u32 page_count = new_mem->num_pages; int ret, last_count = 0; + nv_error(chan->drm, "Evicting %#x bytes from %u/%#Lx to %u/%#Lx\n", page_count << PAGE_SHIFT, old_mem->mem_type, src_offset, new_mem->mem_type, dst_offset); + ret = RING_SPACE(chan, (page_count + 2046) / 2047 * 7 + 2...
2007 Dec 03
1
undefined methods page_count
I''m getting "undefined method `page_count'' for #<Array:0xb7073e1c>" when I tried to run my rails application after installing will_paginate. Details are as below: undefined method `page_count'' for #<Array:0xb7073e1c> Extracted source (around line #7): 4: <%= a.text%> 5: <% end %> 6: 7: &l...
2005 Dec 16
13
How to pass a collection to paginate?
There must be a better way to write this code: @project_pages, @projects= paginate :project, :per_page => 10, :conditions => ["account_id = ?", account] ?! If only I could pass the sub-collection account = ... @projects = account.project to paginate, instead of letting it extract it with a find :all + sql conditions Alain. -- Posted via
2020 Mar 02
0
[PATCH v1 06/11] mm: Allow to offline unmovable PageOffline() pages via MEM_GOING_OFFLINE
...+ * PageOffline() pages that are not marked __PageMovable() and + * have a reference count > 0 (after MEM_GOING_OFFLINE) are + * definitely unmovable. If their reference count would be 0, + * they could at least be skipped when offlining memory. + */ + if (PageOffline(page) && page_count(page)) + return -EBUSY; if (!PageHuge(page)) continue; head = compound_head(page); if (page_huge_active(head)) - return pfn; + goto found; skip = compound_nr(head) - (page - head); pfn += skip - 1; } + return -ENOENT; +found: + *movable_pfn = pfn; return 0; } @@ -1...
2020 Mar 11
0
[PATCH v2 05/10] mm: Allow to offline unmovable PageOffline() pages via MEM_GOING_OFFLINE
...+ * PageOffline() pages that are not marked __PageMovable() and + * have a reference count > 0 (after MEM_GOING_OFFLINE) are + * definitely unmovable. If their reference count would be 0, + * they could at least be skipped when offlining memory. + */ + if (PageOffline(page) && page_count(page)) + return -EBUSY; if (!PageHuge(page)) continue; head = compound_head(page); if (page_huge_active(head)) - return pfn; + goto found; skip = compound_nr(head) - (page - head); pfn += skip - 1; } + return -ENOENT; +found: + *movable_pfn = pfn; return 0; } @@ -1...
2020 May 07
0
[PATCH v3 05/15] mm: Allow to offline unmovable PageOffline() pages via MEM_GOING_OFFLINE
...+ * PageOffline() pages that are not marked __PageMovable() and + * have a reference count > 0 (after MEM_GOING_OFFLINE) are + * definitely unmovable. If their reference count would be 0, + * they could at least be skipped when offlining memory. + */ + if (PageOffline(page) && page_count(page)) + return -EBUSY; if (!PageHuge(page)) continue; head = compound_head(page); if (page_huge_active(head)) - return pfn; + goto found; skip = compound_nr(head) - (page - head); pfn += skip - 1; } + return -ENOENT; +found: + *movable_pfn = pfn; return 0; } @@ -1...
2020 Apr 14
1
[PATCH v2 05/10] mm: Allow to offline unmovable PageOffline() pages via MEM_GOING_OFFLINE
...that are not marked __PageMovable() and > + * have a reference count > 0 (after MEM_GOING_OFFLINE) are > + * definitely unmovable. If their reference count would be 0, > + * they could at least be skipped when offlining memory. > + */ > + if (PageOffline(page) && page_count(page)) > + return -EBUSY; > > if (!PageHuge(page)) > continue; > head = compound_head(page); > if (page_huge_active(head)) > - return pfn; > + goto found; > skip = compound_nr(head) - (page - head); > pfn += skip - 1; > } > + return -...
2007 Apr 18
1
[PATCH 1/5] Add pagetable allocation notifiers
...set_pte(&pbase[i], pfn_pte(addr >> PAGE_SHIFT, + set_pte(&pbase[i], pfn_pte(addr >> PAGE_SHIFT, addr == address ? prot : PAGE_KERNEL)); } return base; @@ -146,6 +147,7 @@ __change_page_attr(struct page *page, pg BUG_ON(!page_count(kpte_page)); if (cpu_has_pse && (page_count(kpte_page) == 1)) { + ClearPagePTE(virt_to_page(kpte)); list_add(&kpte_page->lru, &df_list); revert_page(kpte_page, address); } Index: linux-2.6.13/arch/i386/mm/pgtable.c ===============================================...
2007 Apr 18
1
[PATCH 1/5] Add pagetable allocation notifiers
...set_pte(&pbase[i], pfn_pte(addr >> PAGE_SHIFT, + set_pte(&pbase[i], pfn_pte(addr >> PAGE_SHIFT, addr == address ? prot : PAGE_KERNEL)); } return base; @@ -146,6 +147,7 @@ __change_page_attr(struct page *page, pg BUG_ON(!page_count(kpte_page)); if (cpu_has_pse && (page_count(kpte_page) == 1)) { + ClearPagePTE(virt_to_page(kpte)); list_add(&kpte_page->lru, &df_list); revert_page(kpte_page, address); } Index: linux-2.6.13/arch/i386/mm/pgtable.c ===============================================...
2006 Apr 18
1
Pagination links with separator
Hi, I have @result_pages and @results obtained from paginate in an action. I want to show the pages as 1 | 2 | 3 | 4 > The fifth page will show: < 5 | 6 | 7 | 8 > and so on. How exactly do I render the paginator to give this effect? I guess I will have to use pagination_links_each. But being new to Rails, I need help. Thanks, Yash -- Posted via http://www.ruby-forum.com/.
2019 Oct 24
2
[PATCH RFC v3 6/9] mm: Allow to offline PageOffline() pages with a reference count of 0
On Wed 23-10-19 12:03:51, David Hildenbrand wrote: > >Do you see any downsides? > > The only downside I see is that we get more false negatives on > has_unmovable_pages(), eventually resulting in the offlining stage after > isolation to loop forever (as some PageOffline() pages are not movable > (especially, XEN balloon, HyperV balloon), there won't be progress). >
2019 Oct 24
2
[PATCH RFC v3 6/9] mm: Allow to offline PageOffline() pages with a reference count of 0
On Wed 23-10-19 12:03:51, David Hildenbrand wrote: > >Do you see any downsides? > > The only downside I see is that we get more false negatives on > has_unmovable_pages(), eventually resulting in the offlining stage after > isolation to loop forever (as some PageOffline() pages are not movable > (especially, XEN balloon, HyperV balloon), there won't be progress). >
2020 Mar 10
1
[PATCH v1 06/11] mm: Allow to offline unmovable PageOffline() pages via MEM_GOING_OFFLINE
...that are not marked __PageMovable() and > + * have a reference count > 0 (after MEM_GOING_OFFLINE) are > + * definitely unmovable. If their reference count would be 0, > + * they could at least be skipped when offlining memory. > + */ > + if (PageOffline(page) && page_count(page)) > + return -EBUSY; > > if (!PageHuge(page)) > continue; > head = compound_head(page); > if (page_huge_active(head)) > - return pfn; > + goto found; > skip = compound_nr(head) - (page - head); > pfn += skip - 1; > } > + return -...