lkml.org 
[lkml]   [2007]   [Oct]   [30]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    /
    Date
    From
    SubjectRe: vm_ops.page_mkwrite() fails with vmalloc on 2.6.23
    On 10/30/07, Peter Zijlstra <a.p.zijlstra@chello.nl> wrote:
    > So page->index does what you want it to, identify which part of the
    > framebuffer this particular page belongs to.

    Ok. I'm attempting to walk the code sequence. Here's what I think:

    - driver loads
    - driver vmalloc()s its fb
    - this creates the necessary pte entries
    then...
    - app mmap(/dev/fb0)
    - vma is created
    - defio mmap adds this vma to private list (equivalent of
    address_space or anon_vma)
    - app touches base + pixel(128,128) = base + 16k
    - page fault
    - defio nopage gets called
    - defio nopage does vmalloc_to_page(base+16k)
    - that finds the correct struct page corresponding to that vaddr.
    page->index has not been set by anyone so far, right?
    * ah... i see, you are suggesting that this is where I could set the
    index since i know the offset i want it to represent. right?
    - defio mkwrite get called. defio adds page to its list. schedules delayed work
    - app keeps writing the page
    - delayed work occurs
    - foreach vma { foreach page { page_mkclean_one(page, vma) }
    - cycle repeats...

    Thanks,
    jaya
    -
    To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
    the body of a message to majordomo@vger.kernel.org
    More majordomo info at http://vger.kernel.org/majordomo-info.html
    Please read the FAQ at http://www.tux.org/lkml/

    \
     
     \ /
      Last update: 2007-10-30 14:19    [W:7.758 / U:0.024 seconds]
    ©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site