cvs commit: src/sys/vm vm_contig.c vm_page.c

Alan Cox alc at FreeBSD.org
Thu Jan 8 12:48:31 PST 2004


alc         2004/01/08 12:48:26 PST

  FreeBSD src repository

  Modified files:
    sys/vm               vm_contig.c vm_page.c 
  Log:
   - Enable recursive acquisition of the mutex synchronizing access to the
     free pages queue.  This is presently needed by contigmalloc1().
   - Move a sanity check against attempted double allocation of two pages
     to the same vm object offset from vm_page_alloc() to vm_page_insert().
     This provides better protection because double allocation could occur
     through a direct call to vm_page_insert(), such as that by
     vm_page_rename().
   - Modify contigmalloc1() to hold the mutex synchronizing access to the
     free pages queue while it scans vm_page_array in search of free pages.
   - Correct a potential leak of pages by contigmalloc1() that I introduced
     in revision 1.20: We must convert all cache queue pages to free pages
     before we begin removing free pages from the free queue.  Otherwise,
     if we have to restart the scan because we are unable to acquire the
     vm object lock that is necessary to convert a cache queue page to a
     free page, we leak those free pages already removed from the free queue.
  
  Revision  Changes    Path
  1.27      +6 -2      src/sys/vm/vm_contig.c
  1.274     +7 -6      src/sys/vm/vm_page.c


More information about the cvs-all mailing list