• Andrew Morton's avatar
    [PATCH] random fixes · 5b1b229f
    Andrew Morton authored
    - I changed the sector_t thing in max_block to use davem's approach.
      I agree with Anton, but making it explicit doesn't hurt.
    
    - Remove a dead comment in copy_strings.
    
    Old stuff:
    
    - Remove the IO error warning in end_buffer_io_sync().  Failed READA
      attempts trigger it.
    
    - Emit a warning when an ext2 is mounting an ext3 filesystem.
    
      We have had quite a few problem reports related to this, mainly
      arising from initrd problems.  And mount(8) tends to report the
      fstype from /etc/fstab rather than reporting what has really
      happened.
    
    Fixes some bogosity which I added to max_block():
    
    - `size' doesn't need to be sector_t
    
    - `retval' should not be initialised to "~0UL" because that is
      0x00000000ffffffff with 64-bit sector_t.
    
    - Allocate task_structs with GFP_KERNEL, as discussed.
    
    - Convert the EXPORT_SYMBOL for generic_file_direct_IO() to
      EXPORT_SYMBOL_GPL.  That was only exported as a practicality for the
      raw driver.
    
    - Make the loop thread run balance_dirty_pages() after dirtying the
      backing file.  So it will perform writeback of the backing file when
      dirty memory levels are high.  Export balance_dirty_pages to GPL
      modules for this.
    
      This makes loop work a lot better - I suspect it broke when callers
      of balance_dirty_pages() started writing back only their own queue.
    
      There are many page allocation failures under heavy loop writeout.
      Coming from blk_queue_bounce()'s allocation from the page_pool
      mempool.  So...
    
    - Disable page allocation warnings around the initial atomic
      allocation attempt in mempool_alloc() - the one where __GFP_WAIT and
      __GFP_IO were turned off.  That one can easily fail.
    
    - Add some commentary in block_write_full_page()
    5b1b229f
loop.c 25.6 KB