[lkml]   [1999]   [Apr]   [16]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
Messages in this thread
    Subjectmm/page_alloc.c low_on_memory variable.

    Hello mm gurus,

    In page_alloc.c, defined in /include/linux/mm.h, is this wonderful
    global variable that I'd love to see from a driver module. Unfortunately,
    even though it is global, it is somehow invisible. It becomes an undefined
    symbol if I attempt to use it in my module.

    If I am not supposed to use this, how do I prevent a driver from crashing
    the system by eating up all the free pages?

    The driver that I am implementing should not have a fixed amount of pages
    that it can use because it should be able to use more if there is more
    memory available and less if less.

    Presently, if I allocate pages to buffer an incomming data stream, and
    using failure to obtain a free page as a throttle, it is way too late.
    The machine will die a horrible death with out-of-memory errors for
    everything including init. So I have to be able to check something
    before I attempt to allocate another page.

    Dick Johnson
    Penguin : Linux version 2.2.5 on an i686 machine (400.59 BogoMips).
    Warning : It's hard to remain at the trailing edge of technology.

    To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
    the body of a message to
    Please read the FAQ at

     \ /
      Last update: 2005-03-22 13:51    [W:0.019 / U:18.656 seconds]
    ©2003-2017 Jasper Spaans. hosted at Digital OceanAdvertise on this site