[lkml]   [2012]   [Sep]   [24]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
Messages in this thread
    SubjectRe: sys_kcmp
    Cyrill Gorcunov <> writes:

    > On Mon, Sep 24, 2012 at 10:51:19PM +0400, Cyrill Gorcunov wrote:
    >> > I expect what you want is a call to access_ok, rather than hard coding
    >> > details about task layout here. This test certainly looks wrong
    >> > for a 32bit process on a 64bit kernel. If I read your test right it
    >> > appears I can set values of say 0x100000000 on a 32bit process...
    >> >
    >> > As for mmap_min_addr I would expect your find_vma check would make that
    >> > test unnecessary, simply by not finding a vma...
    >> Good point, Eric, thanks! I'm cooking a new patch now.
    > Btw, Eric, I somehow miss one bit -- how would you set this 0x100000000
    > if TASK_SIZE is a macro which does check for TIF_ADDR32 and sets limit
    > acordingly? What i'm missing?

    How odd. Last time I had looked TASK_SIZE was a simple constant.

    Still I wonder a little if all architectures currently run from 0 to
    TASK_SIZE, for address space available. I seem to remember there have
    been some exceptions to that rule. But I can't recall what they were.


     \ /
      Last update: 2012-09-24 23:21    [W:0.026 / U:1.864 seconds]
    ©2003-2016 Jasper Spaans. hosted at Digital OceanAdvertise on this site