Hello,
On 02/11/2010 10:40 PM, Miklos Szeredi wrote:
quoted text > On Thu, 11 Feb 2010, Tejun Heo wrote:
>>> So there are different offsets:
>>>
>>> a) vma->vm_pgoff (which may mean anything, but usually means b)
>>
>> Yeap, vma->vm_pgoff can be any value and doesn't really matter. The
>> only visible difference would be the /proc listing, right? Setting
>> this to the requested offset is trivial.
>
> You mean leaving it at the requested offset? Yes, that's the most
> trivial thing to do. Very few drivers change vm_pgoff:
>
> git grep "vm_pgoff *=[^=]"
Yeap, sure. I just didn't think it was visible outside.
quoted text >>> b) the offset at which the pages of the mapping are located
>>> c) the offset at which the server side mmap is located
>>
>> There are three offsets.
>>
>> a) the offset a client requested
>>
>> b) the offset into dmmap AS, a client mmap region is mapped to. This
>> could be different from a) by multiple of SHMLBA / PAGE_SIZE.
>
> No, it could be different from a) by an arbitrary value.
Then, sharing those pages would cause aliasing issues.
quoted text >> c) the offset into dmmap AS, a server mmap region is mapped to, where
>> collection of these mmaps define the dmmap AS.
>>
>> The offsets used in b) and c) are the same offsets.
>
> Why are they the same?
I meant they point into the same space. If they're the same value,
they point to the same page.
Thanks.
--
tejun
--
unsubscribe notice 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/
Messages in current thread:
Re: [fuse-devel] [PATCH] FUSE/CUSE: implement direct mmap ... , Tejun Heo , (Thu Feb 11, 6:58 am)