Displaying 20 results from an estimated 56 matches for "page_priv".
2006 Mar 14
1
[Xen-ia64-devel] RE: RE: Linux PG_arch_1 conflict
...to Linux.
>
>What do you think of the followings? Too hacky?
>
>
>extern struct address_space xen_ia64_foreign_dummy_mapping;
>#define PageForeign(page) \
> (page->mapping == &xen_ia64_foreign_dummy_mapping)
>
>#define SetPageForeign(page, dtor) do { \
> set_page_private((page), (unsigned long)dtor); \
> (page)->mapping = &xen_ia64_foreign_dummy_mapping; \
>} while (0)
>
>#define ClearPageForeign(page) do { \
> (page)->mapping = NULL; \
> set_page_private((page), 0); \
>} while (0)
>
>#define PageForeignDestructor(page) \
&...
2006 Mar 14
0
RE: [Xen-ia64-devel] RE: RE: Linux PG_arch_1 conflict
...> >
>> >
>> >extern struct address_space xen_ia64_foreign_dummy_mapping;
>> >#define PageForeign(page) \
>> > (page->mapping == &xen_ia64_foreign_dummy_mapping)
>> >
>> >#define SetPageForeign(page, dtor) do { \
>> > set_page_private((page), (unsigned long)dtor); \
>> > (page)->mapping = &xen_ia64_foreign_dummy_mapping; \
>> >} while (0)
>> >
>> >#define ClearPageForeign(page) do { \
>> > (page)->mapping = NULL; \
>> > set_page_private((page), 0); \
>> &...
2019 Sep 11
0
[vhost:linux-next 16/17] include/linux/page_reporting.h:9:34: note: in expansion of macro 'pageblock_order'
...:9:34: note: in expansion of macro 'pageblock_order'
#define PAGE_REPORTING_MIN_ORDER pageblock_order
^~~~~~~~~~~~~~~
include/linux/page_reporting.h:61:44: note: in expansion of macro 'PAGE_REPORTING_MIN_ORDER'
zone->reported_pages[page_private(page) - PAGE_REPORTING_MIN_ORDER]--;
^~~~~~~~~~~~~~~~~~~~~~~~
arch/riscv/include/asm/page.h:24:22: note: each undeclared identifier is reported only once for each function it appears in
#define HPAGE_SHIFT PMD_SHIFT...
2016 Mar 11
0
[PATCH v1 06/19] zsmalloc: clean up many BUG_ON
...{
- BUG_ON(obj_idx);
+ VM_BUG_ON(obj_idx);
return NULL;
}
@@ -839,7 +838,7 @@ static unsigned long obj_to_head(struct size_class *class, struct page *page,
void *obj)
{
if (class->huge) {
- VM_BUG_ON(!is_first_page(page));
+ VM_BUG_ON_PAGE(!is_first_page(page), page);
return page_private(page);
} else
return *(unsigned long *)obj;
@@ -889,8 +888,8 @@ static void free_zspage(struct page *first_page)
{
struct page *nextp, *tmp, *head_extra;
- BUG_ON(!is_first_page(first_page));
- BUG_ON(first_page->inuse);
+ VM_BUG_ON_PAGE(!is_first_page(first_page), first_page);
+ VM...
2016 Mar 17
1
[PATCH v1 11/19] zsmalloc: squeeze freelist into page->mapping
...bj_idx)
{
struct page *cursor = first_page;
unsigned long offset = obj_idx * class->size;
int nr_page = offset >> PAGE_SHIFT;
unsigned long offset_in_page = offset & ~PAGE_MASK;
void *addr;
int i;
if (class->huge) {
VM_BUG_ON_PAGE(!is_first_page(page), page);
return &page_private(page);
}
for (i = 0; i < nr_page; i++)
cursor = get_next_page(cursor);
addr = kmap_atomic(cursor);
return addr + offset_in_page;
}
static void unmap_handle(unsigned long *addr)
{
if (class->huge) {
return;
}
kunmap_atomic(addr & ~PAGE_MASK);
}
all functions called &q...
2016 Mar 17
1
[PATCH v1 11/19] zsmalloc: squeeze freelist into page->mapping
...bj_idx)
{
struct page *cursor = first_page;
unsigned long offset = obj_idx * class->size;
int nr_page = offset >> PAGE_SHIFT;
unsigned long offset_in_page = offset & ~PAGE_MASK;
void *addr;
int i;
if (class->huge) {
VM_BUG_ON_PAGE(!is_first_page(page), page);
return &page_private(page);
}
for (i = 0; i < nr_page; i++)
cursor = get_next_page(cursor);
addr = kmap_atomic(cursor);
return addr + offset_in_page;
}
static void unmap_handle(unsigned long *addr)
{
if (class->huge) {
return;
}
kunmap_atomic(addr & ~PAGE_MASK);
}
all functions called &q...
2012 Mar 29
0
[PATCH v2 2/2] m2p_find_override: use list_for_each_entry_safe
...gned long flags;
struct list_head *bucket = &m2p_overrides[mfn_hash(mfn)];
- struct page *p, *ret;
+ struct page *p, *t, *ret;
ret = NULL;
- spin_lock_irqsave(&m2p_override_lock, flags);
-
- list_for_each_entry(p, bucket, lru) {
+ list_for_each_entry_safe(p, t, bucket, lru) {
if (page_private(p) == mfn) {
ret = p;
break;
}
}
- spin_unlock_irqrestore(&m2p_override_lock, flags);
-
return ret;
}
--
1.7.2.5
2013 Nov 13
0
[PATCH net-next 4/4] virtio-net: auto-tune mergeable rx buffer size for improved performance
...t; since we can do coalescing).
It's hard to predict the future ;)
256 bytes frames consume 2.5 KB anyway on a traditional NIC.
If it was a concern, we would have it already.
If you receive a mix of big and small frames, there is no win.
> > + if (page) {
> > + est_buffer_len = page_private(page);
> > + if (est_buffer_len > len) {
> > + u32 truesize_delta = est_buffer_len - len;
> > +
> > + curr_skb->truesize += truesize_delta;
> > + if (curr_skb != head_skb)
> > + head_skb->truesize += truesize_delta;
> > + }
>
>...
2013 Nov 13
4
[PATCH net-next 4/4] virtio-net: auto-tune mergeable rx buffer size for improved performance
...to estimate the truesize of the last frag.
> + * EWMA with a weight of 64 makes the size adjustments quite small in
> + * the frags allocated on one page (even a order-3 one), and truesize
> + * doesn't need to be 100% accurate.
> + */
> + if (page) {
> + est_buffer_len = page_private(page);
> + if (est_buffer_len > len) {
> + u32 truesize_delta = est_buffer_len - len;
> +
> + curr_skb->truesize += truesize_delta;
> + if (curr_skb != head_skb)
> + head_skb->truesize += truesize_delta;
> + }
Is there a chance that est_buffer_len was sm...
2013 Nov 13
4
[PATCH net-next 4/4] virtio-net: auto-tune mergeable rx buffer size for improved performance
...to estimate the truesize of the last frag.
> + * EWMA with a weight of 64 makes the size adjustments quite small in
> + * the frags allocated on one page (even a order-3 one), and truesize
> + * doesn't need to be 100% accurate.
> + */
> + if (page) {
> + est_buffer_len = page_private(page);
> + if (est_buffer_len > len) {
> + u32 truesize_delta = est_buffer_len - len;
> +
> + curr_skb->truesize += truesize_delta;
> + if (curr_skb != head_skb)
> + head_skb->truesize += truesize_delta;
> + }
Is there a chance that est_buffer_len was sm...
2016 Mar 15
2
[PATCH v1 11/19] zsmalloc: squeeze freelist into page->mapping
On (03/11/16 16:30), Minchan Kim wrote:
> -static void *location_to_obj(struct page *page, unsigned long obj_idx)
> +static void objidx_to_page_and_ofs(struct size_class *class,
> + struct page *first_page,
> + unsigned long obj_idx,
> + struct page **obj_page,
> + unsigned long *ofs_in_page)
this looks big; 5 params, function "returning" both page and
2016 Mar 15
2
[PATCH v1 11/19] zsmalloc: squeeze freelist into page->mapping
On (03/11/16 16:30), Minchan Kim wrote:
> -static void *location_to_obj(struct page *page, unsigned long obj_idx)
> +static void objidx_to_page_and_ofs(struct size_class *class,
> + struct page *first_page,
> + unsigned long obj_idx,
> + struct page **obj_page,
> + unsigned long *ofs_in_page)
this looks big; 5 params, function "returning" both page and
2007 Apr 18
0
[PATCH 1/5] Paravirt page alloc.patch
...addr += PAGE_SIZE) {
set_pte(&pbase[i], pfn_pte(addr >> PAGE_SHIFT,
addr == address ? prot : ref_prot));
@@ -166,6 +167,7 @@ __change_page_attr(struct page *page, pg
if (!PageReserved(kpte_page)) {
if (cpu_has_pse && (page_private(kpte_page) == 0)) {
ClearPagePrivate(kpte_page);
+ paravirt_release_pt(page_to_pfn(kpte_page));
list_add(&kpte_page->lru, &df_list);
revert_page(kpte_page, address);
}
===================================================================
--- a/arch/i386/mm/pgtable.c
+++...
2007 Apr 18
0
[PATCH 1/5] Paravirt page alloc.patch
...addr += PAGE_SIZE) {
set_pte(&pbase[i], pfn_pte(addr >> PAGE_SHIFT,
addr == address ? prot : ref_prot));
@@ -166,6 +167,7 @@ __change_page_attr(struct page *page, pg
if (!PageReserved(kpte_page)) {
if (cpu_has_pse && (page_private(kpte_page) == 0)) {
ClearPagePrivate(kpte_page);
+ paravirt_release_pt(page_to_pfn(kpte_page));
list_add(&kpte_page->lru, &df_list);
revert_page(kpte_page, address);
}
===================================================================
--- a/arch/i386/mm/pgtable.c
+++...
2016 Mar 30
0
[PATCH v3 06/16] zsmalloc: squeeze inuse into page->mapping
...,7 @@ static void free_zspage(struct page *first_page)
struct page *nextp, *tmp, *head_extra;
VM_BUG_ON_PAGE(!is_first_page(first_page), first_page);
- VM_BUG_ON_PAGE(first_page->inuse, first_page);
+ VM_BUG_ON_PAGE(get_zspage_inuse(first_page), first_page);
head_extra = (struct page *)page_private(first_page);
@@ -992,7 +1026,7 @@ static struct page *alloc_zspage(struct size_class *class, gfp_t flags)
SetPagePrivate(page);
set_page_private(page, 0);
first_page = page;
- first_page->inuse = 0;
+ set_zspage_inuse(page, 0);
}
if (i == 1)
set_page_private(first_...
2007 Apr 18
0
[PATCH 1/6] Page allocation hooks for VMI backend
...addr += PAGE_SIZE) {
set_pte(&pbase[i], pfn_pte(addr >> PAGE_SHIFT,
addr == address ? prot : ref_prot));
@@ -166,6 +167,7 @@ __change_page_attr(struct page *page, pg
if (!PageReserved(kpte_page)) {
if (cpu_has_pse && (page_private(kpte_page) == 0)) {
ClearPagePrivate(kpte_page);
+ paravirt_release_pt(page_to_pfn(kpte_page));
list_add(&kpte_page->lru, &df_list);
revert_page(kpte_page, address);
}
===================================================================
--- a/arch/i386/mm/pgtable.c
+++...
2007 Apr 18
0
[PATCH 1/6] Page allocation hooks for VMI backend
...addr += PAGE_SIZE) {
set_pte(&pbase[i], pfn_pte(addr >> PAGE_SHIFT,
addr == address ? prot : ref_prot));
@@ -166,6 +167,7 @@ __change_page_attr(struct page *page, pg
if (!PageReserved(kpte_page)) {
if (cpu_has_pse && (page_private(kpte_page) == 0)) {
ClearPagePrivate(kpte_page);
+ paravirt_release_pt(page_to_pfn(kpte_page));
list_add(&kpte_page->lru, &df_list);
revert_page(kpte_page, address);
}
===================================================================
--- a/arch/i386/mm/pgtable.c
+++...
2013 Dec 17
0
[PATCH net-next 3/3] net: auto-tune mergeable rx buffer size for improved performance
...age to estimate the truesize of the last frag.
+ * EWMA with a weight of 64 makes the size adjustments quite small in
+ * the frags allocated on one page (even a order-3 one), and truesize
+ * doesn't need to be 100% accurate.
+ */
+ if (skb_is_nonlinear(head_skb)) {
+ u32 est_buffer_len = page_private(page);
+ if (est_buffer_len > len) {
+ u32 truesize_delta = est_buffer_len - len;
+
+ curr_skb->truesize += truesize_delta;
+ if (curr_skb != head_skb)
+ head_skb->truesize += truesize_delta;
+ }
+ }
+ ewma_add(&rq->mrg_avg_pkt_len, head_skb->len);
return head_skb...
2020 Mar 12
0
[RFC for Linux] virtio_balloon: Add VIRTIO_BALLOON_F_THP_ORDER to handle THP spilt issue
...on.h
> +++ b/include/linux/balloon_compaction.h
> @@ -100,8 +100,12 @@ static inline void balloon_page_insert(struct balloon_dev_info *balloon,
> struct page *page)
> {
> __SetPageOffline(page);
> - __SetPageMovable(page, balloon->inode->i_mapping);
> - set_page_private(page, (unsigned long)balloon);
> + if (balloon->inode) {
> + __SetPageMovable(page, balloon->inode->i_mapping);
> + set_page_private(page, (unsigned long)balloon);
> + } else {
> + set_page_private(page, 0);
> + }
> list_add(&page->lru, &balloon->...
2013 Nov 12
0
[PATCH net-next 4/4] virtio-net: auto-tune mergeable rx buffer size for improved performance
...from the last frag's page to estimate the truesize of the last frag.
+ * EWMA with a weight of 64 makes the size adjustments quite small in
+ * the frags allocated on one page (even a order-3 one), and truesize
+ * doesn't need to be 100% accurate.
+ */
+ if (page) {
+ est_buffer_len = page_private(page);
+ if (est_buffer_len > len) {
+ u32 truesize_delta = est_buffer_len - len;
+
+ curr_skb->truesize += truesize_delta;
+ if (curr_skb != head_skb)
+ head_skb->truesize += truesize_delta;
+ }
+ }
+ ewma_add(&rq->mrg_avg_pkt_len, head_skb->len);
return 0;
}...