1. 03 Jan, 2005 9 commits
    • Andrew Morton's avatar
      [PATCH] vmscan: total_scanned fix · aa0baf35
      Andrew Morton authored
      We haven't been incrementing local variable total_scanned since the
      scan_control stuff went in.  That broke kswapd throttling.
      Signed-off-by: default avatarAndrew Morton <akpm@osdl.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
      aa0baf35
    • Jan Kara's avatar
      [PATCH] Allow disabling quota messages to console · cdd39d34
      Jan Kara authored
      Allow disabling of quota messages to console (they can disturb other
      output).
      Signed-off-by: default avatarJan Kara <jack@suse.cz>
      Signed-off-by: default avatarAndrew Morton <akpm@osdl.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
      cdd39d34
    • Jan Kara's avatar
      [PATCH] Fix of quota deadlock on pagelock: reiserfs · 04a6c897
      Jan Kara authored
      Implement quota journaling and quota reading and writing functions for
      reiserfs.  Solves also several other deadlocks possible for reiserfs due to
      the lock inversion on journal_begin and quota locks.
      
      From: Vladimir Saveliev <vs@namesys.com>
      
      When CONFIG_QUOTA is defined reiserfs's finish_unfinished sets and clears
      MS_ACTIVE bit in s_flags field of super block.  If that bit was set already
      it should not be set.
      Signed-off-by: default avatarJan Kara <jack@suse.cz>
      Signed-off-by: default avatarAndrew Morton <akpm@osdl.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
      04a6c897
    • Jan Kara's avatar
      [PATCH] Fix of quota deadlock on pagelock: ext3 · 98887122
      Jan Kara authored
      Implementation of quota reading and writing functions for ext3.
      Signed-off-by: default avatarJan Kara <jack@suse.cz>
      Signed-off-by: default avatarAndrew Morton <akpm@osdl.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
      98887122
    • Jan Kara's avatar
      [PATCH] Fix of quota deadlock on pagelock: ext2 · 6b394613
      Jan Kara authored
      Implementation of quota reading and writing functions for ext2.
      Signed-off-by: default avatarJan Kara <jack@suse.cz>
      Signed-off-by: default avatarAndrew Morton <akpm@osdl.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
      6b394613
    • Jan Kara's avatar
      [PATCH] quota umount race fix · 84f308c2
      Jan Kara authored
      Fix possible races between umount and quota on/off.
      
      Finally I decided to take a reference to vfsmount during vfs_quota_on() and
      to drop it after the final cleanup in the vfs_quota_off().  This way we
      should be all the time guarded against umount.  This way was protected also
      the old code which used filp_open() for opening quota files.  I was also
      thinking about other ways of protection but there would be always a window
      (provided I don't want to play much with namespace locks) where
      vfs_quota_on() could be called while umount() is in progress resulting in
      the "Busy inodes after unmount" messages...
      
      Get a reference to vfsmount during quotaon() so that we are guarded against
      umount (as was the old code using filp_open()).
      Signed-off-by: default avatarJan Kara <jack@suse.cz>
      Signed-off-by: default avatarAndrew Morton <akpm@osdl.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
      84f308c2
    • Jan Kara's avatar
      [PATCH] Fix of quota deadlock on pagelock: quota core · cf684334
      Jan Kara authored
      The four patches in this series fix deadlocks with quotas of pagelock (the
      problem was lock inversion on PageLock and transaction start - quota code
      needed to first start a transaction and then write the data which subsequently
      needed acquisition of PageLock while the standard ordering - PageLock first
      and transaction start later - was used e.g.  by pdflush).  They implement a
      new way of quota access to disk: Every filesystem that would like to implement
      quotas now has to provide quota_read() and quota_write() functions.  These
      functions must obey quota lock ordering (in particular they should not take
      PageLock inside a transaction).
      
      The first patch implements the changes in the quota core, the other three
      patches implement needed functions in ext2, ext3 and reiserfs.  The patch for
      reiserfs also fixes several other lock inversion problems (similar as ext3
      had) and implements the journaled quota functionality (which comes almost for
      free after the locking fixes...).
      
      The quota core patch makes quota support in other filesystems (except XFS
      which implements everything on its own ;)) unfunctional (quotaon() will refuse
      to turn on quotas on them).  When the patches get reasonable wide testing and
      it will seem that no major changes will be needed I can make fixes also for
      the other filesystems (JFS, UDF, UFS).
      
      This patch:
      
      The patch implements the new way of quota io in the quota core.  Every
      filesystem wanting to support quotas has to provide functions quota_read()
      and quota_write() obeying quota locking rules.  As the writes and reads
      bypass the pagecache there is some ugly stuff ensuring that userspace can
      see all the data after quotaoff() (or Q_SYNC quotactl).  In future I plan
      to make quota files inaccessible from userspace (with the exception of
      quotacheck(8) which will take care about the cache flushing and such stuff
      itself) so that this synchronization stuff can be removed...
      
      The rewrite of the quota core. Quota uses the filesystem read() and write()
      functions no more to avoid possible deadlocks on PageLock. From now on every
      filesystem supporting quotas must provide functions quota_read() and
      quota_write() which obey the quota locking rules (e.g. they cannot acquire the
      PageLock).
      Signed-off-by: default avatarJan Kara <jack@suse.cz>
      Signed-off-by: default avatarAndrew Morton <akpm@osdl.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
      cf684334
    • Jan Kara's avatar
      [PATCH] Fix reiserfs quota debug messages · 6ffc2881
      Jan Kara authored
      Attached patch fixes debug messages of quota code in reiserfs so that they
      compile.  Chris Mason agreed the patch.
      Signed-off-by: default avatarJan Kara <jack@suse.cz>
      Signed-off-by: default avatarAndrew Morton <akpm@osdl.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
      6ffc2881
    • Jan Kara's avatar
      [PATCH] Expose reiserfs_sync_fs() · 3bc5bf4e
      Jan Kara authored
      Attached patch exposes reiserfs_sync_fs().  This call is needed by the new
      quota code to write data to disk on quotaoff so that userspace can see them
      afterwards.  Chris Mason agrees with the patch.
      
      Make reiserfs provide the sync_fs() function so that the quota code
      has a way to reliably force a transaction to disk.
      Signed-off-by: default avatarJan Kara <jack@suse.cz>
      Signed-off-by: default avatarAndrew Morton <akpm@osdl.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
      3bc5bf4e
  2. 02 Jan, 2005 31 commits