GIT: unionfs2-2.6.27.y: Changes to branch 'master'
Erez Zadok
ezk at fsl.cs.sunysb.edu
Thu Aug 12 23:15:03 EDT 2010
Documentation/accounting/.gitignore | 1 +
Documentation/auxdisplay/.gitignore | 1 +
Documentation/connector/.gitignore | 1 +
Documentation/filesystems/tmpfs.txt | 6 +-
Documentation/ia64/.gitignore | 1 +
Documentation/networking/.gitignore | 1 +
Documentation/pcmcia/.gitignore | 1 +
Documentation/spi/.gitignore | 2 +
Documentation/video4linux/.gitignore | 1 +
Documentation/vm/.gitignore | 1 +
Documentation/watchdog/src/.gitignore | 2 +
Makefile | 2 +-
arch/parisc/math-emu/decode_exc.c | 1 +
arch/powerpc/lib/string.S | 4 +-
arch/powerpc/oprofile/op_model_cell.c | 2 +-
arch/powerpc/platforms/pseries/hotplug-cpu.c | 30 +--
arch/powerpc/platforms/pseries/plpar_wrappers.h | 8 +
arch/powerpc/platforms/pseries/smp.c | 28 ++
arch/x86/boot/compressed/.gitignore | 2 +
arch/x86/ia32/ia32_aout.c | 1 -
arch/x86/kernel/pci-calgary_64.c | 17 +-
arch/x86/kernel/process.c | 6 +-
arch/x86/kvm/vmx.c | 3 +
arch/x86/kvm/x86.c | 21 +-
arch/x86/kvm/x86_emulate.c | 5 +-
drivers/acpi/processor_idle.c | 13 +-
drivers/ata/libata-core.c | 7 +-
drivers/ata/libata-eh.c | 6 +-
drivers/char/agp/amd64-agp.c | 27 +-
drivers/char/ipmi/ipmi_si_intf.c | 11 +-
drivers/char/mem.c | 3 +
drivers/char/tty_io.c | 6 +-
drivers/gpu/drm/r128/r128_cce.c | 18 +-
drivers/gpu/drm/r128/r128_drv.h | 8 +
drivers/gpu/drm/r128/r128_state.c | 36 +-
drivers/hwmon/coretemp.c | 34 ++-
drivers/hwmon/lm78.c | 23 +-
drivers/hwmon/w83781d.c | 26 +-
drivers/i2c/busses/i2c-i801.c | 6 +-
drivers/i2c/busses/i2c-tiny-usb.c | 12 +-
drivers/i2c/i2c-core.c | 29 +-
drivers/infiniband/ulp/ipoib/ipoib_main.c | 4 +-
drivers/md/md.c | 29 ++
drivers/md/raid1.c | 9 +-
drivers/md/raid10.c | 2 +-
drivers/media/video/em28xx/em28xx-dvb.c | 1 +
drivers/misc/enclosure.c | 7 +-
drivers/mtd/ubi/cdev.c | 1 -
drivers/net/arcnet/com20020-pci.c | 4 +-
drivers/net/b44.c | 3 +-
drivers/net/bonding/bond_main.c | 9 +
drivers/net/cpmac.c | 3 +-
drivers/net/r8169.c | 4 +-
drivers/net/sky2.c | 23 +-
drivers/net/wireless/hostap/hostap_cs.c | 10 +
drivers/net/wireless/hostap/hostap_hw.c | 13 +
drivers/net/wireless/hostap/hostap_wlan.h | 2 +-
drivers/parisc/eisa_eeprom.c | 2 +-
drivers/parisc/led.c | 6 +-
drivers/scsi/aacraid/commctrl.c | 4 +-
drivers/scsi/megaraid/megaraid_sas.c | 18 +-
drivers/serial/8250.c | 7 +-
drivers/usb/core/devio.c | 61 +++-
drivers/usb/core/inode.c | 4 +-
drivers/usb/host/ehci-hub.c | 7 +-
drivers/usb/host/ehci-q.c | 11 +-
drivers/usb/host/ehci-sched.c | 1 +
fs/cifs/cifssmb.c | 16 +
fs/cifs/sess.c | 10 +-
fs/ecryptfs/messaging.c | 17 +-
fs/exec.c | 3 +-
fs/ext4/balloc.c | 88 ++++-
fs/ext4/ext4.h | 13 +
fs/ext4/ext4_sb.h | 1 +
fs/ext4/inode.c | 447 ++++++++++++++++++-----
fs/ext4/mballoc.c | 39 ++-
fs/ext4/resize.c | 3 +-
fs/ext4/super.c | 11 +-
fs/fcntl.c | 6 +-
fs/gfs2/dir.c | 2 +-
fs/namei.c | 14 +-
fs/namespace.c | 9 +-
fs/nfs/client.c | 2 +
fs/nfs/dir.c | 2 +
fs/nfsd/nfs4xdr.c | 8 +-
fs/nfsd/nfssvc.c | 2 +-
fs/unionfs/Makefile | 2 +-
fs/xfs/xfs_dfrag.c | 5 +-
include/asm-x86/checksum_32.h | 3 +-
include/asm-x86/kvm_host.h | 1 +
include/asm-x86/kvm_x86_emulate.h | 2 +-
include/linux/fs.h | 2 +
include/linux/percpu_counter.h | 12 +-
include/linux/sched.h | 24 ++-
include/linux/security.h | 10 +
include/linux/topology.h | 4 +-
include/linux/writeback.h | 1 -
include/math-emu/op-common.h | 2 +-
include/net/sctp/structs.h | 1 +
kernel/futex.c | 28 ++-
kernel/printk.c | 2 +-
kernel/sched.c | 12 +-
kernel/sched_fair.c | 13 +-
kernel/sched_features.h | 1 +
kernel/sched_idletask.c | 6 +-
kernel/sched_rt.c | 2 +-
kernel/time/clockevents.c | 16 +-
kernel/time/tick-broadcast.c | 7 +-
kernel/trace/trace.c | 2 +-
lib/percpu_counter.c | 8 +-
mm/filemap.c | 6 +
mm/mempolicy.c | 34 ++-
mm/migrate.c | 3 +
mm/mmap.c | 3 +-
mm/nommu.c | 3 +-
mm/page-writeback.c | 2 -
mm/shmem.c | 8 +-
net/ax25/af_ax25.c | 2 +-
net/ipv4/tcp_minisocks.c | 2 +-
net/ipv6/netfilter/ip6t_REJECT.c | 6 +-
net/ipv6/sit.c | 2 +-
net/sched/sch_api.c | 2 +
net/sctp/sm_make_chunk.c | 62 +++-
net/sunrpc/svc_xprt.c | 25 +-
net/tipc/bearer.c | 37 +--
net/tipc/bearer.h | 2 +-
net/tipc/net.c | 25 +-
net/unix/af_unix.c | 5 +-
scripts/kconfig/Makefile | 2 +-
scripts/mod/modpost.c | 2 +-
security/keys/keyring.c | 18 +-
security/keys/process_keys.c | 6 +-
security/security.c | 9 +
sound/pci/mixart/mixart.c | 24 +-
134 files changed, 1279 insertions(+), 528 deletions(-)
New commits:
commit 2406cf793af20feb5ed776edefef6a38b669837b
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Wed Aug 11 01:57:23 2010 -0400
Unionfs: Release 2.5.5
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 4202c6cbfb514be29d2d2ba4ddff519259ac475c
Merge: 5894b5e0874e35d127991a0f23d6fe32e3076845 b56283505c2b59b4f570d7d91800a35d588500fa
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Thu Aug 12 23:14:10 2010 -0400
Merge branch 'master' of story:/scm/git/unionfs-2.6.27.y
commit 5894b5e0874e35d127991a0f23d6fe32e3076845
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Thu Feb 25 20:37:07 2010 -0500
Unionfs: Release 2.5.4
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 63f4c84ba110603fd90aa33c2e728ab743731bcf
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Thu Feb 25 20:24:20 2010 -0500
Unionfs: update copyright year to 2010
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 1fc24d63450f94708c8d3027bd90c152066df5ea
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Thu Dec 3 19:00:56 2009 -0500
Unionfs: unlock lower parent inode correctly on error path
Bug fix: on some errors, lower directory inode may remain locked and hold a
reference. This was in ->create, ->symlink, and ->mknod.
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit ea5455496c3de4c44cffb25c5edd7bea7b0a8ebc
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Tue Sep 22 17:54:37 2009 -0400
Unionfs: Release 2.5.3
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 82bdc707b3c33ccd0d9fbaac9d121dd399b55421
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Tue Sep 22 17:46:01 2009 -0400
Unionfs: handle an open-unlink-ftruncate sequence
If someone calls open(), then unlink(), then ftruncate() on a file (rare,
but possible), then it's possible for unionfs to get an unlinked inode which
doesn't have an inode->i_sb and its inode->i_ino is zero. Don't oops in
that case.
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit f9d2daab7e9b64792b3f095d52dce5d2833e3a3d
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Tue Sep 22 17:35:15 2009 -0400
Unionfs: fix readonly nfs2/3 permission handling
In unionfs_permission: NFSv2/3 return EACCES on readonly-exported, locally
readonly-mounted file systems, instead of EROFS like other file systems do.
So we have no choice here but to intercept this and ignore it for NFS
branches marked readonly. Specifically, we avoid using NFS's own "broken"
->permission method, and rely on generic_permission() to do basic checking
for us.
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit c2e3588a93e96a6aa09f5e4f824725e9454d3186
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Wed Jun 10 12:27:59 2009 -0400
Unionfs: release 2.5.2
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 310c829ecdb14c07346b588c08d18453e91499e6
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Sun Jan 18 21:22:46 2009 -0500
Unionfs: release 2.5.1
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit b2049464382d89d9868ad8a5d0e2ed7d885b537a
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Sun Jan 18 22:29:10 2009 -0500
Unionfs: update copyrights for 2009
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 33d27dee23c5d6f0deffcc90d3f70ee657b6dfcb
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Sun Jan 18 21:01:41 2009 -0500
Unionfs: create whiteout in correct dir after rename with copyup
Fixes bug #625: a file renamed/moved into a directory, if resulted in a
copyup with a whiteout creation, could cause the whiteout to be created in
the wrong dir.
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 5e1b060ead63240dcd54dbc9966016f00e7fd0c0
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Mon Jan 12 23:10:33 2009 -0500
Unionfs: use path_put in mount code
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 19bcf7498e952fd3fd5c26bedaf04522563539f1
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Fri Nov 7 16:51:13 2008 -0500
Unionfs: handle partial copyup errors gracefully
Don't leave any dentries behind if copying up the inode (or setting its
permission, i.e., using TOMOYO) failed.
CC: Tetsuo Handa <penguin-kernel at i-love.sakura.ne.jp>
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit a561217774d338df03473978b68e2783fc626cc5
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Sat Sep 20 10:54:59 2008 -0400
Unionfs: release 2.5
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit e338a2987a9f2196e0ba0ae3580022ae33078935
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Thu Sep 18 19:55:19 2008 -0400
Unionfs: unionfs_permission locking fixes
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit e50d6ff584af74c4fa610befea509a21f98931f2
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Fri Sep 19 00:44:00 2008 -0400
Unionfs: file/dentry revalidation fixes
Cleanup unnecessary code, merge functions together, and handle situation
where parent dentry may not be valid.
commit 599b20d7e57588b12ec4312224140f932bb5851a
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Wed Sep 17 13:52:17 2008 -0400
Unionfs: remove unused nameidata parameters
In preparation for the VFS removing most/all nameidata from file systems's
view.
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 2a1daabfbf94dd94e031995a7664f82a18faf2f8
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Wed Sep 17 11:41:28 2008 -0400
Unionfs: file_release must always succeed
Why does f_op->release return an int if the VFS ignores it?!
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit b69614bdeb3b468d9f1d2ccf588b140b28a838a2
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Wed Sep 17 03:29:35 2008 -0400
Unionfs: remove redundant file-invariant check in file_revalidate
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 076397b222c0f8bd8325aada247c72dc7733f7ec
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Wed Sep 17 03:27:35 2008 -0400
Unionfs: fix readlink/follow_link to add locking
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit fd26f738d82f5098a064172751678f3ea820b6d4
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Wed Sep 17 03:24:57 2008 -0400
Unionfs: return EINVAL in setattr on error
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit d9622d3e136d07b30f188462b79ebc0a1462ce41
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Wed Sep 17 03:22:21 2008 -0400
Unionfs: just warn in put_super instead of BUG-ing
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 5c6a214931a1ca7d0a77c3404efa1e803bf7ba58
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Thu Sep 18 02:27:44 2008 -0400
patch unionfs-cleanup-mntput-calls.patch
commit 4b131ffbfe67109b27691550fff93d170aaf230e
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Tue Sep 16 00:59:08 2008 -0400
Unionfs: use dget_parent to keep parent dentry stable
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit e68ca3cc6ce3066f592610ba41d3d9128ff33915
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Tue Sep 16 00:01:53 2008 -0400
Unionfs: remove unnecessary calls to copy_attr_times
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit d21a81850bc0ec0cf83436a3180fba5dae23e836
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Fri Sep 12 23:16:26 2008 -0400
Unionfs: fix off-by-one but in mkdir
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 2450e18a2b97d7ba3e9a5bda963e7297fe17a662
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Tue Aug 26 15:07:49 2008 -0400
Unionfs: don't open unhashed files
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit fd026942007dd005cd4b1194af352297d29674d8
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Wed Aug 20 13:04:27 2008 -0400
Unionfs: initialize lower mnt in lookup after vfs_path_lookup
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit f1301e18c4a216269ab36a930bdc880a7e7c0d42
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Wed Sep 10 23:41:18 2008 -0400
Unionfs: drop branchcount on error
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 7911b996cf8031410aa72f34bd38d643565efc4e
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Wed Sep 10 23:41:10 2008 -0400
Unionfs: add a few more invariant debugging checks
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 39eaad98dc631cfbffb6fb1a16d66535d7b05f7a
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Wed Sep 10 23:41:02 2008 -0400
Unionfs: update parent mnt on unlink
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit eeb46041e5cf5e01b82b7c6aa7771de860af3fb1
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Wed Aug 20 15:42:40 2008 -0400
Unionfs: prevent a privilege escalation during first copyup
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 173d9fae59483ae17a539bbeba1283097f56ea22
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Tue Jul 29 21:32:36 2008 -0400
Unionfs: release 2.4
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 4cff2913295c5c7fddb73eeb366fa67332cc9a7a
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Mon Jul 28 00:29:50 2008 -0400
Unionfs: use new kmem_cache_create constructor prototype
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 1af04a6232c0f2f6ed9bb36be1decf30850b3468
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Mon Jul 28 00:28:58 2008 -0400
Unionfs: LOOKUP_ACCESS intent no longer exists
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 9907e03f75351b121d25c75ebeb1215314125d78
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Mon Jul 28 00:36:13 2008 -0400
Unionfs: permission no longer takes a nameidata parameter
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit e5968686e709ecc57cadf4cb8efd22a241c1b70e
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Mon Jul 28 00:04:00 2008 -0400
Unionfs: symlink no longer takes a mode parameter
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit b9e570448bca0ac1b9d0821750974c4803cd0a5e
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Mon Jul 28 00:25:46 2008 -0400
Unionfs: properly hash newly created inodes
This fixes LTP's syscalls/rename13 test.
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit f126314adb9668e53a21f9387964c580615e1b70
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Mon Jul 28 00:25:46 2008 -0400
Unionfs: minor checkpatch fixes
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 6e88eba8773a907240bf2386f58fda56ace576b8
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Mon Jul 28 00:25:46 2008 -0400
Unionfs: update copyrights
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 46af5bea8bb97ea22bc09fe35b88ace3a959595d
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Mon Jul 28 00:25:46 2008 -0400
Unionfs: update maintainers
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 7cc6cb6615550f0ac56a4436e43ba9ab618a85f2
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Mon Jul 28 00:25:46 2008 -0400
Unionfs: remove old lookup code
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 9a40dbcbf67651d2a3bddd3c91597457dbf8c404
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Mon Jul 28 00:25:46 2008 -0400
Unionfs: cache coherency fixes
Handle unhashed or silly-renamed lower dentries properly.
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 36916e8b8370e8a6d11af0eece47d842a9061ad1
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Mon Jul 28 00:25:46 2008 -0400
Unionfs: free lower paths array when destroying dentry's private data
CC: Hugh Dickins <hugh at veritas.com>
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 981d516c45adbd2a86546c3608df64f8779ee953
Author: Hugh Dickins <hugh at veritas.com>
Date: Mon Jul 28 00:25:46 2008 -0400
LTP's iogen01 doio tests used to hang nicely on 32-bit SMP when /tmp was a
unionfs mount of a tmpfs, i_size_read spinning forever, waiting for a lost
seqcount update: fixed by taking i_lock around i_size_write when 32-bit
SMP.
But akpm was dissatisfied with the resulting patch: its lack of
commentary, the #ifs, the nesting around i_size_read, the lack of
attention to i_blocks. I promised to redo it with the general
spin_lock_32bit() he proposed; but disliked the result, partly because
"32bit" obscures the real constraints, which are best commented within
fsstack_copy_inode_size itself.
This version adds those comments, and uses sizeof comparisons which the
compiler can optimize out, instead of CONFIG_SMP, CONFIG_LSF.
BITS_PER_LONG.
Signed-off-by: Hugh Dickins <hugh at veritas.com>
Cc: Erez Zadok <ezk at cs.sunysb.edu>
Cc: Michael Halcrow <mhalcrow at us.ibm.com>
Cc: <hooanon05 at yahoo.co.jp>
Cc: Christoph Hellwig <hch at lst.de>
Signed-off-by: Andrew Morton <akpm at linux-foundation.org>
commit b1af5f849ee6efe82272d6a0b2f6160f7287eaa6
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Mon Jul 28 00:25:46 2008 -0400
Unionfs: lookup overhaul using vfs_path_lookup
Rework the lookup code to use vfs_path_lookup as much as possible, to ensure
that we have a vfsmount at this critical stage. This is necessary for the
upcoming VFS API change from vfs_* to path_* methods. This change also
allows unionfs to cross bind mounts and other mounts on lower branches.
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 40050cceec1c3300364f03cac832988ce85243ab
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Mon Jul 28 00:25:46 2008 -0400
Unionfs: overhaul whiteout code
Move all whiteout functions and helpers into a separate file, replace all
embedded whiteout code with calls to helpers. Cleanup and consolidate the
code. This will make it easier to replace the whiteout code with a
Linux-native whiteout implementation (once available).
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 3329b6fb902d8ea8755472dd5f0ec90ece66e413
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Mon Jul 28 00:25:46 2008 -0400
Unionfs: simplify stale-inode detection code
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit b557022aadeee894ac4769e3d09fc6e329806378
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Mon Jul 28 00:25:46 2008 -0400
Unionfs: create and consolidate helpers to path-put lower objects
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 408b0ec1c2f70a88eae360902b0635c31aed0075
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Mon Jul 28 00:25:46 2008 -0400
Unionfs: create and consolidate helpers to iput lower objects
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit e181f34140fbf9d2abd607facbf8b70a7025e62a
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Mon Jul 28 00:25:46 2008 -0400
Unionfs: move a rename helper closer to rename code
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit e0cb7ba6e76524e9bdcac57ae83ce5762bbcec6b
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Mon Jul 28 00:25:46 2008 -0400
Unionfs: simplify the macros used to get/set the dentry start/end branches
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit b4bf006f9614651cd2ba8efa599534f823485f29
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Mon Jul 28 00:25:46 2008 -0400
Unionfs: move fs/Makefile entry up to minimize merge conflicts
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit ea61a3c20d45779b85b118f234d6c22a78f6bcb4
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Mon Jul 28 00:25:46 2008 -0400
Unionfs: use new umount_begin prototype
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 7e6d14dd1e3fc87243ae762a37d1eddca6f7767d
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Wed Apr 23 19:41:26 2008 -0400
Unionfs: release 2.3.3
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit aaf49dc38bec4d0c967f4aeacd236cac475debbf
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Wed Apr 23 19:05:59 2008 -0400
Unionfs: lock parent dentry branch config in write
Ensure that branch configuration is available to file_revalidate should a
copyup be required.
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 38a4fc70b63115977234a5462c9c3229e891a896
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Wed Apr 23 19:05:50 2008 -0400
Unionfs: set lower file to NULL in file_release
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit f03d82ebcb867bd857818f135b0c72dfeaf20659
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Wed Apr 23 19:05:40 2008 -0400
Unionfs: maintain one-open-file invariant for non-directories
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit dd3dd3bc2838ee95057f0c9d5db60208688cc639
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Wed Apr 23 19:05:22 2008 -0400
Unionfs: reorganize file_revalidate for un/locking callers
Also clean up deep nesting/indentation.
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit b8eec73051e7ee2803372992b8905fe212675083
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Tue Apr 15 13:11:04 2008 -0400
Unionfs: copyup only if file is being written to
Before, we used to copyup on an open(2) call which used flags implying
writing (O_RDWR, O_WRONLY, O_APPEND). This meant that a file being opened
for writing, then immediately closed (without actually writing to the file),
will still have been copied up. Now, we don't copyup such files in ->open,
but defer the copyup till later. [Bug #591].
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 6441b4d9ef60aa627e531dbf638e6ed4847e90ed
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Thu Apr 10 15:32:26 2008 -0400
Unionfs: set append offset correctly for copied-up files
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit f72a33d23b51630c010940337291352a12f7a21e
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Tue Apr 15 13:07:44 2008 -0400
Unionfs: don't dereference dentry without lower branches in d_release
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit a2d50cce6b4bfc0da152a37fa3dfdb107f66ff49
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Sat Apr 5 21:02:23 2008 -0400
Unionfs: stop as soon as first writeable branch is found
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 3361beeb9a76a759bf8f90b90680d090e1665d4d
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Thu Apr 3 13:56:47 2008 -0400
Unionfs: lock inode around calls to notify_change()
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit a3021b1f0ca5d4a3b574de7178ab97d11d8490de
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Thu Apr 3 13:15:59 2008 -0400
Unionfs: copy lower times in fsync/fasync only when needed
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit f79b18fe99eb781c7917a89a45303dd1e4fe42a5
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Tue Apr 15 13:05:52 2008 -0400
Unionfs: prevent races in unionfs_fault
vm_ops->fault may be called in parallel. Because we have to resort to
temporarily changing the vma->vm_file to point to the lower file, a
concurrent invocation of unionfs_fault could see a different value. In this
workaround, we keep a different copy of the vma structure in our stack, so
we never expose a different value of the vma->vm_file called to us, even
temporarily. A better fix (already tested) would be to change the calling
semantics of ->fault to take an explicit file pointer.
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 4047a87fc6df1d03680a22513650d2c7d47d1a5b
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Tue Apr 15 15:20:03 2008 -0400
Unionfs: minor code cleanups
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 5d2228aa830a46221996bf5d0dab285712f60a9f
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Mon Mar 31 22:32:28 2008 -0400
Unionfs: release 2.3.2
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 1f95ef4c942f89d130418792420e0c9db93b0d6a
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Sun Mar 30 17:15:08 2008 -0400
Unionfs: update lower mnts on rmdir with copyup
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit c87d74a5ece5218af39f6dcc5d25c63fa7d0432e
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Sun Mar 30 17:11:47 2008 -0400
Unionfs: don't purge lower sb data on remount
This is no longer needed, as we don't have upper and lower pages. Plus this
was racy, requiring the unexported inode_lock variable.
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 2d7b811410a13d7f07cef73e1cb5a7f6796dd57c
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Wed Mar 26 16:25:34 2008 -0400
Unionfs: release 2.3.1
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 66c6a03063fd8664a0d248be5fb82acab281e910
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Tue Mar 25 17:56:12 2008 -0400
Unionfs: do not over-decrement lower superblock refs on remount
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 410ddb5282f5994838b48bf20a5aaa2d84670c0b
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Mon Mar 24 20:24:52 2008 -0400
Unionfs: release 2.3
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 5610cc5c451b637fb5b52c7d463b27c60dfccfef
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Mon Mar 24 17:29:42 2008 -0400
Unionfs: display mount point name along with generation number
CC: Dave Miller <justdave at mozilla.com>
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit a19978fd5e4a0de11d349e2fb2b2f9f9e0022071
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Sun Mar 23 01:16:33 2008 -0400
Unionfs: document reasons for opaque directories
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 14ac2dbdac471b8a107435b706b83e93aff5e2c8
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Sat Mar 22 22:55:45 2008 -0400
Unionfs: use noinline_for_stack
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit b984f6f34e79320524ad6c4ece62a5d5fa17abf5
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Sat Mar 22 21:47:35 2008 -0400
Unionfs: use __func__ instead of __FUNCTION__
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 9e9808c1ae47a2328a1984e4d25d9882d7557219
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Fri Mar 21 16:02:19 2008 -0400
Unionfs: don't copy parent inode times in setattr
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 7f98a18c8b8524617d504c9235872c6bb345f382
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Sat Mar 22 22:49:29 2008 -0400
Unionfs: reduce number of whiteouts by deleting all instances of files
Optimize the unlinking of non-dir objects in unionfs by deleting all
possible lower inode objects from all writable lower branches. This may
consume a bit more processing, but on average reduces overall inode
consumption and further saves a lot by reducing the total number of
whiteouts needed. We create a whiteout now only if we could not delete all
lower objects, or if one of the lower branches was explicitly marked
read-only.
Signed-off-by: Himanshu Kanda <hkanda at cs.sunysb.edu>
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 503de366f837c0ab8a23d8e3d37f8b11d5966f2c
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Sun Mar 23 02:05:01 2008 -0400
Unionfs: lock our dentry in file operations
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 49aea4df22a8503c36060f8abccf9d37319b1cb0
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Fri Mar 21 23:37:44 2008 -0400
Unionfs: implement vm_operations->fault
As per recommendations made at LSF'08, a stackable file system which does
not change the data across layers, should try to use vm_operations instead
of address_space_operations. This means we now have to implement out own
->read and ->write methods because we cannot rely on VFS helpers which
require us to have a ->readpage method. Either way there are two caveats:
(1) It's not possible currently to set inode->i_mapping->a_ops to NULL,
because too many code paths expect i_mapping to be non-NULL.
(2) a small/dummy ->readpage is still needed because generic_file_mmap,
which we used in unionfs_mmap, still check for the existence of the
->readpage method. These code paths may have to be changed to remove the
need for readpage().
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 4207789a3aff932ed199c83c142122959de72e27
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Fri Mar 21 16:07:59 2008 -0400
Unionfs: implement splice_read/write methods directly
Must implement splice_read/write directly, using VFS helpers, because we can
no longer rely on generic_file_splice_read/write: they need
address_space_operations implemented, which we no longer have.
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 07f4c4b33dd4b73c0d3763ba2e47749af64e7631
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Fri Mar 21 16:04:42 2008 -0400
VFS: rename do_splice_to/from to vfs_splice_* and export symbols
A stackable file system which uses vm_ops->fault, and does not implement
address_space_operations, cannot use generic_file_splice_read/write, but has
to implement ->splice_read/write itself. These two helper functions are
very useful to such a module.
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit f6e2c15cc1bf00b90ddc2507a3f67c2962f784a1
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Mon Mar 24 20:44:54 2008 -0400
VFS: export release_open_intent as GPL symbol, not regular symbol
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit a51737c372f48cd60501636d758b63b7d0c638d4
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Fri Feb 15 23:08:04 2008 -0500
Unionfs: release 2.2.4
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 13bcb712f6e74a974e3c39351011267c06cd9038
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Fri Feb 15 18:42:43 2008 -0500
VFS/Unionfs: use generic path_get/path_put functions
Remove unionfs's versions thereof.
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit d4713a828b3dc1b6b35142cfa167264e5c173f88
Author: Jan Blunck <jblunck at suse.de>
Date: Fri Feb 15 18:47:28 2008 -0500
Unionfs: use the new path_put
* Add path_put() functions for releasing a reference to the dentry and
vfsmount of a struct path in the right order
* Switch from path_release(nd) to path_put(&nd->path)
* Rename dput_path() to path_put_conditional()
Signed-off-by: Jan Blunck <jblunck at suse.de>
Signed-off-by: Andreas Gruenbacher <agruen at suse.de>
Acked-by: Christoph Hellwig <hch at lst.de>
Signed-off-by: Andrew Morton <akpm at linux-foundation.org>
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 8175095cb72129e88d7e147bd08bc8e3e9698b7e
Author: Andrew Morton <akpm at linux-foundation.org>
Date: Fri Feb 15 18:45:45 2008 -0500
Unionfs: embed a struct path into struct nameidata instead of nd dentrymnt
Signed-off-by: Andrew Morton <akpm at linux-foundation.org>
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit aa0411a890bb70c37a4af2dcc83c802a39c7051b
Author: David Howells <dhowells at redhat.com>
Date: Fri Feb 15 17:18:48 2008 -0500
Unionfs: stop using iget() and read_inode()
Replace unionfs_read_inode() with unionfs_iget(), and call that instead of
iget(). unionfs_iget() then uses iget_locked() directly and returns a
proper error code instead of an inode in the event of an error.
unionfs_fill_super() returns any error incurred when getting the root inode
instead of EINVAL.
Signed-off-by: David Howells <dhowells at redhat.com>
Signed-off-by: Andrew Morton <akpm at linux-foundation.org>
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 69601267b45a617bfb74fdc1e129d7f9d4f31aab
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Fri Feb 15 17:18:48 2008 -0500
Unionfs: use dget_parent in revalidation code
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 5b39f91ba80fb7f82f0b1711291fe9ce246587c5
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Fri Feb 15 17:18:48 2008 -0500
Unionfs: branch management/configuration fixes
Remove unnecessary calls to update branch m/ctimes, and use them only when
needed. Update branch vfsmounts after operations that could cause a copyup.
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit e33b86230e505f7f2a41ab47d0008d419f12a8fa
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Fri Feb 15 17:18:48 2008 -0500
Unionfs: lock parents' branch configuration fixes
Ensure that we lock the branch configuration of parent and child dentries in
operations which need it, and in the right order.
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 7db5e4b6633c47cfc17ceb285b2ded145862905b
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Fri Feb 15 17:18:48 2008 -0500
Unionfs: factor out revalidation routine
To be used by rest of revalidation code, as well a callers who already
locked the child and parent dentry branch-configurations.
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit dd67dcc23eb3a5f81cca4105e9f2160652be2979
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Fri Feb 15 17:18:48 2008 -0500
Unionfs: revalidation code cleanup and refactoring
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 92c37eb5c61ee45832e27c562ec3251dc0153b2a
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Fri Feb 15 17:18:48 2008 -0500
Unionfs: improve debugging in copy_attr_times
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 11fa87924aef957c8203f1f6c7f4e937c7633102
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Fri Feb 15 17:18:48 2008 -0500
Unionfs: follow_link locking fixes
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 75a6067585d1f103da300a9da31da112535a0aba
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Fri Feb 15 17:18:48 2008 -0500
Unionfs: extend dentry branch configuration lock in open
Dentry branch configuration "info node" lock should extend to calls to
copy_attr_times.
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 172d481a16df5106d033edf96745694359b502c6
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Fri Feb 15 17:18:48 2008 -0500
Unionfs: initialize path_save variable
This is not strictly necessary, but it helps quiet a gcc-4.2 warning (a good
optimizer may optimize this initialization away).
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
Signed-off-by: Josef 'Jeff' Sipek <jsipek at cs.sunysb.edu>
commit 9de5ee6bac7ab299c7708c1ce48a0af4ceed8e51
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Fri Feb 15 17:18:48 2008 -0500
Unionfs: uninline unionfs_copy_attr_times and unionfs_copy_attr_all
This reduces text size by about 6k.
Cc: Hugh Dickins <hugh at veritas.com>
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 91b95098ff15485781152684b6ba2a58658d3c24
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Fri Feb 15 17:18:48 2008 -0500
Unionfs: document behavior when the lower topology changes
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 442c1297715b26a1cce1544df230d54237123285
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Fri Feb 15 17:18:48 2008 -0500
Unionfs: ensure consistent lower inodes types
When looking up a lower object in multiple branches, especially for
directories, ignore any existing entries whose type is different than the
type of the first found object (otherwise we'll be trying to, say, call
readdir on a non-dir inode).
Signed-off-by: Himanshu Kanda <hkanda at fsl.cs.sunysb.edu>
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit f46979706727810a818ec794d242e48a445b1dc8
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Fri Feb 15 17:18:48 2008 -0500
Unionfs: grab lower super_block references
This prevents the lower super_block from being destroyed too early, when a
lower file system is being unmounted with MNT_FORCE or MNT_DETACH.
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 48487fad8ade2ad26bc35a8d7fbd7c02927ef68f
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Fri Jan 25 22:43:03 2008 -0500
Unionfs: release 2.2.3
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit d7a56d2936a3c763f4adb714d2e659e75b534ee2
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Fri Jan 25 17:04:21 2008 -0500
Unionfs: lock_rename related locking fixes
CC: Mike Halcrow <mhalcrow at us.ibm.com>
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 24d458a78522620cb986c03e11eeab971c089628
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Fri Jan 25 16:04:18 2008 -0500
Unionfs: d_parent related locking fixes
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit dde2ed4e51e97e43533fe4c31c7eee5f8bd9fc18
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Thu Jan 24 21:57:06 2008 -0500
Unionfs: remove unnecessary call to d_iput
This old code was to fix a bug which has long since been fixed in our
copyup_permission and unionfs_d_iput.
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit df383dc19b6b447ef1e44c0344a816949e7f38a3
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Tue Jan 22 05:04:18 2008 -0500
Unionfs: use first writable branch (fix/cleanup)
Cleanup code in ->create, ->symlink, and ->mknod: refactor common code into
helper functions. Also, this allows writing to multiple branches again,
which was broken by an earlier patch.
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit d18c524118ab308fca43bc8394896bb175dc4715
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Wed Jan 9 20:38:17 2008 -0500
Unionfs: release 2.2.2
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 057f47188375c5918342622fe6cd168ae94cf73b
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Wed Jan 9 19:07:29 2008 -0500
Unionfs: ensure we have lower dentries in d_iput
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit ec79038e747b6c963ee2dece64c87eb40fc5229c
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Wed Jan 9 15:26:56 2008 -0500
Unionfs: branch-management related locking fixes
Add necessary locking to dentry/inode branch-configuration, so we get
consistent values during branch-management actions. In d_revalidate_chain,
->permission, and ->create, also lock parent dentry.
commit 315ae1ac65803af9420d8348932ad84e3c419520
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Wed Jan 9 15:26:56 2008 -0500
Unionfs: mmap fixes
Ensure we have lower inodes in prepare/commit_write.
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit f850fbbf935c4dfaa41ecda44ad1630383aba077
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Wed Jan 9 15:26:56 2008 -0500
Unionfs: merged several printk KERN_CONT together into one pr_debug
CC: Joe Perches <joe at perches.com>
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 343286c4d89264f931aba1f54b331ec92e360cb9
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Wed Jan 2 21:57:29 2008 -0500
Unionfs: release 2.2.1
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit fe0dd3abe8fad00a75e3a4ab9a33aa3c6130bac2
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Tue Jan 1 16:43:39 2008 -0500
Unionfs: use VFS helpers to manipulate i_nlink
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 3a7606892eae7b4d5f6a97b91711a76ad33e204a
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Tue Jan 1 21:37:39 2008 -0500
Unionfs: locking fixes
Lock parent dentries during revalidation.
Reduce total number of lockdep classes used.
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit a41cc470d0faeaf5a0a35909e1d3118f276d9210
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Tue Jan 1 16:27:46 2008 -0500
Unionfs: use printk KERN_CONT for debugging messages
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 1eb9113ab0191efb9e4f856164eb5998ae47a0dc
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Fri Dec 28 13:31:53 2007 -0500
Unionfs: release 2.2
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit b19f8f193eade9f799e3b3a04212a7e4949ce623
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Fri Dec 28 10:53:44 2007 -0500
Unionfs: don't check parent dentries
Parent dentries may not be locked and may change, so don't check them. But
do check parent inodes if they are passed to the method. Also, ensure the
checks are done only if no error occurred.
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 08100c7fa9062b822f6381acd9ce50cec9a755b0
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Thu Dec 27 19:05:05 2007 -0500
Unionfs: implement d_iput method
This is needed to drop lower objects early enough, under certain conditions,
so the lower objects don't stay behind until umount(). [LTP testing]
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 10e1a498bb8a0f21e4eb053a6e9b0989f643da85
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Thu Dec 27 19:19:46 2007 -0500
Unionfs: don't check dentry on error
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 7b127c3804743cfb034659cca1b278a33eafd85f
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Thu Dec 27 19:04:09 2007 -0500
Unionfs: cleanup lower inodes after successful unlink
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit ea835847e01c3a3518c8effdb544cdc1aecd7ffd
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Sun Dec 23 16:36:29 2007 -0500
Unionfs: initialize namelist variable in rename
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit c93e96f64397fe0215a39eb1d4e744236836b0ea
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Sun Dec 23 16:30:19 2007 -0500
Unionfs: minor cleanup in check_empty
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 7e2c9a370182c6670e8a4774d2ea159a642896ab
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Sat Dec 22 20:45:47 2007 -0500
Unionfs: update inode times after a successful open
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit edd232ce9f9c3e2b662c514c03574debb21d43c1
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Sat Dec 22 19:43:03 2007 -0500
Unionfs: set our superblock a/m/ctime granularity
Set it to 1 ns, because we could be stacked on top of file systems with such
granularity.
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 0f0b2a3cdd098a58c7af08806fb15ac934365621
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Fri Dec 28 13:46:14 2007 -0500
Unionfs: handle on lower inodes in lookup
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit b4684b225c71964fbc58ae3549c899335a6d523b
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Wed Dec 26 00:10:37 2007 -0500
Unionfs: minor code rearrangement in rename
To avoid too much code nesting.
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit efae1c6e325afdcfcb2f4ad59b05b10363430826
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Fri Dec 28 13:38:09 2007 -0500
Unionfs: implement lockdep classes
Lockdep fixes. Support locking order/classes (e.g., parent -> child ->
whiteout). Remove locking from create_parents: it's enough to just dget the
dentries in question. Move parent locking to from lookup_backend to caller,
unionfs_lookup.
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit deb0da9e5a0518df53d4e27fbf580aa23e0b450d
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Thu Dec 27 13:35:36 2007 -0500
Unionfs: prevent false lockdep warnings in stacking
A stackable file system like unionfs often performs an operation on a lower
file system, by calling a vfs_* method, having been called possibly by the
very same method from the VFS. Both calls to the vfs_* method grab a lock
in the same lock class, and hence lockdep complains. This warning is a
false positive in instances where unionfs only calls the vfs_* method on
lower objects; there's a strict lock ordering here: upper objects first,
then lower objects.
We want to prevent these false positives so that lockdep will not shutdown
so it'd still be able to warn us about potentially true locking problems.
So, we temporarily turn off lockdep ONLY AROUND the calls to vfs methods to
which we pass lower objects, and only for those instances where lockdep
complained. While this solution may seem unclean, it is not without
precedent: other places in the kernel also do similar temporary disabling,
of course after carefully having checked that it is the right thing to do.
In the long run, lockdep needs to be taught how to handle about stacking.
Then this patch can be removed. It is likely that such lockdep-stacking
support will do essentially the same as this patch: consider the same
ordering (upper then lower) and consider upper vs. lower locks to be in
different classes.
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 8a557428266dbc745dd9adf4ac61134be4abebc2
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Tue Dec 25 15:41:08 2007 -0500
Unionfs: remove unnecessary parent lock in create
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 1bad5701caef46593ed82152ceaa22295a97471d
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Tue Dec 25 15:40:23 2007 -0500
Unionfs: remove unnecessary locking in follow-link
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit d4c2a601cdc3d4aaf6063b574d6c65c311fa5e9d
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Thu Dec 20 23:14:44 2007 -0500
Unionfs: remove unnecessary lock in read_inode
Our read_inode doesn't need to grab the superblock rwsem because there no
chance it could be affected by branch management. But our read_inode was
called from other places which did grab need to grab that rwsem, and lockdep
complained.
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 8aa1bc8a223822cbc3e33eed5d11db2b9ed4c3bd
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Thu Dec 20 23:10:19 2007 -0500
Unionfs: remove unnecessary lock when deleting whiteouts
Lockdep complained, because we eventually call vfs_unlink which'd grab the
necessary locks.
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 18aba2eef84d671c4af5eaf524f997fc595a9fd1
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Thu Dec 20 15:22:22 2007 -0500
Unionfs: remove unnecessary conditional inode lock
This was intended to protect the inode during branch management, but that is
now done through our superblock rwsem.
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 07c5ab7ddfb58e3a778bd8ca455116c42be8c5fb
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Thu Dec 20 23:08:13 2007 -0500
Unionfs: prevent deadlock in cache coherency
Don't try to truncate_inode_pages in in purge_inode_data, because this could
lead to a deadlock between some of address_space ops and dentry
revalidation: the address space op is invoked with a lock on our own page,
and truncate_inode_pages will block on locked pages. Instead, it should be
enough to be gentler and just invalidate_mapping_pages.
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 3f0d5d2996fca5c93eb4728e88b75a465c2b0620
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Mon Dec 24 23:07:20 2007 -0500
Unionfs: remove custom read/write methods
Having them results in lockdep warnings about having locks and grabbing the
same class locks in do_sync_read/write which were called from
unionfs_read/write. All they did was revalidate out file object sooner,
which will now be deferred till a bit later. Instead, use generic
do_sync_read and do_sync_write.
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 1c98dbf3d595dacd9e84469edc1fc5cd1b4dc392
Author: Hugh Dickins <hugh at veritas.com>
Date: Fri Dec 28 13:41:39 2007 -0500
Unionfs: restructure unionfs_setattr and fix truncation order
Restructure the code to move the lower notify_change out of the loop in
unionfs_setattr. Cleanup and simplify the code. Then fix the truncation
order which fsx-linux in a unionfs on tmpfs found. Then handle copyup
properly.
When shrinking a file, unionfs_setattr needs to vmtruncate the upper level
before notifying change to the lower level, to eliminate those dirty pages
beyond new eof which otherwise drift down to the lower level's writepage,
writing beyond its eof (and later uncovered when the file is expanded).
Also truncate the upper level first when expanding, in the case when
the upper level's s_maxbytes is more limiting than the lower level's.
Signed-off-by: Hugh Dickins <hugh at veritas.com>
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 9277940c15ae059bf77ec6e487c535eb3dd187f6
Author: Hugh Dickins <hugh at veritas.com>
Date: Tue Dec 25 15:31:13 2007 -0500
Unionfs: mmap fixes
Remove !mapping_cap_writeback_dirty shortcircuit from unionfs_writepages.
It was introduced to avoid the stray AOP_WRITEPAGE_ACTIVATE coming from
shmem_writepage; but that has since been fixed in shmem_writepage and in
write_cache_pages. It stayed because it looked like a good optimization,
not to waste time calling down to tmpfs when that would serve no purpose.
But in fact this optimization causes hangs when running LTP with unionfs
over tmpfs. The problem is that the test comes at the wrong level: unionfs
has already declared in its default_backing_dev_info that it's playing by
cap_writeback_dirty rules. If it does nothing here in its writepages, its
dirty pages accumulate and choke the system. What's needed is to carry on
down and let its pages be cleaned while in turn they dirty the lower level.
And this now has an additional benefit for tmpfs, that a sync or pdflush
pushes these pages down to shmem_writepage, letting it match the filepage
coming from unionfs with the swap which may have been allocated earlier,
so it can free the duplication sooner than waiting for further pressure.
Remove unnecessary locking/code from prepare_write. Handle if no lower
inodes in writepage.
Signed-off-by: Hugh Dickins <hugh at veritas.com>
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 60ba85732ae69553d4920db1612e6c7cbc1c59c0
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Tue Dec 18 19:14:46 2007 -0500
Unionfs: release special files on copyup
If we copyup a special file (char, block, etc.), then dput the source
object.
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit a3767ea7c9f041057e9e3618e1abe45ccce27c12
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Tue Dec 18 18:57:24 2007 -0500
Unionfs: create new symlinks only in first branch
When creating a new symlink, always create it in the first branch, which is
always writeable, not in the branch which may have a whiteout in it. This
makes the policy for the creation of new symlinks consistent with that of
new files/directories, as well as improves efficiency a bit.
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 96a835ac943ee48eaeece2ec8a733eea0bebb05b
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Tue Dec 18 18:56:55 2007 -0500
Unionfs: create new special files only in first branch
When creating a new special file, always create it in the first branch,
which is always writeable, not in the branch which may have a whiteout in
it. This makes the policy for the creation of new special files consistent
with that of new files/directories, as well as improves efficiency a bit.
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit a38167af79bbf4c4645e07c2465e29ef15dc3471
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Tue Dec 18 01:06:30 2007 -0500
Unionfs: initialize inode times for reused inodes
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 65d92e96d9e0d1976ceabac828bc64f3d1669e2e
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Thu Dec 20 22:40:38 2007 -0500
Unionfs: interpose cleanup and fix for spliced dentries
Fix unionfs_interpose to fill lower inode info when d_splice_alias returns
NULL. Also cleanup impossible case (d_splice_alias doesn't return ERR_PTR).
Signed-off-by: Rachita Kothiyal <rachita at fsl.cs.sunysb.edu>
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 82919c6211e15145554e6c7c764b3a0cf08d6119
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Fri Dec 28 14:08:11 2007 -0500
Unionfs: clarify usage.txt read/write behavior
CC: Michael Tokarev <mjt at tls.msk.ru>
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 040cb428d85d1bef72cd3a820f42e699b5c3101b
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Fri Dec 21 00:27:47 2007 -0500
Unionfs: use locking around i_size_write in 32-bit systems
CC: Hugh Dickins <hugh at veritas.com>
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 46a69f0b644d9c9213b4febbb49bf06f06979301
Author: Hugh Dickins <hugh at veritas.com>
Date: Tue Dec 25 16:39:35 2007 -0500
VFS/fs_stack: use locking around i_size_write in 32-bit systems
LTP's iogen01 doio tests hang nicely on 32-bit SMP when /tmp is a unionfs
mount of a tmpfs. See the comment on i_size_write in linux/fs.h: it needs
to be locked, otherwise i_size_read can spin forever waiting for a lost
seqcount update.
Most filesystems are already holding i_mutex for this, but unionfs calls
fsstack_copy_inode_size from many places, not necessarily holding i_mutex.
Use the low-level i_lock within fsstack_copy_inode_size when 32-bit SMP.
Checked the entire unionfs code to ensure this is the right fix for
i_size_write().
Also compared to what other file systems do when they have to handle inodes,
esp. not their own inodes (e.g., network file systems have to access the
exported file system's inodes). Found out that most such file systems not just
don't lock around i_size_write, but they don't even use i_size_read or
i_size_write to access the inode's size.
CC: Mike Halcrow <mhalcrow at us.ibm.com>
Signed-off-by: Hugh Dickins <hugh at veritas.com>
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit c26e06e9a0b1f22e4c6009be58931f1bd00086d6
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Tue Dec 25 16:37:01 2007 -0500
VFS/fs_stack: drop cast on inode passed to i_size_read
i_size_read() takes 'const struct inode *' already, as of 2.6.20.
CC: Mike Halcrow <mhalcrow at us.ibm.com>
Signed-off-by: Jan Engelhardt <jengelh at computergmbh.de>
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit d5110b319f4464a7bd68d35e902a20c51be59d02
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Thu Dec 13 17:11:30 2007 -0500
Unionfs: clarify usage.txt mount options
CC: Jim Kissel <jlk at osml.eu>
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 48b71974e89125a189f02c3d0d576607aee2a9e0
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Wed Dec 12 12:31:26 2007 -0500
Unionfs: avoid using drop_pagecache_sb in remount
Exporting drop_pagecache_sb to modules is somewhat risky because one cannot
sleep inside invalidate_mapping_pages. This could cause a lot of latency in
the pre-emption code. So don't export this symbol to minimize the risk that
others will use it.
Instead, unionfs will try to directly invalidate as many pages it can from
the unionfs_remount code. Invalidating those inode pages is not strictly
required, but helpful in encouraging a revalidation of inodes sooner than
waiting for individual f/s ops to access the union. Since a remount is
already an expensive but rare operation, this inode pages invalidation
shouldn't add too much overhead.
CC: Nick Piggin <nickpiggin at yahoo.com.au>
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit d286e5aae05366194855579b595c3bde41594898
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Sat Dec 8 13:47:57 2007 -0500
Unionfs: release 2.1.11
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit ad8749a81febedc30438cb50973342c4bdd35d86
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Fri Dec 7 19:44:02 2007 -0500
Unionfs: reduce the amount of cache-coherency debugging messages
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit cab755f87290cbfc63c272105e275fceb4b5b576
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Fri Dec 7 16:09:24 2007 -0500
Unionfs: cleanup/consolidate branch-mode parsing code
Also a bug fix: disallow unrecognized branch modes at mount time, instead of
defaulting to "rw".
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 0ffe033ed96ecebd4fc38fa46c691de8dcd4d13e
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Mon Nov 26 19:11:38 2007 -0500
Unionfs: call wait_on_page_writeback before clear_page_dirty_for_io
CC: Hugh Dickins <hugh at veritas.com>
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 05bed92543372dc0e60a240da5ac21d49b20de5a
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Sun Nov 25 22:40:07 2007 -0500
Unionfs: release 2.1.10
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit daf60ff36d6e36ceb0d3dd4552bb69c3b398182b
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Sun Nov 25 13:35:54 2007 -0500
Unionfs: use generic_file_aio_read/write
There's no apparent need to define our own aio_read/write methods.
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 112f0605ac15936694a2c70fe265862b08eb0362
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Sun Nov 25 13:34:04 2007 -0500
Unionfs: update our inode size correctly upon partial write
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 458cf20eb704b29730d73c6c0cbc0c4d7eaabd51
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Sun Nov 25 14:51:56 2007 -0500
Unionfs: prevent multiple writers to lower_page
Without this patch, the LTP fs test "rwtest04" triggers a
BUG_ON(PageWriteback(page)) in fs/buffer.c:1706.
CC: Hugh Dickins <hugh at veritas.com>
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit c4cb9ef5ebd845ffebcba8d376dd6483340d6eae
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Sat Nov 24 20:05:47 2007 -0500
Unionfs: support splice(2)
Also remove redundant variable from unionfs_readpage (saves a bit on stack
space).
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit ea48fe11ce13c414af81a17c2f8224b44ba91fa9
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Sat Nov 24 16:43:36 2007 -0500
Unionfs: reintroduce a bmap method
This is needed for swapon(2) files in the union.
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit a5699bae5e85cf490b772e47f2747314d0e6e195
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Sat Nov 24 16:03:14 2007 -0500
Unionfs: update times in setattr
Needed to maintain Unix semantics via utimes(2).
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 0716ce836b3fdc23418abd4e9d19ecc39fda7384
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Sun Nov 25 23:01:28 2007 -0500
Unionfs: create opaque directories' whiteouts unconditionally
Needed to maintain Unix semantics (LTP testing).
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit c712ed38890218ab83000720cd579a0b1107e5f6
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Sun Nov 25 15:48:40 2007 -0500
Unionfs: don't create whiteouts on rightmost branch
If we are unlinking/rmdir'ing an object on the rightmost branch, there's no
need to create a whiteout there: this saves on storage space and inodes.
Also, in the (degenerate) case of having only one branch, this really saves
on whiteouts.
CC: Hugh Dickins <hugh at veritas.com>
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 7026b14c93027539c9ab18dc8d83edbba35064c2
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Sun Nov 25 15:47:57 2007 -0500
Unionfs: release lower resources on successful rmdir
This patch prevents those resources from lingering around until memory
pressure would have forced them out. The patch also properly handles
directories that have been rmdir'ed which are still some process's cwd.
CC: Hugh Dickins <hugh at veritas.com>
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 6cafaf8971a65419c2667ff8285348f29839b6fe
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Sat Nov 24 02:55:21 2007 -0500
Unionfs: remove useless debugging messages
These are considered normal behaviour, they don't really reveal any insight
to the person debugging the code, and they tend to clutter console messages.
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 4345fcf9da2efad827d227891f4c447707fbc9e3
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Tue Nov 20 22:29:20 2007 -0500
Unionfs: handle whiteouts more efficiently in filldir
If we cache a dirent for file "foo", and then it gets deleted, then we look
for a ".wh.foo" whiteout entry in the same dirent cache. But our dirent
cache strips the ".wh." prefix, thus looking for an entry named "foo" whose
filldir_node->whiteout should be 1 instead of 0. In that case, don't
display an incorrect printk message that the file system may be corrupt,
but set that filldir_node->whiteout to 1.
CC: Hugh Dickins <hugh at veritas.com>
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit b00963f9e47bee0ae9716f043e204d39bc077308
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Tue Nov 20 22:23:08 2007 -0500
Unionfs: set lower mnt after mkdir which resulted in copyup
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 6910924c41ae5da4e9ad3ba5f4332af8700ce92d
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Sat Nov 24 02:09:28 2007 -0500
Unionfs: minor cleanup in the debugging infrastructure
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit f3e8d9f14e3433b90e615d08b244478bb8bdf48c
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Sun Nov 18 20:46:16 2007 -0500
Unionfs: minor coding standards applied
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 1a938af1faf86a6fea9b65793112c57e55493be5
Author: Hugh Dickins <hugh at veritas.com>
Date: Sun Nov 18 20:26:05 2007 -0500
Unionfs: minor cleanup in writepage
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 51d3a3eef7ff939cd6ef9364aa86f530c325b71a
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Sun Nov 18 20:23:08 2007 -0500
Unionfs: use f_path instead of f_dentry/mnt
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit ebd609088f941a6b6f4639ced0209c50ee586763
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Wed Nov 21 21:55:53 2007 -0500
Unionfs: cleaner support for RT patches
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 72cf842a185db89a4a2a30348107b530c5f248b6
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Mon Nov 12 22:55:22 2007 -0500
Unionfs: release 2.1.9
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 5dc5081e0917daa3a2fd746ea2600f137f0d02f1
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Sun Nov 11 19:40:49 2007 -0500
Unionfs: move debugging checks inside locks
This is to ensure that the objects we want to check aren't being destroyed
or changed by another thread.
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 57f6b8174e8c03352d03bfdfde5d2ac051cb29fd
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Mon Nov 12 20:36:20 2007 -0500
Unionfs: fold do_readpage into unionfs_readpage
Simplify the code and reduce stack pressure a bit.
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 58269eae26ac8d509c2d23440a1c82d46f572286
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Sun Nov 11 18:34:34 2007 -0500
Unionfs: remove unnecessary lower atime updates
No need for this because our readpage calls vfs_read on the lower objects,
which would update the atime as/if needed.
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 182812826b264ed2d6577720cb4a60061ebbb276
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Mon Nov 12 20:35:58 2007 -0500
Unionfs: debugging updates
Don't perform dentry+inode checks unless both are valid.
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 1370aecac49ee8bb19da6b807fc6308c44d47774
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Fri Nov 9 10:27:32 2007 -0500
Unionfs: clear partial read in readpage
Signed-off-by: Hugh Dickins <hugh at veritas.com>
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 5c4f047322622b23a93068869b64dcdcadeb1ee4
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Mon Nov 12 20:34:28 2007 -0500
Unionfs: writepage updates
Don't set/reset the PageUptodate flag on our page. Call flush_dcache_page
on the lower page after copy_highpage, and set it uptodate. Call
set_page_dirty right before clear_page_dirty_for_io.
CC: Hugh Dickins <hugh at veritas.com>
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 95fa573d47d11a504fdc38d0265c83e70ecb0261
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Sat Nov 10 20:20:58 2007 -0500
Unionfs: update cache-coherency detection heuristics
Use a small delay to reduce the number of times unionfs has to detect
changed mtime's/ctime's, and also reduce the potential for false positives.
See Documentation/filesystems/unionfs/concepts.txt for a detailed
discussion.
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 92c5286d88e155d5518f781f1a1a5d27d70ccc5c
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Sat Nov 10 16:01:38 2007 -0500
Unionfs: use i_size wrappers
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit f819ad89e95b0c037261fa3e6b864ea7c24ac801
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Sat Nov 10 22:01:16 2007 -0500
Unionfs: flush and release updates
Remove the totalopens counter which was intended to reduce unnecessary
processing of d_deleted dentries. Move that processing from file_release to
flush.
Cc: Hugh Dickins <hugh at veritas.com>
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit f1bd54302eb3752528ddb925c55d556dfe761cb1
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Fri Nov 2 19:45:30 2007 -0400
Unionfs: release 2.1.8
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit c64958987b98745e6ff7c7e97919cd272e7fc005
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Fri Nov 2 19:56:49 2007 -0400
Unionfs/VFS: no need to export 2 symbols in security/security.c
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit cc907eb2675749483619cf8a0936f1145c8c53dd
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Thu Nov 1 01:38:09 2007 -0400
Unionfs: don't printk an error if it's due to common copyup
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 540a2df02039848ce3d2c279706837197015c19a
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Thu Nov 1 00:41:03 2007 -0400
Unionfs: don't bother validating inode if it has no lower branches
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit eadb36d64768e3ba5e0bafe759e1a33a68a73718
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Thu Nov 1 21:27:54 2007 -0400
Unionfs: avoid a deadlock during branch-management on a pivot_root'ed union
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
Acked-by: Herton Ronaldo Krzesinski <herton at mandriva.com>
commit aab14b9d1d2273f287f2b4192b84a655de9f5fb4
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Wed Oct 31 19:04:26 2007 -0400
Unionfs: mmap updates
Rewrite unionfs_writepage to minimize dependence on AOP_WRITEPAGE_ACTIVEATE,
handle memory pressure better, and update documentation. Remove
unionfs_sync_page because it's not needed.
CC: Hugh Dickins <hugh at veritas.com>
CC: Pekka Enberg <penberg at cs.helsinki.fi>
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 4cc92f4a79b16d0bd86dea069399e9d435680bc7
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Sun Oct 28 20:24:34 2007 -0400
Unionfs: update usage.txt documention
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 74926bcceb2cbd44e6c3ad82aae620007f618995
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Thu Nov 1 20:33:12 2007 -0400
Unionfs: cleanup permission checking code
Use vfs helpers and avoid redundant checks performed by the VFS already.
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 5441a281e9480b5de2e6ac13927725a6af62721a
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Sun Oct 28 20:24:39 2007 -0400
Unionfs: delete whiteouts in sticky directories
This is needed to maintain Unix semantics.
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit f491b080243dbebd93c32e520558d8c89505e7f3
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Fri Nov 2 19:33:00 2007 -0400
Unionfs: revert fs/Kconfig text update
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 9544183dad248a98254b78a48a3050c760a37991
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Thu Oct 18 20:35:06 2007 -0400
Unionfs: release 2.1.7
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 0753b07262b8a159bc9dcf22a705d54b932503bc
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Sun Oct 21 16:06:42 2007 -0400
Unionfs: remove obsolete #define and comment
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 061218b86ea6b88890cddc3470f85fbd1fe6bb3f
Author: Jeff Layton <jlayton at redhat.com>
Date: Fri Oct 19 00:44:00 2007 -0400
Unionfs: fix unionfs_setattr to handle ATTR_KILL_S*ID
Don't allow unionfs_setattr to trip the BUG() in notify_change. Clear
ATTR_MODE if the either ATTR_KILL_S*ID is set. This also allows the
lower filesystem to interpret these bits in its own way.
Signed-off-by: Jeff Layton <jlayton at redhat.com>
Cc: Josef 'Jeff' Sipek <jsipek at cs.sunysb.edu>
Cc: Christoph Hellwig <hch at lst.de>
Signed-off-by: Andrew Morton <akpm at linux-foundation.org>
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit e7d8205acf3b00deb84c96d3a98f944eba263f21
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Thu Oct 18 17:16:51 2007 -0400
Unionfs: remove for_writepages nfs workaround
This is no longer necessary since struct writeback_control no longer has a
fs_private field which lower file systems (esp. nfs) use. Plus, unionfs now
defines its own ->writepages method.
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 265c9d8b7ae254852791ed34d855a60edbd65d3b
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Thu Oct 18 14:03:16 2007 -0400
Unionfs: convert a printk to pr_debug in release
This is mostly an informational message, not an error.
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 1624bc1f4c18a9d98dd3ce8fe213c79db17addac
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Wed Oct 17 17:35:02 2007 -0400
Unionfs: don't bother validating dentry if it has no lower branches
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 806920cf4a3b77631e1d38738783294bf816e154
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Wed Oct 17 16:37:51 2007 -0400
Unionfs: don't printk trivial message upon normal rename-copyup
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 52a1432e4e7f64bc53e0da2273954a2ec765f160
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Tue Oct 16 10:50:16 2007 -0400
Unionfs: support lower filesystems without writeback capability
Implement unionfs_writepages. As per
mm/filemap.c:__filemap_fdatawrite_range(), don't call our writepage if the
lower mapping has BDI_CAP_NO_WRITEBACK capability set.
Signed-off-by: Pekka J Enberg <penberg at cs.helsinki.fi>
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit cf3a4a660e99c615c41ad86ec243bdca543996a9
Author: Andrew Morton <akpm at linux-foundation.org>
Date: Thu Oct 18 15:54:55 2007 -0400
Unionfs: slab api remove useless ctor parameter and reorder parameters
fs/unionfs/super.c: In function 'unionfs_init_inode_cache':
fs/unionfs/super.c:874: warning: passing argument 5 of 'kmem_cache_create' from incompatible pointer type
Cc: Christoph Lameter <clameter at sgi.com>
Cc: Josef 'Jeff' Sipek <jsipek at cs.sunysb.edu>
Signed-off-by: Andrew Morton <akpm at linux-foundation.org>
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 6294c9e25b2d226ea2770fd3080f75ffeae7c15d
Author: Andrew Morton <akpm at linux-foundation.org>
Date: Thu Oct 18 15:50:15 2007 -0400
Unionfs: security convert lsm into a static interface fix
ERROR: "security_inode_permission" [fs/unionfs/unionfs.ko] undefined!
ERROR: "security_file_ioctl" [fs/unionfs/unionfs.ko] undefined!
Need these back.
Cc: "Serge E. Hallyn" <serue at us.ibm.com>
Cc: Arjan van de Ven <arjan at infradead.org>
Cc: Chris Wright <chrisw at sous-sol.org>
Cc: James Morris <jmorris at namei.org>
Cc: Stephen Smalley <sds at tycho.nsa.gov>
Cc: Josef 'Jeff' Sipek <jsipek at cs.sunysb.edu>
Signed-off-by: Andrew Morton <akpm at linux-foundation.org>
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit a0a5325d17093e4ff9c7039133c7854165117509
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Sun Sep 30 15:04:31 2007 -0400
Unionfs: release 2.1.6
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 618981cd53f3b229d6b5dc64a8278f64498b5bd0
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Sun Sep 30 13:47:14 2007 -0400
Unionfs: coding style: avoid lines longer than 80 chars
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 523472ee0586d2299881bb0fd176c6c09617b2ed
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Sat Sep 29 01:36:57 2007 -0400
Unionfs: coding style: miscellaneous fixes
No braces around single-statement if's.
No externs in .c files.
use <linux/mman.h> not <asm/mman.h>.
Use (foo *) not (foo*).
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 9ea87aea055c2a98f99877ed026742776e28e947
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Sat Sep 29 01:36:57 2007 -0400
Unionfs: coding style: avoid multiple assignments on same line
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 0a5d9eb83b58ca7c50526cb9dcd0b550dcb43b6a
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Sat Sep 29 01:36:57 2007 -0400
Unionfs: coding style: take assignments out of "if" conditions
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 90bed1269c688ebf795123457f76f1d835d8b962
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Sun Sep 30 13:11:16 2007 -0400
Unionfs: coding style: proper spacing
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit fc396deac75fcf3d4557c74db4e5c1171d2d21ec
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Sat Sep 29 01:36:57 2007 -0400
Unionfs: use braces in both branches of conditionals
As per CodingStyle, if one branch of an if-then-else has braces because it
has multiple statements, then the other branch should have braces too, even
if the other branch has only one statement in it.
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 5f5b5341f62574844abf124b9ee7e96ab46d476c
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Sat Sep 29 01:36:57 2007 -0400
Unionfs: remove periods from the end of printk strings
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 3e1a8795b756b250af8c04dccad66c694a5cbfcd
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Sat Sep 29 01:36:57 2007 -0400
Unionfs: update/assign a KERN_* level to all printk statements
Also use pr_info() instead of printk(KERN_INFO ...)
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 9ab4aa39bbb90f38549fe859008bd13e337f8d54
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Sat Sep 29 01:36:57 2007 -0400
Unionfs: add missing newlines in printk's
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit a8e877c180724d6ae339429a0a2cbe31c9fa6083
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Sat Sep 29 01:36:57 2007 -0400
Unionfs: convert all appropriate printk's to pr_debug calls
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 2fe8cf7e55d6369f5ebcabd2dd529be2c40197ce
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Sat Sep 29 01:36:57 2007 -0400
Unionfs: use pr_debug() instead of custom dprintk()
Also turn on DEBUG if CONFIG_UNION_FS_DEBUG is on
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 358a12d2dcb38bcbca9cc55de1c85130bee02b05
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Sat Sep 29 01:36:57 2007 -0400
Unionfs: use page_offset() helper
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 29ac194164bba1a09118f5275d5dbdfd93f61292
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Sat Sep 29 01:36:57 2007 -0400
Unionfs: remove unnecessary if condition
The condition is always true there.
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 1a4705cc722ad26721f0b3445dd67d076a47886b
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Sat Sep 29 01:36:57 2007 -0400
Unionfs: properly indent static struct
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 24ef95431e696f1ff4e896928d4a1d79193f01ac
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Sat Sep 29 01:36:57 2007 -0400
Unionfs: use UNIONFS_NAME macro
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit ce3a6e595aee7612b9ba0302eebe0e70b5f7e355
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Sat Sep 29 01:36:57 2007 -0400
Unionfs: use consistent printk prefixes
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 95d8abbd0daca738ee2b4c7489c4e07d631248fe
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Sat Sep 29 01:36:57 2007 -0400
Unionfs: minor comment cleanups
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit cb6d0b5252198481040de8ec81ca0b4bf9b9e90d
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Sat Sep 29 01:36:57 2007 -0400
Unionfs: compile if debug is off
Signed-of-by: John Johansen <jjohansen at suse.de>
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 5a19c446f74388ad037d9bb8103b8631d458d9d0
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Thu Sep 27 23:55:57 2007 -0400
patch unionfs_undo_unnecessary_unlikely_calls
commit 5b3874935d0ae75741c7952ca7ba1bb1d093911e
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Thu Sep 27 23:45:46 2007 -0400
Unionfs: display informational messages only if debug is on
This is to avoid filling the console/logs with messages that are primarily
of debugging use.
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
Acked-by: Josef 'Jeff' Sipek <jsipek at cs.sunysb.edu>
commit 63e17faf4f42cc04af79b6f05cab17be29f8ca87
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Tue Sep 25 22:39:53 2007 -0400
Unionfs: release 2.1.5
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit c87b3ba14624c0d6ecf21feef74f1ffb9d6907e3
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Tue Sep 25 22:14:43 2007 -0400
Unionfs: use poison.h for safe poison pointers
This also fixes a compile warning on 64-bit systems.
Signed-off-by: Josef 'Jeff' Sipek <jsipek at cs.sunysb.edu>
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit afbcdab902c0911ce6385a030c12363f27eadbae
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Tue Sep 25 00:44:44 2007 -0400
Unionfs: add un/likely conditionals on xattr ops
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 05e0ed1fa863da38d5bc2c7c8a01812e0c7fd2d3
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Tue Sep 25 00:44:44 2007 -0400
Unionfs: add un/likely conditionals on unlink ops
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit b538d910f898938605b785a85d9f93ee9ad44fd8
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Mon Sep 24 02:22:53 2007 -0400
Unionfs: add un/likely conditionals on common subr
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 29a7b152cba5dd3e2fc41ca121c2d051e929eb39
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Mon Sep 24 01:09:14 2007 -0400
Unionfs: add un/likely conditionals on readdir ops
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit b8b50d0aa9f62bbf9a53a3559d38d54e13ec6624
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Mon Sep 24 01:09:14 2007 -0400
Unionfs: add un/likely conditionals on rename ops
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 91c534ee0cf352e237d2b860d0cbeca09cc28524
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Mon Sep 24 01:09:14 2007 -0400
Unionfs: add un/likely conditionals on mmap ops
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 9441aa54dc618a4e2945106ba4ba0f2c2ea95752
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Mon Sep 24 01:09:14 2007 -0400
Unionfs: add un/likely conditionals on super ops
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit ef98083fde26fe99d3b7b54bd36f860912fcde7f
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Mon Sep 24 01:09:14 2007 -0400
Unionfs: add un/likely conditionals on lookup ops
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit fa99c2a2cae31998c862b0b94741b04f304c45da
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Mon Sep 24 01:09:14 2007 -0400
Unionfs: add un/likely conditionals on inode ops
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit b92d8a33bcad73fda660c61b7c8bca961ea2b359
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Mon Sep 24 02:21:13 2007 -0400
Unionfs: add un/likely conditionals on fileops
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 38ba1f92c0ae3680b6472fb67ce0919bc76e34a9
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Mon Sep 24 02:21:09 2007 -0400
Unionfs: add un/likely conditionals on headers
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 77b320d2eb9995a59280b07eb7007b54b9006e4a
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Mon Sep 24 01:09:14 2007 -0400
Unionfs: add un/likely conditionals on dir ops
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 64278f4a2949d00d013f0adfff2a5301bcc71d1c
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Mon Sep 24 01:09:14 2007 -0400
Unionfs: add un/likely conditionals on dentry ops
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 9e38aab29f45a24308365bff6ee4e2afb7503d1d
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Mon Sep 24 01:09:14 2007 -0400
Unionfs: add un/likely conditionals on debug ops
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 75643eec799840be0b7d29e92f1ac57903b67069
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Mon Sep 24 01:09:14 2007 -0400
Unionfs: add un/likely conditionals on copyup ops
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit d8108bb6ca1c999bc37dcfe39a3749165f7f2847
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Mon Sep 24 01:09:41 2007 -0400
Unionfs: add un/likely conditionals on common fileops
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 8ec60f0801c59d6a8b5b3e44a182c19cc1bdd22f
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Tue Sep 25 00:50:48 2007 -0400
Unionfs: lower nameidata support for nfsv4
Pass nameidata structures as needed to the lower file system, support
LOOKUP_ACCESS/OPEN intents. This makes unionfs work on top of nfsv4.
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit cfb8b8a9cacc617259cb9a2751310f89cf271b4d
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Tue Sep 25 00:44:44 2007 -0400
Unionfs: add lower nameidata debugging support
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit b73823106ebf2d88f55382100c5a33e9e522b13f
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Tue Sep 25 00:44:44 2007 -0400
Unionfs: minor coding style updates
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit a3047a7e930398e5b0199dff6096f933886cc3b2
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Tue Sep 25 00:44:44 2007 -0400
Unionfs: cast page->index loff_t before shifting
Fixes bugs in number promotion/demotion computation, as per
<http://lkml.org/lkml/2007/9/20/17>
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit f1f40e9269f025650cbc94a529235cb543f5a554
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Thu Sep 20 00:14:33 2007 -0400
Unionfs: release 2.1.4
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit ee8305b364e6f3e32bcfb52d60ee0188fa380844
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Wed Sep 19 23:52:18 2007 -0400
Unionfs: cache-coherency fixes
Do not update mtime if there is no upper branch for the inode. This
prevents from calling unionfs_lower_inode_idx() with a negative index, which
triggers a bug.
Signed-off-by: Olivier Blin <blino at mandriva.com>
Acked-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 9cda794a3f695da0d20f7513894f6a2d72ac8785
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Thu Sep 20 00:59:05 2007 -0400
Unionfs: display informational messages only if debug is on
This is to avoid filling the console/logs with messages that are primarily
of debugging use.
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 1ab10220492d38e8017084ebd7219e62d0d0d1e0
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Wed Sep 19 21:18:35 2007 -0400
Unionfs: use int in unionfs_d_revalidate
We have to use an int, even though unionfs_d_revalidate calls other routines
that return only true/false, b/c ->d_revalidate is allowed to return a
negative errno number.
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit f2c2fc75cfd5ae74965b54adf9716e0ddf82f0ea
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Wed Sep 19 21:12:37 2007 -0400
Unionfs: documentation updates/corrections
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 7a5adbb6d4bd874d8ab936b2a02ff4c7c96bead8
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Mon Sep 10 23:38:02 2007 -0400
Unionfs: release 2.1.3
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 5bd98d16f1c99623558bb6f9cd1209361fe436bf
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Mon Sep 10 20:19:29 2007 -0400
Unionfs: cache coherency after lower objects are removed
Prevent an oops if a lower file is deleted and then it is stat'ed from the
upper layer. Ensure that we return a negative dentry so the user will get
an ENOENT. Properly dput/mntput so we don't leak references at the lower
file system.
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 6907eb37bc8cbf6031a0a52a8c305301f0bea2eb
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Mon Sep 10 20:15:37 2007 -0400
Unionfs: unionfs_lookup locking consistency
Ensure that our lookup locking is consistent and symmetric: if a lock
existed before calling lookup_backend, it should remain so; only if
performing a lookup of a known new dentry, should lookup_backend return a
newly-locked dentry-inode info (and only if there was no error). Document
this behavior. This cleanup allowed us to remove two unnecessary int
declarations.
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 0ee995ceb0797ea74f5529701a825f693388cec4
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Mon Sep 10 20:10:31 2007 -0400
Unionfs: use boolean type in unionfs_d_revalidate
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 5a5fa0695c15ee45ce2ed29ae4026fd6e10514c6
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Mon Sep 10 20:09:41 2007 -0400
Unionfs: add missing newlines to printks
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 6b740acfe772e84a475640db139f195ce27722d8
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Thu Sep 6 00:41:59 2007 -0400
Unionfs: remove unnecessary comment
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit f46764d43eee8bb9412efebed591a9c7ae8afb4a
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Thu Sep 6 00:40:02 2007 -0400
Unionfs: documentation updates
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 51ef13a4054ae6854e22a5d63273be1e28219ac2
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Thu Sep 6 00:35:12 2007 -0400
Unionfs: use bool type in dentry and file revalidation code
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 781c45f2d60f5779937fecaae781905d0690d7c9
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Thu Sep 6 00:42:56 2007 -0400
Unionfs: cache-coherency fix for is_newer_lower
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 8d7f844030bd01cb9dfef34ae5cc54578e0c8f7e
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Wed Sep 5 22:18:44 2007 -0400
Unionfs: import Jeff's fixes from korg
64 bit fixes for debugging support.
Use bool type where appropriate.
Minor code cleanups.
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
Signed-off-by: Josef 'Jeff' Sipek <jsipek at cs.sunysb.edu>
commit 612cd234acc3e1b4246bc02889b802caa343d506
Author: Josef 'Jeff' Sipek <jsipek at cs.sunysb.edu>
Date: Mon Sep 3 17:32:07 2007 -0400
Unionfs: Remove unused #defines
Signed-off-by: Josef 'Jeff' Sipek <jsipek at cs.sunysb.edu>
commit b388d27598a14845619936040d4132f04586754f
Author: Josef 'Jeff' Sipek <jsipek at cs.sunysb.edu>
Date: Mon Sep 3 17:22:45 2007 -0400
Unionfs: Simplify unionfs_get_nlinks
Since we set the right value for d_type in readdir, there's really no point
in having to calculate the number of directory links. Some on-disk
filesystems don't even store the number of links for directories.
Signed-off-by: Josef 'Jeff' Sipek <jsipek at cs.sunysb.edu>
commit 7b581561766fe45f5a1dadce128545767511e2df
Author: Josef 'Jeff' Sipek <jsipek at cs.sunysb.edu>
Date: Fri Aug 31 19:31:58 2007 -0400
Unionfs: unionfs_create rewrite
The code was hard to follow and violated some invariants (e.g., never modify
a read only branch, and always create on branch 0).
Signed-off-by: Josef 'Jeff' Sipek <jsipek at cs.sunysb.edu>
commit 88c78f58704d646d372fca47f6d2c7326fab3ee6
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Fri Aug 31 11:24:06 2007 -0400
Unionfs: document lockdep issues
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 86880d67b06ce04c6b0451f9242e460afe63bd03
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Fri Aug 24 10:42:56 2007 -0400
Unionfs: support CONFIG_PREEMPT_RT
Use compat_rw_semaphore when using the real-time preemption patches.
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 3fb5209946d838f1d40953284a115ada971cb621
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Wed Aug 22 18:08:48 2007 -0400
Unionfs: release 2.1.2
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 4ec752ccda266fc332e6211504844a9cf357669d
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Wed Aug 22 16:49:09 2007 -0400
Unionfs: imported fixes from korg branch's take-3 series
- removed EACCES/EROFS text from issues.txt
- updated sioq.[hc] copyright dates to 2006 (not earlier)
- added small XXX comment to xattr copyup code (selinux CAP_FOWNER stuff) to
say that entire copyup code should be moved to SIOQ.
- copyup_xattr: renamed name_list_orig -> name_list_buf
- multi-line static inline unionfs_xattr_kfree
- rewrote unionfs_interpose a bit cleaner (no backward goto's, better
variable names, use small util fxn, etc.)
- introduced CONFIG_UNION_FS_DEBUG instead of hand-editing makefile
- unionfs_mntget/put cleanups
- bug fix to is_robranch_idx (thanks to Patrick Aussems). Fixed bug #571.
- fixed a couple of important bugs in our init/release_lower_nd
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 97193aff6f78f413d45596e537f795689ddb24f5
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Sun Aug 19 15:54:06 2007 -0400
Unionfs: release 2.1.1.
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 99da0fb29490bd812af2d550f89c1a01ea8d2af4
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Sun Aug 19 15:22:43 2007 -0400
Unionfs: minor usage.txt documentation fix
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 360e998d78ed79d3084f67341e203655a1c1dc10
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Sat Aug 18 16:02:02 2007 -0400
Unionfs: imported fixes from korg branch
Export release_open_intent.
SElinux: xattr fixes (CAP_FOWNER).
unionfs_xattr_kfree inline function.
alloc_lower_nd -> init_lower_nd.
free_lower_nd -> release_lower_nd.
unionfs_purge_extras -> unionfs_postcopyup_release.
unionfs_inherit_mnt -> unionfs_postcopyup_setmnt.
minor code/copyright cleanups.
MS_SILENT remount fix.
simplify unionfs_mntget/put.
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 0ed812274e4039158b3fa3cad620ef7138987aa9
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Sat Aug 11 14:01:08 2007 -0400
Unionfs: back-port stuff from Jeff's korg branch to per-kernel branches
Just a bunch of code cleanups: no functionality changed.
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
Signed-off-by: Josef 'Jeff' Sipek <jsipek at cs.sunysb.edu>
commit 9fc3d1cbfa147471e99ca736030756d8cd2c5fa0
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Sat Aug 11 13:57:38 2007 -0400
MM/VFS: prevent compile warnings/errors with unknown struct super_block
This is a temp fix for 2.6.23-rc2.
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 906305c5f551ab6363aceb6b965eff3e8bb3ea3f
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Fri Aug 10 22:21:05 2007 -0400
Revert "bugfix: add MODULE_LICENSE to mtdsuper module so it loads"
This reverts commit 924185024a661a3a0fb772fde4ce178e587ed018.
commit 3b171c9d8e6e290e1c500058bbb3326d07f4704d
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Thu Aug 9 17:04:19 2007 -0400
Unionfs/eCryptfs: remove lookup_one_len_nd and LOOKUP_ONE code
Signed-off-by: Josef 'Jeff' Sipek <jsipek at cs.sunysb.edu>
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 72263ef70ef6df8c954dba49c8c11990c828b824
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Tue Aug 7 18:51:20 2007 -0400
Unionfs: support incremental versions
Also: release Unionfs 2.1 (since code has gotten much more stable since 2.0)
Unionfs will now report its precise version number and the kernel it was
meant for, upon module loading. This is useful for maintenance purposes:
users can report the precise release number of Unionfs, and it also helps
prevent running older versions when newer ones are intended, or mixing
versions among supported kernels.
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 744faba4beff73233c7fd8a669c39024becb34ab
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Wed Aug 1 10:29:42 2007 -0400
Unionfs: check for immutable files before read-only branches
Immutable files should never be allowed to be copied-up on write, even if
they're on read-only file systems or branches.
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 28c8ddaf6825ef7d0cc2243bb9de78b6099270bb
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Tue Jul 31 19:25:55 2007 -0400
Unionfs: mmap fixes to unionfs_writepage
Don't call unlock_page on lower_page unless lower ->writepage failed.
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 9097678efbbb076608d32dbd6aa6fd5022e935b5
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Tue Jul 31 18:12:25 2007 -0400
Unionfs: rewrite cleanup_file more cleanly
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 887ceffe4faf01d24895473d2d3066b6f3f046b7
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Tue Jul 31 03:58:50 2007 -0400
Unionfs: improved printk upon copyup
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 67c856f75122698fb7493d22a66d23fc77ff0ab8
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Tue Jul 31 03:53:47 2007 -0400
Unionfs: xattr copyup fixes
Rewrote xattr copyup code more cleanly; documented it better; eliminate one
possible leak in error path; and ignore another impossible copyup-time error
which caused fanout invariant violations under memory-pressure conditions.
Don't use vmalloc when allocating xattr buffers, as the VFS no longer does
so (just use kmalloc). Eliminate unionfs_xattr_free which is now just plain
kfree.
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit f3b395b45b5f1d15c41a4558f31c0fd38792e12d
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Tue Jul 31 03:33:24 2007 -0400
Unionfs: fixes to cache-coherency checking code
Under memory pressure, in_newer_lower could be called on uninitialized
dentries or inodes. So return 0 safely in that case (rather than oops).
This is OK because is_newer_lower will be called again on the same object(s)
and cache-coherency will be validated and maintained then.
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit b9deea877a2a0e44eb6a70fd1e2323c9f6e0e0cb
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Tue Jul 31 03:29:50 2007 -0400
Unionfs: mmap fixes to unionfs_writepage
This patch fixes hangs when calling sync(2) on memory-pressured systems.
Call find_lock_page instead of grab_cache_page. We used to call
grab_cache_page(), but that was unnecessary as it would have tried to create
a new lower page if it didn't exist, leading to deadlocks (esp. under
memory-pressure conditions, when it is really a bad idea to *consume* more
memory). Instead, we assume the lower page exists, and if we can find it,
then we ->writepage on it; if we can't find it, then it couldn't have
disappeared unless the kernel already flushed it, in which case we're still
OK. This is especially correct if wbc->sync_mode is WB_SYNC_NONE (as per
Documentation/filesystems/vfs.txt). If we can't flush our page because we
can't find a lower page, then at least we re-mark our page as dirty, and
return AOP_WRITEPAGE_ACTIVATE as the VFS expects us to. (Note, if in the
future it'd turn out that we have to find a lower page no matter what, then
we'd have to resort to RAIF's page pointer flipping trick.)
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 157bec38ff6b6cb101813a714d388b2e59c692cc
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Thu Jul 26 00:04:58 2007 -0400
Unionfs: bugfix when mounting readonly exported NFS volumes (was: nfsro)
When stacking on top of readonly exported NFS volumes, which are mounted
locally read-write, attempting to create a new file yields the proper EROFS.
But attempting to modify an existing file returns an EACCES, which
interferes with unionfs's copyup policy: only EROFS triggers a copyup,
whereas EACCES does not (and shouldn't -- that'd be a security hole). The
old unionfs 1.x attempted to workaround this EACCES condition by supporting
a special unionfs mount option called 'nfsro'; support for this option was
left in the latest unionfs 2.0, but the mount option was not made available
until we could properly investigate this issue with the latest NFS code.
This patch removes all remnants of this 'nfsro' support. It is no longer
needed. Instead, users can use the existing per-branch 'ro' unionfs mount
option, which would properly return the appropriate status conditions back
from unionfs_permission. These return conditions result in a copyup if and
only if needed, even for readonly exported NFS volumes. In effect, unionfs
per-branch 'ro' option now simulates a true readonly localhost mount.
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 1b47f8082d6aba84b951713a361eef5f70b6b0a6
Author: Adrian Bunk <bunk at stusta.de>
Date: Mon Jul 2 14:27:57 2007 -0400
[PATCH] unionfs: make functions static
This patch makes some needlessly global functions static.
Signed-off-by: Adrian Bunk <bunk at stusta.de>
Signed-off-by: Josef 'Jeff' Sipek <jsipek at cs.sunysb.edu>
commit 6486f1063c052b39513fb98e60a18953aacf18db
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Mon Jul 23 03:13:01 2007 -0400
Unionfs: pass nameidata intent information to lower level file systems
As of 2.6.23-rc1, nfs2 and nfs3, like nfs4 before them, begin relying on the
struct nameidata and especially the intent information, which is passed to
vfs_create() and others. So, as of now, unionfs properly creates and passes
that intent data to the lower level file system. Currently supported are
LOOKUP_CREATE open intents. Others can be supported in the future
incrementally.
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 0d4be4e8eae95728c1da30700c259a16007020bc
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Sun Jul 22 21:53:49 2007 -0400
Unionfs: kmem_cache_create doesn't take a dtor argument any longer
Porting unionfs to 2.6.23-rc1
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 3ef147f50c15cad428358882dbdc68d248aae4e3
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Sun Jul 22 01:10:45 2007 -0400
Unionfs: ensure cache coherency in unionfs_fsync/fasync
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 040707d3fec11bb10ec773c41609fe9566bc48d1
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Sat Jul 21 23:56:16 2007 -0400
Unionfs: implement native unionfs_fsync/unionfs_fasync methods
Unionfs is not a block-based file system, but it has to work with both
block-based file systems and non-block-based ones (i.e., when
CONFIG_BLOCK=n). We used to define our ->fsync method to file_fsync, but
that's wrong because file_fsync partially depends on CONFIG_BLOCK=y. And we
didn't define an fasync method: now we have both. Moreover, at best,
file_fsync would have caused unionfs to sync up one lower branch---but as a
fanout file system, we need to sync up all valid lower branches.
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
Conflicts:
fs/unionfs/file.c
commit 74bfff13dcbd1faf4598fc2b5d2a5392cdfdcad4
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Sat Jul 21 20:22:38 2007 -0400
Unionfs: small documentation fix to usage.txt
Reported by Daniel Farrugia.
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit a3fcb5045e08e45510af183f2838c084c8d62d46
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Sat Jul 21 02:44:32 2007 -0400
Unionfs: mmap fixes to ->writepage/readpage/sync_page
unionfs_writepage: handle true errors differently from
AOP_WRITEPAGE_ACTIVATE conditions returned by lower file systems (such as
tmpfs).
unionfs_readpage: call flush_dcache_page as required.
unionfs_sync_page: don't call grab_cache_page to get the lower page, because
that function does too much and could lead to deadlocks. Instead, call the
lighter-weight find_lock_page.
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 33dc029b7fee9eb4763130a62a1f3394d0e478c1
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Sat Jul 21 02:38:14 2007 -0400
Unionfs: branch-management bugfix to unionfs_file_revalidate
If we re-opened the file on a different branch than the original one, and
only if this was due to a new branch inserted, then update the mnt counts of
the old and new branches accordingly.
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit de1dfe64b4ba1d3cd090278e5acf298b31bb85a4
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Tue Jul 17 03:18:25 2007 -0400
Unionfs: cleanup: break line longer than 80 chars
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 80e9a7347605877c89d5f01e532504f4a821e831
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Tue Jul 17 02:58:15 2007 -0400
Unionfs: fix minor typo in revalidate_chain comment
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit a7c80e99a8532ca03029414e3d7021a03ac76c37
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Mon Jul 16 23:56:26 2007 -0400
Unionfs: bugfix: don't call branchget() until dentry_open succeeded
If dentry_open fails, we incorrectly have incremented our branch counts
which would prevent unionfs from being unmounted (EBUSY).
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit c98f9d6afa974aac9440805006d478a651794bb8
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Mon Jul 16 23:54:11 2007 -0400
Unionfs: branch-management bug-fix to lower mnt counts
When we revalidate opened files, the files may point to a different set of
files on the lower branches: this could happen especially if we insert a new
leftmost branch which happens to have duplicate file names of already-open
files in lower-priority branches. In this case, update the mnt counts of
the old and new branches which hold the file accordingly. Without this fix,
the mntcnt of one branch is going to be one too high; and another will be
one too low.
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit bd343ca5921ffa4a94b34b9293a6e99bdb77eb3e
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Mon Jul 16 23:45:46 2007 -0400
Unionfs: use igrab instead of atomic_inc inode refcnt
In branch management code, use igrab() which is better than directly
incrementing the lower inode reference count.
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 951bb21771c9242b6b57c9946980849df3515a08
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Mon Jul 16 23:42:55 2007 -0400
Unionfs: cache-coherency: update times of root inode after branch management
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit aa7c42e134520bb2f1c0290b10c40b8d0bbf2819
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Mon Jul 16 23:40:07 2007 -0400
Unionfs: debugging: don't oops if sb->s_root is NULL
If we're calling show_branch_counts very early during mount or late during
unmount, don't oops if the s_root is already NULL.
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit e7238a8f4c95389eb0630dfdf28871a2e016466a
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Mon Jul 16 23:38:30 2007 -0400
Unionfs: debugging: show inode reference counts for all branches
Another useful utility function for debugging, to show the inode refcnt's
of all lower inodes.
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 35ec8458b03c35d67ebe92f1840ea690e751325f
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Mon Jul 16 23:35:19 2007 -0400
Unionfs: fix small typo in comment
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit fa54ab40a06c073c6c972dff850d3059f45acc2f
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Sat Jul 14 03:25:02 2007 -0400
Unionfs: bugfix -- set copied up open file mode to read and write
When we copyup a file, we used to set the new file's open mode to write
only. But we need read permission too. We need write permission because
we're creating a new file; and we need read permission because the original
file had to have been readable. If we don't set the new files permission to
BOTH read and write, we get -EBADF when trying calling vfs_read/vfs_write on
a copied up file. (This fix is somewhat related to unionfs_readpage fixes
that use vfs_read instead of calling the lower readpage.)
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 92a93b62b4b558b7e9e30e7c34181d4db2fa29e5
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Sat Jul 14 03:36:15 2007 -0400
Unionfs: rewrite do_unionfs_readpage to use vfs_read (bugfix)
In do_unionfs_readpage, we used to call the lower file system's ->readpage.
However, some file systems (e.g., tmpfs) don't implement ->readpage, causing
a NULL pointer dereference under certain conditions, especially under severe
memory pressure. This patch reimplements do_unionfs_readpage using
vfs_read, which makes the code simpler and more reliable, as we depend on
the VFS to do most of the hard work (even if this implementation might be a
bit slower).
This fix also makes sense because it makes the mmap code in unionfs more
symmetric with unionfs_commit_write --- which uses vfs_write().
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit a11baec09be83541406ddf633aa782f76810dd24
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Fri Jul 13 02:40:31 2007 -0400
Unionfs: fix minor typo in a comment
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 0658cba93c45a25b635c77548a21318f25cffd15
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Wed Jul 11 16:13:07 2007 -0400
Unionfs: use the splice_read file method instead of sendfile
In 2.6.23 (prior to rc1), sendfile was obsoleted in favor of splice_read.
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit dcfb6841360d55bd34e6c03d279806061f2dafdc
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Mon Jul 9 20:19:08 2007 -0400
unionfs: better handling when copying up permissions
When we copyup a file, directory, or symlink, we may be copying up from one
file system type to another. The destination file system may not support
all of the features of the source file system, and the differences in
support may be minor. For example jffs2 doesn't allow one to chmod a
symlink (and it returns a -EOPNOTSUPP). So we ignore such harmless errors,
rather than propagating them up, which results in copyup errors and errors
returned back to users.
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 5b6873f8a3bab4fd4fed466d2e24bde8bf77a856
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Mon Jul 9 20:14:41 2007 -0400
Unionfs: better error handling in rename code when copyups are involved
First, rewrite code slightly and document it better to explain why we appear
to ignore copyup errors (because we try the next branch to the left).
Second, change a BUG_ON to a printk(KERN_ERR), because a mild failure to
copyup a file should not cause an oops. For example, some file systems
don't support UIDs/GIDs (e.g., VFAT) and others don't allow you to chmod a
symlink (e.g., jffs2), possibly resulting in mild copyup failures; that
shouldn't be considered so severe as to cause an oops.
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 67952f7b05c76597acc269d8386804d6447e22a8
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Sat Jul 7 21:31:28 2007 -0400
Unionfs: bugfix when renaming symlinks on readonly branches
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit ce9be7e45499beca9d9b3a0d05c4888a46f91ff9
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Tue Jul 3 09:14:39 2007 -0400
Unionfs: prevent deadlock with branch-management code.
Don't grab the superblock read-lock in unionfs_permission, which prevents a
deadlock with the branch-management "add branch" code (which grabbed the
write lock). It is safe to not grab the read lock here, because even with
branch management taking place, there is no chance that unionfs_permission,
or anything it calls, will use stale branch information.
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit f77ad769e9a2829fbc21b2c258f82ec0ba17e102
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Fri Jun 29 02:33:14 2007 -0400
Unionfs: rename file->f_dentry references to file->f_path.dentry
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 15f91878f5f33b02320b9e44927e62c27d6f8b49
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Fri Jun 29 02:02:42 2007 -0400
Unionfs: improved comment above unionfs_follow_link
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit bdb6fb050b62ec401535d64e053cd30c0e87b2b8
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Fri Jun 29 02:00:24 2007 -0400
Unionfs: Change the semantics of sb info's rwsem
This rw semaphore is used to make sure that a branch management
operation...
1) will not begin before all currently in-flight operations complete
2) any new operations do not execute until the currently running branch
management operation completes
Reworked the patch a bit, added comments, and fixed some bugs, from the
version originally committed into the master branch.
TODO: rename the functions unionfs_{read,write}_{,un}lock() to something
more descriptive.
Signed-off-by: Josef 'Jeff' Sipek <jsipek at cs.sunysb.edu>
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit e818ed82edf5b5340e756b37a60911e71d3ad34f
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Fri Jun 29 00:45:47 2007 -0400
Unionfs: Remove superfluous check for NULL pointer
Since we use containers and the struct inode is _inside_ the
unionfs_inode_info structure, UNIONFS_I will always (given a non-NULL inode
pointer), return a valid non-NULL pointer.
Signed-off-by: Josef 'Jeff' Sipek <jsipek at cs.sunysb.edu>
Conflicts:
fs/unionfs/super.c
commit b81e25f1a8a3d58fb7346e6c8ad5cee920cb351f
Author: Josef 'Jeff' Sipek <jsipek at cs.sunysb.edu>
Date: Fri Jun 8 10:58:22 2007 -0400
Unionfs: Change free_dentry_private_info to take a struct dentry
This makes it more symmetric with new_dentry_private_info.
Signed-off-by: Josef 'Jeff' Sipek <jsipek at cs.sunysb.edu>
commit 81d9cfc26283306197f9d8d73f0b55d0350b4dc2
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Fri Jun 29 00:36:08 2007 -0400
Unionfs: Cleanup new_dentry_private_data
Signed-off-by: Josef 'Jeff' Sipek <jsipek at cs.sunysb.edu>
Conflicts:
fs/unionfs/lookup.c
commit e6186fa4a3d2f0b76c218c55eaf72eb097e99bd9
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Sun Jun 17 22:39:38 2007 -0400
Unionfs: document cache-coherency design and implementation
Document our cache-coherency design, implementation; also mention alternate
designs and a couple of limitations which might be overcome by special
kernel support at the VFS/MM levels. Now that cache-coherency is working,
remove the now-obsolete older discussion of temporary workarounds.
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 4a6608dbf21b0f36f578a8f2d504b4545c7521b7
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Sun Jun 17 22:39:05 2007 -0400
Unionfs: cache-coherency calls to maintain the time invariants
This patch represents several types of related changes. First, we invoke
functions to synchronize the upper and lower times as and when needed. Many
of these were bug fixes which were discovered during the development of the
cache-coherency code. That is, Unionfs itself wasn't maintaining
appropriate
times in some places, which if not fixed would have been detected by the
invariant-checking code as a false positive (incorrectly considered as if a
user modified the lower objects directly).
Second, we do not call invariant-validation functions (unionfs_check_file,
unionfs_check_dentry, etc.) until *after* we've revalidated them. Otherwise
we produced false positives.
Third, we pass a flag "willwrite" to __unionfs_d_revalidate_chain to tell it
to purge data pages if the inode lower times appear to be newer.
See Documentation/filesystems/unionfs/concepts.txt under the "Cache
Coherency" section for more details of this design and implementation.
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 51b38220d434984789d4d2b81a720f6d015817cb
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Sun Jun 17 22:37:54 2007 -0400
Unionfs: core cache-coherency code
This represents the core of the cache-coherency code, the code which
maintains time-based invariants; the lower objects should never be newer
than the upper Unionfs objects. If they are newer, then it means that a
user has modified the lower Unionfs branches directly. If so, then we have
to revalidate our objects by rebuilding them, and possibly discard any stale
data or meta-data. See Documentation/filesystems/unionfs/concepts.txt under
the "Cache Coherency" section for more details of this design and
implementation.
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit c078f162083aa573aaa977131ae637d93c65184a
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Sun Jun 17 22:36:55 2007 -0400
Unionfs: introduce two functions to maintain time invariants
A new function unionfs_copy_attr_times to maintain the inode time invariants
as per the Unionfs design (i.e., lower times should never be newer than our
times), as documented in Documentation/filesystems/unionfs/concepts.txt.
The second function, unionfs_copy_attr_all, is the unionfs-specific function
to copy all attributes: it uses the special Unionfs handling of hard-links
(via unionfs_get_nlinks) and it uses the special a/c/mtime handling (via
unionfs_copy_attr_times). This second function is the special
fanout-version of fsstack_copy_attr_all, which was simplified for
linear-stack stackable file systems.
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 410b3ad740ca1c7c7bbfabf3846067f6666793cc
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Sun Jun 17 22:36:03 2007 -0400
Unionfs: prototype and location change for unionfs_get_nlinks
Change prototype of unionfs_get_nlinks to take a const inode. Also move
extern for unionfs_get_nlinks so it can be refereed to in other Unionfs
header files.
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 53846f61d9b761167080013441f396d559ce4206
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Sun Jun 17 22:35:25 2007 -0400
ecryptfs: update to new API of fsstack_copy_attr_all
Remove obsolete third argument to fsstack_copy_attr_all which was always
NULL for ecryptfs.
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit c26abd3b3c49d9a04d2cd376e2aaf9495e996940
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Sun Jun 17 22:34:47 2007 -0400
fs_stack: simplify generic attribute-copying function
Remove special get_nlinks callback from fsstack_copy_attr_all, because the
callback was only used by Unionfs (and always used by Unionfs). Unionfs now
needs a more complex version of fsstack_copy_attr_all, with two callbacks:
therefore it's easier to simplify this method for simple linear-stacking
stackable file system, and introduce a more complex fan-out version of it
for Unionfs.
This is an API change which requires that every stackable file system in the
kernel be updated to reflect that (currently only eCryptfs).
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit e1cea99c859dcb4f07d5f4151ad8569cf29ec03c
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Sun Jun 17 22:33:56 2007 -0400
Unionfs: m/c/atime invariant checking debugging code
Add checks to verify that lower inode times are not newer than our own inode
times. Introduce two useful utility debugging functions to print inode
times.
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 7226dee1bbd7416494ea79d9f94b4488818e663f
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Sun Jun 17 22:29:40 2007 -0400
Unionfs: bugfix in debugging infrastructure
Off-by-one bug fixed in range checking for lower directories.
Ensure that we PRINT_CALLER before an additional debug message.
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 9f33a375e644e255078118a5d201d43e2f21042d
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Mon Jun 11 12:48:29 2007 -0400
Cache coherency: resync unionfs data/meta-data when lower files change
Whenever we revalidate a file or dentry, we check to see if any of the lower
inodes have changed (new mtime/ctime). If so, we revalidate the upper
unionfs objects. This method "works" in that as long as a user process will
have caused unionfs to be called, directly or indirectly, even to just do
->d_revalidate, then we will have purged the current unionfs data and the
process will see the new data. For example, a process that continually
re-reads the same file's data will see the NEW data as soon as the lower
file had changed, upon the next read(2) syscall. This also works for
meta-data changes which change the ctime (chmod, chown, chgrp, etc).
However, this doesn't work when the process re-reads the file's data via
mmap and the data was already read before via mmap: once we respond to
->readpage(s), then the kernel maps the page into the process's address
space and there doesn't appear to be a way to force the kernel to invalidate
those pages/mappings, and force the process to re-issue ->readpage. Note:
only pages that have already been readpage'ed are not updated; any other
pages which unionfs's ->readpage would be called on, WILL get the updated
data. If there's a way to invalidate active mappings and force a
->readpage, let us know please (invalidate_inode_pages2 doesn't do the
trick).
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 71afb20079196b71d8f041c9c8513ddfec9451dc
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Mon Jun 11 10:52:21 2007 -0400
revert changes to new_dentry_private_data and document it
Revert bad changes to this function, but this time explain better its precise
semantics. It can take a dentry whose private unionfs 'info' node exists or
not, and it should allocate and un/lock it only if it's NULL.
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 81147753ed4c2d1d2c3c6fe00eb1db46dd2e4a8f
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Sun Jun 10 19:04:30 2007 -0400
cleanup: convert all instances of "hidden" to "lower".
The unionfs code contained many references to symbols whose name had the
string "hidden" in it, referring to, for example, a "hidden inode" below the
unionfs inode. The term "hidden" was there for historical reasons and was a
misnomer, implying that the objects at unionfs's lower branches were somehow
hidden or unavailable. This was not just incorrect, but confusing. The
lower objects are just that: lower. They are not hidden from users. In
fact, users can 'cd' to lower branches and manipulate files directly there.
This long patch renames all such mis-named symbols, and re-indents the code
as needed to comply with coding standards.
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 869b2a5fcb9b76bd6e86d8fed21a98ee3999082d
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Sun Jun 10 17:55:23 2007 -0400
Fix section marker in header file:
WARNING: fs/unionfs/unionfs.o(.init.text+0x56): Section mismatch: reference to .exit.text:stop_sioq (between 'init_module' and 'init_sioq')
Signed-off-by: Randy Dunlap <randy.dunlap at oracle.com>
Signed-off-by: Josef 'Jeff' Sipek <jsipek at cs.sunysb.edu>
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 97a7c82526a830b95a17d448630f9553b80be1b8
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Sun Jun 10 17:51:42 2007 -0400
minor indentation correction
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 7e4adf005aa4311135a9e465967e233fe0096f6e
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Wed Jun 6 01:20:15 2007 -0400
bugfix: add MODULE_LICENSE to mtdsuper module so it loads
This is a temp fix in rc4. Also reported this bug to MTD maintainer.
commit 72b6e7adec0b57088ebff27a43ee3f9708a348eb
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Tue Jun 5 21:58:07 2007 -0400
bugfix: properly reset lower inode start/end range
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 92ebc0f2ab1816e93576647f1725b1197d94300d
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Sun Jun 3 02:27:37 2007 -0400
cleanup: rewrite new_dentry_private data more simply
Also remove unnecessary variables and statements.
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 348a9bd604fcb27b3870d97c6562e9844525023d
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Sun Jun 3 02:26:36 2007 -0400
bugfix: remove extra superblock rwsem unlock call
This also makes the code more symmetric: the same code which locks also
unlocks the rwsem.
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 724f13d7625ac55ef4447a3fb360a11bc05b496a
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Fri Jun 1 00:47:20 2007 -0400
remove unnecessary comment
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 869052640b61127b731dbfccf8474dcb99bcd208
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Fri Jun 1 00:01:03 2007 -0400
properly format a multi line comment
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 08762a1609ca815f5f4bbb329808c8c27dffd1d7
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Thu May 31 23:34:59 2007 -0400
reformat all lines longer than 80 characters
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 2ca22e26c247d4811f2c54bec6ad0449921e7676
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Thu May 31 23:13:14 2007 -0400
debugging: indent code properly and cleanups
Also make PRINT_CALLER look like a function.
Fix one small bug in __show_branch_counts.
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 70093f402712a0683070901e014d6ef5cb3fe8bb
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Thu May 31 22:32:10 2007 -0400
cleanup: reformat all lines longer than 80 characters
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit af4d029506953c79b31fd262c57974ba4d2241b6
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Thu May 31 15:53:28 2007 -0400
spell check all strings and comments
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 524a36b1aaa9afb958f2f8afae9131d72fa3fa2b
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Thu May 31 15:30:55 2007 -0400
cleanup: ensure proper comment on every "#endif"
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit e2e746fc618469e90292c777d9981a3826026682
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Wed May 30 23:34:23 2007 -0400
Revert "Unionfs: Cleanup locking in new_dentry_private_data"
This reverts commit ad2d6a5f5e0501ecf704bf2c748e9818ee8e019b.
Conflicts:
fs/unionfs/lookup.c
commit a855ca7e3d8f6f1d14411525050e2c1d169003f3
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Wed May 30 20:14:07 2007 -0400
bugfix: ensure dentry/inode/mnt validity after a successful ioctl
We call unionfs_partial_lookup in our queryfile ioctl method, so we can find
all instances of a lower object to report back to a suer. This can violate
the fanout invariants (e.g., a regular file should have only one lower
object active at a time). So we have to re-establish the invariants on the
lower dentries, inodes, and mnts.
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 3e8499172b6ed48ae60d04f49cab820948027d4c
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Wed May 30 20:09:07 2007 -0400
bugfix: release superblock lock at end of ioctl method
Signed-off-by: Josef 'Jeff' Sipek <jsipek at cs.sunysb.edu>
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 870a799aecdabd3f1231733b0efb6160b6547fe4
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Wed May 30 01:02:20 2007 -0400
bug fixes: revalidate dentries passed to all inode/super operations
Be sure to properly revalidate all dentry chains passed to all inode and
super_block operations. Remove the older BUG_ON test is_valid_dentry().
This should help improve cache-coherency.
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 48844d0b0dff174bc536c1aad9a6e722dc2e7236
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Tue May 29 22:09:59 2007 -0400
code consistency: ensure that every #endif has a matching comment
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit e2e535353fc53c8937318d7de2135cb28e6ba44e
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Mon May 28 23:24:58 2007 -0400
invariants: don't complain if no lower dentry of a deleted dentry
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 1063acf1771bd5e4557128f1ec00d2fe683e3197
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Mon May 28 19:47:35 2007 -0400
invariants: don't complain about directories with some NULL lower objects
Directories can have NULL lower objects in between start/end, but NOT if at
the start/end range. We cannot verify that this dentry is a type=DIR,
because it may already be a negative dentry. But if dbstart is greater than
dbend, we know that this couldn't have been a regular file: it had to have
been a directory. In that case, don't complain about NULL lower objects in
in between start/end.
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 652f0b4637b14fec241fdf862d0143a8b74655c7
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Mon May 28 19:45:45 2007 -0400
Revert "invariants: don't complain about directories with some NULL lower objects"
This reverts commit 9d8ee83d478be30faf351af7628066ec6658efb5.
commit feb97b071fd4b506dcbc90016fe0bb1c035d5b44
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Mon May 28 19:42:20 2007 -0400
invariants: don't complain about directories with some NULL lower objects
Directories can have NULL lower objects in between start/end, but NOT if at
the start/end range. We cannot verify that this dentry is a type=DIR,
because it may already be a negative dentry. But if dbstart is greater than
dbend, we know that this couldn't have been a regular file: it had to have
been a directory. In that case, don't complain about NULL lower objects in
in between start/end.
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit fc9dc195a25d92c1809601447cb6eceec7a5d426
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Mon May 28 19:39:44 2007 -0400
cleanup: rewrite unionfs_partial_lookup more cleanly and add comments
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit aeac34a461b63ea45f624a54b175dc0fc2601302
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Mon May 28 19:38:14 2007 -0400
bug fix: prevent null mntget warning messages in unionfs_lookup_backend
Don't try to mntget a lower mnt at a point where the lower mnts don't yet
exist (the callers will have them later on). Instead, get the lower mnt of
the sb->s_root.
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit f678c3abc13fedd7c2cf30e3680162ff49a25717
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Mon May 28 19:36:02 2007 -0400
documentation: expand comments to unionfs_lookup_backend
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 1c4607664204e5855abb9d7ac784ada28f2799a8
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Mon May 28 19:23:42 2007 -0400
cleanup: remove unnecessary call to inherit_mnt
Our unionfs_lookup doesn't need to call inherit_mnt: the lower mnts will be
correct here (but not if other methods such as unionfs_rename call our
lookup_backend helper function directly).
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit a8e2e078cb7fccb38943ba7a5f2c598ee81e3604
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Mon May 28 19:21:21 2007 -0400
bug fix: don't warn if trying to mntput a "negative" union object
In unionfs_d_release, we may get negative dentries which don't have a lower
mnt. In that case, don't print a warning message from unionfs_mntput about
trying to put a NULL mnt.
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit e393fb08d8d13d0f8abb04ab6442a7802772f69a
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Mon May 28 19:18:45 2007 -0400
bug fix: get lower mnt from root dentry instead of lower dentry
While copying-up a file, the union object hasn't been fully formed yet, so
we don't have all the lower dentries/mnts to use (the caller will have them
later on). Therefore, we should use the sb->s_root's lower mnt here. This
fixes a "NULL mnt" warning message that came from unionfs_mntget.
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 0846693f228838b26fa85edacd0d1276d14d9337
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Fri May 25 22:36:13 2007 -0400
Unionfs: allow users to override Makefile options in fs/unionfs/local.mk
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 23bb7089bdc11d51f971c4b61127f3d71ff76808
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Fri May 25 22:01:03 2007 -0400
documentation: better comment in branch_id_to_idx
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 6debc9db28dcd19ff91902811b9309cb7fff20c9
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Fri May 25 17:01:00 2007 -0400
bug fix: catch bad use of dirs= options (extra ':' separators)
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit b5a6b010cff42e47efb763768600806592798997
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Fri May 25 16:20:36 2007 -0400
unionfs: merge find_new_branch_index and branch_id_to_idx into one function
Useful code cleanup and consolidation between the ODF code and non-ODF code.
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 0c019440dbae33788a119fcca25cabb8192020c7
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Fri May 25 15:47:44 2007 -0400
unionfs: minor cleanup and better commenting in new_dentry_private_data
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 9e59a509c513d43b0fb2c8a109b100acf3384ad4
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Fri May 25 15:45:30 2007 -0400
Unionfs: Cleanup locking in new_dentry_private_data
Signed-off-by: Josef 'Jeff' Sipek <jsipek at cs.sunysb.edu>
Conflicts:
fs/unionfs/lookup.c
commit b30cc929d9764f1645100bfee21c220b23eb808d
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Fri May 25 15:37:38 2007 -0400
bugfix: prevent null-deref oops if lower f/s is NFS (mmap writes)
This is a workaround fora deficiency of the linux MM layer, which doesn't
allow clean coordination between upper and lower pages in stackable layers.
We prevent an oops, but the cost is that we're not able to implement
writepages cleanly, not can we call the lower file system's writepages.
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 9df6cfefce95159540f382c65ceb0e418e71484e
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Thu May 24 00:08:03 2007 -0400
cleanup: use krealloc instead of open-coding it with kmalloc/kfree/memcpy
commit 16979aa1f8538b784cebf715063a0b3947802a27
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Wed May 23 21:27:58 2007 -0400
bugfix: prevent a NULL ptr deref if branch is nfs and using mmap writes
By some strange condition, the VFS can pass our unionfs_writepage a
writeback_control structure which, if passed as is to the lower ->writepage
-- here nfs_writepage, triggers a NULL ptr deref in NFS. This fix works
around this issue, and results in a successfully written mmaped file.
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 1344039aec46038cfb826e2cd12600564b53736d
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Wed May 23 21:26:01 2007 -0400
bugfix: handle lower file systems that do not support writeable mappings
File systems such as jffs2 (tested in 2.6.22-rc22) do not have a
->writepage. Make sure unionfs detects that conditions and returns EINVAL
when a user tries to mmap such a file with VM_WRITE.
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 680fc5aee91b0acadc4187912d95f9664fa9f6cf
Author: Erez Zadok <ezk at bigvaio.(none)>
Date: Tue May 22 23:53:25 2007 -0400
documentation: comment to ODF developers to address
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 0cb80df88d7c84f4b2a7bf7624e41511811268f2
Author: Erez Zadok <ezk at bigvaio.(none)>
Date: Tue May 22 23:52:12 2007 -0400
bug fix: set lower inodes correctly after branch management succeeds
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit f6c75cfa4b142befcd83a986d645cfa0605f45e1
Author: Erez Zadok <ezk at bigvaio.(none)>
Date: Tue May 22 23:50:44 2007 -0400
bug fix: prevent self deadlock with remount code in pivot_root scenarios
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 720ca0d1812a2da8c63937089b4f803ced949a85
Author: Erez Zadok <ezk at bigvaio.(none)>
Date: Tue May 22 23:49:35 2007 -0400
debugging: test for freed (0x5a) inodes
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 3a93b32a6891bf355710fd52215d4f527c2827bd
Author: Erez Zadok <ezk at bigvaio.(none)>
Date: Tue May 22 18:04:14 2007 -0400
bugfix: statfs lower file system properly
Get the correct lower dentry to use to statfs the first branch (always), now
works with disk-based as well as network file systems. Also document the
code better.
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 310e8cf5aa848acc8a8c9f8e15c7eb6f8ddca1f8
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Sat May 19 21:11:22 2007 -0400
Add Erez Zadok to maintainers list
commit e63dbd16e3dc8e0e500edfac8c3842d2a4e3168b
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Sat May 19 21:07:29 2007 -0400
add standard copyright comment to linux/union_fs.h
commit 21d75131bd7792944cd71c7060e3799d30126943
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Sat May 19 20:44:25 2007 -0400
d_splice bugfix: update dentry in our lookup if needed.
commit 352e1cfc2c8a8a874d126846b0c21faac2fbaa9e
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Sat May 19 19:59:13 2007 -0400
mmap: file revalidation and fanout invariant validation
Added the newer checks to file revalidation and fanout invariants to the
newly merged mmap code. Also minor mmap related comments added.
commit 9943dfd221d8e389b4900cd4fa518bc13976910b
Author: Yiannis Pericleous <yiannos at agora2.fsl.cs.sunysb.edu>
Date: Sat May 19 15:23:22 2007 -0400
mmap: sync_page bug, call sync_page on lower page, not unionfs page
commit 102189193e604a6fabf6d84ba19075441b51ef32
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Sat May 19 19:17:30 2007 -0400
mmap: also revalidate file passed to unionfs_release
Conflicts:
fs/unionfs/commonfops.c
commit 0158b325057bfa581a60deb4352b2147bfba1368
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Sat May 5 20:41:46 2007 -0400
mmap: update atime upon successful file reading (via mmap or otherwise)
commit 55fe9cfa13e6089659bfd8e2003b023b9ed02a6f
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Sat May 5 19:27:33 2007 -0400
mmap: proper locking to interoperate with branch-management code
Include proper read un/lock calls as in file.c. Make unionfs_do_readpage
static as no one else should call this helper function.
commit 1086f9a94308986e414eacff4fcf285a781effa6
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Sat May 5 19:15:28 2007 -0400
mmap: remove unnecessary unionfs_bmap method
Unionfs is not a block-based file system, so it should not define ->bmap.
commit e660641e43aa025bac28e70f4cde79a2a5375334
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Sat May 5 19:10:00 2007 -0400
mmap: trivial sendfile support
commit e9c6ceff3f5d8fa71785916e0b7feadb596fb71e
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Sat May 19 19:10:42 2007 -0400
mmap: minor code and comment reformatting
Conflicts:
fs/unionfs/file.c
commit 3eec1a470a136f2c13149b69e4b81668e21424e0
Author: Yiannis Pericleous <yiannos at louie.fsl.cs.sunysb.edu>
Date: Tue May 1 19:11:53 2007 -0400
mmap: #if 0 unneeded code instead of commenting it out
commit 0dd2b281fcd742e1af334248468a54b88f0710fd
Author: Yiannis Pericleous <yiannos at louie.fsl.cs.sunysb.edu>
Date: Tue May 1 15:18:39 2007 -0400
mmap: read upper file instead of lower file
dont touch atimes on reads
commit 91126b4ababea90f65da1b5dc89a01449f0cb2ac
Author: Yiannis Pericleous <yiannos at louie.fsl.cs.sunysb.edu>
Date: Sat Apr 28 22:04:54 2007 -0400
mmap: coding style: reformated a line longer than 80 chars
commit 5ad357ffd1af8ab88b96a46994c2d941bdad9547
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Sat Apr 28 21:04:05 2007 -0400
mmap: remove defunct comments
commit dc82aa997d78186d864509101e808b0f07f77003
Author: Yiannis Pericleous <yiannos at louie.fsl.cs.sunysb.edu>
Date: Fri Apr 27 18:13:29 2007 -0400
mmap: file revalidation
commit 74a7a6a1d623fc5490086d3fd65d2ba4656c23ae
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Sat May 19 19:00:51 2007 -0400
mmap: applied main mmap patch
Resolved the following conflicts:
Conflicts:
fs/unionfs/Makefile
fs/unionfs/file.c
commit e76bc1a3aee681e3575125ccf4f9b93459b96bce
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Sat May 19 18:22:53 2007 -0400
bugfix: fixed interpose to check if d_splice_alias returns a dentry
Also in unionfs_interpose, ensure that this new dentry's private data is
correct. unionfs_interpose now returns a dentry if d_splice_alias has
returned a dentry. (This is a reimplementation of the same fix from the ODF
code base.)
commit 3ee14a9c4586177984af83ffe9294c8af0db60f8
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Sat May 19 17:14:27 2007 -0400
debug: remove unnecessarily verbose debugging printk's
commit e522aa87f3642dd069581d2f5e49bc4ba420a0f3
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Sat May 19 16:40:16 2007 -0400
cleanup: consistent printk messages
commit ebc5f8a9ff9c6ac8dfe77cd1b5376a7380deee3c
Author: Erez Zadok <ezk at bigvaio.(none)>
Date: Fri May 18 03:41:05 2007 -0400
cleanup: eliminate wrapper function create_parents
Eliminate simple wrapper function create_parents which trivially called
create_parents_named with one more arg derived from the caller. Instead,
remove the wrapper, rename create_parents_named to create_parents, and make
everyone call create_parents directly. This clarifies the code a bit more
and saves a bit on stack space.
commit fd7a554b11ed82a8567c753db73d62698eb4ab84
Author: Erez Zadok <ezk at bigvaio.(none)>
Date: Fri May 18 03:27:02 2007 -0400
cleanup: eliminate wrapper function copyup_dentry
Eliminate simple wrapper function copyup_dentry which trivially called
copyup_named_dentry with 2 more args derived from the caller. Instead,
remove the wrapper, rename copyup_named_dentry to copyup_dentry, and make
everyone call copyup_dentry directly. This clarifies the code a bit more
and saves a bit on stack space.
commit 190562398637390774b06dad603ac787d4c21657
Author: Erez Zadok <ezk at bigvaio.(none)>
Date: Fri May 18 03:07:37 2007 -0400
cleanup: rewrite do_delayed_copyup more cleanly and clearly
commit bd805109c8a0fa6e06b42417e91204f9ec7c734d
Author: Erez Zadok <ezk at bigvaio.(none)>
Date: Fri May 18 02:18:44 2007 -0400
debugging: small fix to Makefile to correct #define typo
commit 4bb766b075eb376f9ba61769f35933e208de0964
Author: Erez Zadok <ezk at bigvaio.(none)>
Date: Fri May 18 01:56:08 2007 -0400
cleanup: remove unnecessary macro used in only one place
Remove the UNIONFS_TMPNAM_LEN macro and just use the actual length of the
string file name in question, which is more efficient (and correct).
commit 4b0a058c27cce0ee7a38329bf5ea458979787edc
Author: Erez Zadok <ezk at bigvaio.(none)>
Date: Fri May 18 01:53:12 2007 -0400
bug fix: don't revalidate dropped dentries
This fixes a harmless but annoying message that unionfs prints if a dropped
dentry is being revalidated, which could happen if you unlink open files.
commit 8ed4a49cc5a03ba3a97e8a89e9f00781bef9af6d
Author: Erez Zadok <ezk at bigvaio.(none)>
Date: Fri May 18 01:45:18 2007 -0400
bug fix: retry lookup for different silly-renamed files
When we have to copyup an open-but-unlinked file, we have to give it a
temporary name, similar to NFS's silly-renamed files. So we generate
temporary file names until we find one that doesn't exist, and use it. The
code had a bug where if the silly-renamed file name already existed, Unionfs
would oops upon copyup to that temp name.
commit 0f65c71977fbd2457b9cd7951d74e0a3839880e1
Author: Erez Zadok <ezk at bigvaio.(none)>
Date: Fri May 18 01:41:04 2007 -0400
Documentation: better comments for copyup-related code
commit 8c3044c58ad5ba153f2706244769b9d3bc4a63fb
Author: Erez Zadok <ezk at bigvaio.(none)>
Date: Fri May 18 01:39:26 2007 -0400
Verify and maintain fanout invariants.
This somewhat long patch calls various invariant-checking (debugging)
functions in all places where the fanout invariants should hold. The three
invariant-checking functions, __unionfs_check_{inode,dentry,file}, perform
exhaustive sanity checking on the fan-out of various Unionfs objects. We
check that no lower objects exist outside the start/end branch range; that
all objects within are non-NULL (with some allowed exceptions); that for
every lower file there's a lower dentry+inode; that the start/end ranges
match for all corresponding lower objects; that open files/symlinks have
only one lower objects, but directories can have several; and more.
The rest of this patch actually fixes many places where these invariants did
not hold, which could lead to bugs or corruptions under heavy loads,
multi-threaded workloads, dynamic branch-management, and mmap operations.
Most of the bugs related to actions involving copyups and whiteouts. With
these fixes, the entire Unionfs regression suite passes without a single
invariant violated.
commit 4304cbc51af99cd192a6323bd8b08d97cd51e90b
Author: Erez Zadok <ezk at bigvaio.(none)>
Date: Fri May 18 01:31:14 2007 -0400
Post-copyup helper functions
Two functions which are very useful to execute common actions needed after a
copy-up had taken place.
commit 39d6d248f94f243eea63ff963e7342afaf40f13b
Author: Erez Zadok <ezk at bigvaio.(none)>
Date: Fri May 18 01:28:00 2007 -0400
Introduce compile-time debugging support to Unionfs
Similar to other file systems, to turn on debugging, one is asked to change
the Makefile slightly. The vast majority of the debugging utility functions
are in debug.c. They are useful for developers and users to report to
developers. The main code has some very useful hooks left behind that are
non-intrusive and cleaner (i.e., no "ifdef DEBUG" clutter).
commit cbd682cd4fa5cb861752b5d763ce5efeb876f709
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Fri May 11 01:55:19 2007 -0400
bugfixes: correctly decrement refcounts of mnt's upon branch management
The old logic was broken in one place, which another place tried to "fix"
incorrectly. Also added detailed comments to explain the new/correct logic.
commit 5b92645f81d3249d3a3d79fa78d4a4341598d82c
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Fri May 11 01:51:48 2007 -0400
bugfix in BUG_ON use: actually catch bad use of unionfs_mntput
commit b8ec314dcd8154ebf35d2acf36125e507f064d04
Author: Yiannis Pericleous <yiannos at louie.fsl.cs.sunysb.edu>
Date: Sat Apr 28 22:06:46 2007 -0400
cleanup: removed a trailing whitespace
commit 1539f3f93b13396a673d17059f75f4f31a731a1b
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Fri May 4 14:50:01 2007 -0400
bugfix: remove defunct unionfs_put_inode method
Removed old workaround code that was needed to get mmap working, is no
longer needed with recent kernels.
commit 00f07fa04cdcc7e7c504ef6beb7d756f3b33928a
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Fri May 4 14:44:02 2007 -0400
optimize branch overlapping test a bit
commit 0f0f8f1c4d77a1ea903a1485dfe7b6db7d853295
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Mon Apr 30 17:30:48 2007 -0400
Documentation update regarding overlapping branches and new lookup code.
Added detailed comment and updated documentation (issues.txt) to explain why
overlapping branches are disallowed, better explain cache coherency issues,
and mention upcoming do_lookup_lookup changes.
commit d3578c7b9c231b57aeb3a6d46593477e98cd9609
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Mon Apr 30 16:42:30 2007 -0400
branch management: disallow setting leftmost branch to readonly
Unionfs requires the leftmost branch to be writeable for copyup to work
properly and simply. If, through branch-management commands (add, delete,
or mode change), the leftmost branch will becomes readonly, then return an
error (and tell the user to use "remount,ro" if they want a readonly union).
commit 341d894744f4eedbe9c463a6165018bbb2a21574
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Sun Apr 29 19:33:25 2007 -0400
fsstack: 4th case to do_path_lookup
Signed-off-by: Josef 'Jeff' Sipek <jsipek at cs.sunysb.edu>
commit e3018c715d674468ef16d059f9e3538fa59d3400
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Fri Apr 27 12:35:44 2007 -0400
Revert "Unionfs: Check remount options for being NULL"
This reverts commit 49491b290f0f791a531316c6197437547985537b.
commit 0859d4678f78499db57b2f797fc063cf45678f95
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Thu Apr 19 18:40:36 2007 -0400
bugfix: don't leak resources when copyup fails partially
commit 320dd5adc80739874fa13ec65bf505d8dacc984e
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Wed Apr 18 02:08:14 2007 -0400
cleanup: call our unionfs_{unlock,lock}_dentry instead of mutex ops.
This is for consistency with the rest of the code, which helps us place
debugging code when un/locking our special "info" mutex in our dentries.
commit ec31b5602691aad9415ca0e88d1f999a8ccb7bb0
Author: Erez Zadok <ezk at bigvaio.(none)>
Date: Sun Apr 15 17:43:53 2007 -0400
cleanup: rename our "do_rename" to __unionfs_rename.
To avoid confusion with the VFS-named function do_rename, and to help ctags,
rename our utility (static) function "do_rename" to "__unionfs_rename".
commit ea746b868cbef312781a4515e98563f1e607d0ce
Author: Erez Zadok <ezk at bigvaio.(none)>
Date: Sun Apr 15 17:37:40 2007 -0400
cleanup: rename prefix our version of double_lock_dentry with "unionfs_"
To avoid potential confusion with the VFS function of the same name (and
also confusion with ctags), rename our special version of double_lock_dentry
to unionfs_double_lock_dentry.
commit c3bc463d3d6ce5faf9d594b8aebaacd85b59dbdc
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Fri Apr 13 18:33:41 2007 -0400
Cleanup: ensure space between every comma-delimited function argument list
commit af5a43b9f83f05c89515dc0a7a7c0d4cfe14b2da
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Wed Mar 28 12:42:37 2007 -0400
cleanup: rewrite long while(1) loop more cleanly
commit f231658673ed53c0df440bcd7074ad0f23730b42
Author: Erez Zadok <ezk at bigvaio.(none)>
Date: Sun Mar 25 01:37:15 2007 -0400
Move one function off of branchman.c and remove source file.
After branch-management support was added, branchman.c became obsolete: it
used to hold the old ioctl-based branch-management commands, but now we do
those commands via remount (in super.c). So move the only remaining small
query-file ioctl from branchman.c to commonfops.c, close to unionfs_ioctl;
and remove any leftover extern's which referred to old code in branchman.c
commit 32deb76314464f7036667e1c505ccdc8d413ed96
Author: Erez Zadok <ezk at bigvaio.(none)>
Date: Sun Mar 25 01:29:41 2007 -0400
cleanup: consistent pointer declaration spacing.
Change instances of "foo * var" to "foo *var" for consistency.
commit d8ac4145a04b523b14367a9c0247c104827329c3
Author: Erez Zadok <ezk at bigvaio.(none)>
Date: Sun Mar 25 01:24:54 2007 -0400
Merge unionfs_write with __unionfs_write.
Merge the two functions because unionfs_write was a small function and the
only one which called the __unionfs_write. This saves on stack space and
clarifies code a bit.
commit 8f18f2d3a8b10daea764ac66354ea8d223d09a63
Author: Erez Zadok <ezk at bigvaio.(none)>
Date: Sun Mar 25 01:12:48 2007 -0400
cleanup: fix one odd indentation and long line breakup.
commit 88c65c738627dfe4a01556134e711b64741cd7ee
Author: Erez Zadok <ezk at shekel.local>
Date: Sun Mar 25 00:27:12 2007 -0400
Commenting the code.
Audited entire code for documentation. Added comments at top of functions
where it felt necessary (i.e., function's name and size don't make it clear
what it may be doing precisely). Reformatted some long comments. Fixed a
few comment typos and spelling errors.
commit 556952df6eac3fc14f5439a21296bcec6484e602
Author: Erez Zadok <ezk at shekel.local>
Date: Sat Mar 24 23:14:03 2007 -0400
cleanup: prefix external functions with 'extern' properly
commit 955b7ad95cd34b79c27fbe85031e653789e61a60
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Sat Mar 24 23:01:13 2007 -0400
cleanup: one more trailing whitespace removed.
commit 64387981a3124a7f5a764c308a95631b33f7ed8f
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Sat Mar 24 20:06:44 2007 -0400
cleanup: spell check all strings and comments
commit f7c58e4a4f029e055ff220ccf32a4402717f9e68
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Sat Mar 24 19:56:56 2007 -0400
cleanup: use consistent style for multi-line comments
commit c46c431907fc8df0e9a1ab9aa6b722e3738ea3eb
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Sat Mar 24 19:41:58 2007 -0400
cleanup: keep all top-of-function automatic variables clustered together
commit 4d89dec53cd9d7a0037f62a75658257794157c7f
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Sat Mar 24 19:32:42 2007 -0400
coding-style: remove one more {braces} around one-statement code block
commit f706e207c64940e25263c4208918c83a99b66c87
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Sat Mar 24 19:31:28 2007 -0400
cleanup: remove unnecessary blank lines in short code blocks
commit 5d93c97e14e2f6704aed5a19aeecd9da6015dda6
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Sat Mar 24 19:21:51 2007 -0400
cleanup: add missing copyright notices
commit ae30fb33221975fda3e13691b0dd5a042d998cb5
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Sat Mar 24 19:14:18 2007 -0400
coding-style: reformat lines longer than 80 chars (accounting for TABs)
commit f860fe9371750c22d8db78085a7d129d2475deba
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Sat Mar 24 18:36:59 2007 -0400
cleanup: every printk should prefix with "unionfs: " consistently
commit bc6b0e2b2e76c7ff42e05fde2ef3f21b5ee0c697
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Sat Mar 24 18:19:49 2007 -0400
coding-style: remove unnecessary {braces} around one-line code blocks
commit a17956f50bee24e090fca7cb4ec1021ab23de4b7
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Sat Mar 24 18:11:10 2007 -0400
coding-style: no lines over 80 chars
commit b366d9b50b9d72bafee85de307ce5158b1796a04
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Sat Mar 24 17:57:56 2007 -0400
coding-style: indent every line properly
commit 136964dcd796fe9ebd8379ef87383694ec494a73
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Sat Mar 24 17:41:57 2007 -0400
cleanup: remove trailing spaces
commit 94561995a4feaaf6136224a2ac88f311ab16ee4a
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Sat Mar 24 16:28:59 2007 -0400
Documentation: fix spelling error
commit 24371367b9d6f6d2d5e0aedb2ffce64fa02cc456
Author: Erez_Zadok <ezk at cs.sunysb.edu>
Date: Sat Mar 24 16:19:40 2007 -0400
Documentation: minor typo fixed in incgen remount option
commit 3e5b04b5a336a4e54c01c46291185493056bad79
Author: Josef 'Jeff' Sipek <jsipek at cs.sunysb.edu>
Date: Sat May 19 03:14:30 2007 -0400
Unionfs: SLAB_CTOR_CONSTRUCTOR has been removed from vanilla
Signed-off-by: Josef 'Jeff' Sipek <jsipek at cs.sunysb.edu>
commit 90d6deb40a5ddb1ca9ee2c703b92ec774f815dca
Author: Pekka Enberg <penberg at cs.helsinki.fi>
Date: Sun May 13 12:55:44 2007 -0400
[PATCH] unionfs: fix slab abuses with krealloc
This changes unionfs to use krealloc() for reallocating memory so that we
don't need to play tricks with slab internals.
Cc: Josef Sipek <jsipek at fsl.cs.sunysb.edu>
Signed-off-by: Pekka Enberg <penberg at cs.helsinki.fi>
Signed-off-by: Andrew Morton <akpm at linux-foundation.org>
Signed-off-by: Josef 'Jeff' Sipek <jsipek at cs.sunysb.edu>
commit b86aad8b455abcc1a93ec56eed034426c2da67d3
Author: Adrian Bunk <bunk at stusta.de>
Date: Sat May 5 15:28:33 2007 -0400
[PATCH] fix unionfs compilation
On Sat, May 05, 2007 at 01:49:55AM -0700, Andrew Morton wrote:
>...
> Changes since 2.6.21-rc7-mm2:
>...
> git-unionfs.patch
>...
> git trees
>...
<-- snip -->
...
CC fs/unionfs/super.o
/home/bunk/linux/kernel-2.6/linux-2.6.21-mm1/fs/unionfs/super.c: In function ‘init_once’:
/home/bunk/linux/kernel-2.6/linux-2.6.21-mm1/fs/unionfs/super.c:822: error: ‘SLAB_CTOR_VERIFY’ undeclared (first use in this function)
/home/bunk/linux/kernel-2.6/linux-2.6.21-mm1/fs/unionfs/super.c:822: error: (Each undeclared identifier is reported only once
/home/bunk/linux/kernel-2.6/linux-2.6.21-mm1/fs/unionfs/super.c:822: error: for each function it appears in.)
make[3]: *** [fs/unionfs/super.o] Error 1
<-- snip -->
Signed-off-by: Adrian Bunk <bunk at stusta.de>
Signed-off-by: Josef 'Jeff' Sipek <jsipek at cs.sunysb.edu>
commit c370a07145b3ea20be72cbf12b84d11f965f7a0d
Author: Adrian Brunyate <abrunyate at yahoo.com>
Date: Thu Apr 26 18:51:16 2007 -0400
Unionfs: Check remount options for being NULL
Signed-off-by: Adrian Brunyate <abrunyate at yahoo.com>
Signed-off-by: Josef 'Jeff' Sipek <jsipek at cs.sunysb.edu>
commit cd680814a9c9d19cf45798d4ff106ab74ed4bb2a
Author: Adrian Brunyate <abrunyate at yahoo.com>
Date: Thu Apr 26 18:51:09 2007 -0400
Unionfs: Accept MS_SILENT during remount
[jsipek: whitespace cleanup]
Signed-off-by: Adrian Brunyate <abrunyate at yahoo.com>
Signed-off-by: Josef 'Jeff' Sipek <jsipek at cs.sunysb.edu>
commit d3bddd02b009737181eb219269b80a7cc39cea03
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Fri Mar 23 13:10:46 2007 -0400
Unionfs: Don't inline do_remount_{add,del,mode}_option
gcc4 decided to inline do_remount_{add,del,mode}_option creating an 600 byte
stack abuser on a x86_64 test box.
Reported by: Josef 'Jeff' Sipek <jsipek at cs.sunysb.edu>
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
Signed-off-by: Josef 'Jeff' Sipek <jsipek at cs.sunysb.edu>
commit 933d942d398894ac586502bce9b458f4548aab1f
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Fri Mar 23 13:07:14 2007 -0400
Unionfs: Added several BUG_ONs to assert dentry validity
This should help catch races between the VFS and the branch-management code.
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
Signed-off-by: Josef 'Jeff' Sipek <jsipek at cs.sunysb.edu>
commit 953f74cb1e0a78a1d0fb5becd701cf2072998294
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Thu Mar 22 20:17:48 2007 -0400
Unionfs: Properly handle stale inodes passed to unionfs_permission
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
Signed-off-by: Josef 'Jeff' Sipek <jsipek at cs.sunysb.edu>
commit 61fd5072ee6558d1477030efe27f0d0ca8edb7bb
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Thu Mar 22 20:09:07 2007 -0400
Unionfs: Pass lowernd to lower ->revalidate function
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
Signed-off-by: Josef 'Jeff' Sipek <jsipek at cs.sunysb.edu>
commit 7a841ed3bb09d43cdd42a0db323b49da42298fcb
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Thu Mar 22 20:08:30 2007 -0400
Unionfs: vfsmount reference counting fixes
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
Signed-off-by: Josef 'Jeff' Sipek <jsipek at cs.sunysb.edu>
commit 391817ef360dfeef094c7c458b108644f92f9592
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Thu Mar 22 20:01:56 2007 -0400
Unionfs: unionfs_create needs to revalidate the dentry
We have to read-lock the superblock rwsem, and we have to revalidate the
parent dentry and this one. A branch-management operation could have taken
place, mid-way through a VFS operation that eventually reaches
unionfs_create(). So we have to ensure consistency, just as we do with the
file operations.
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
Signed-off-by: Josef 'Jeff' Sipek <jsipek at cs.sunysb.edu>
commit 50c2397c8aacc9a001d3e6f90aa59b7e3eeafb9b
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Thu Mar 22 19:47:43 2007 -0400
Unionfs: Decrement totalopens counter on error in unionfs_open
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
Signed-off-by: Josef 'Jeff' Sipek <jsipek at cs.sunysb.edu>
commit a6ac4c886ca3b5fb355de484cb9386afc6410f8a
Author: Josef 'Jeff' Sipek <jsipek at cs.sunysb.edu>
Date: Sun Mar 18 16:30:45 2007 -0400
Unionfs: Document unionfs_d_release locking
Signed-off-by: Josef 'Jeff' Sipek <jsipek at cs.sunysb.edu>
commit addc742f98eccdcc5474c1d43167f01ed45c3feb
Author: Josef 'Jeff' Sipek <jsipek at cs.sunysb.edu>
Date: Sun Mar 18 16:22:03 2007 -0400
Unionfs: Remove the older incgen ioctl
The new remount code now has the "incgen" functionality.
Signed-off-by: Josef 'Jeff' Sipek <jsipek at cs.sunysb.edu>
commit b676a01e0822bd947c34eb03755f266b8bc321a4
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Thu Mar 22 19:32:40 2007 -0400
Unionfs: Grab the unionfs sb private data lock around branch info users
Locking/concurrency/race fixes. Use the unionfs superblock rwsem, and grab
the read lock around every op that uses branch-related information, such as
branch counters. Grab the write rwsem lock in operations which attempt to
change branch information, such as when adding/deleting branches. This
will, for example, cause branch-management remount commands (which are
infrequent) to block a bit until all in-progress file operations on open
files are done.
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
[jsipek: whitespace fixes & more locks/unlocks]
Signed-off-by: Josef 'Jeff' Sipek <jsipek at cs.sunysb.edu>
commit 33f33908983c7f5f8be7ee2aac89673588e49ac4
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Mon Mar 19 21:02:55 2007 -0400
Unionfs: Rewrite unionfs_d_revalidate
Rewrite unionfs_d_revalidate code to avoid stack-unfriendly recursion: split
into a call to revalidate just one dentry, and an interative driver function
to revalidate an entire dentry-parent chain.
Fix vfsmount ref leaks which prevented lower f/s from being unmounted after
generation increment, esp. during heavy loads.
Fix one deadlock between revalidation code and VFS.
Better documentation of what the code does.
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
[jsipek: compile & whitespace fixes]
Signed-off-by: Josef 'Jeff' Sipek <jsipek at cs.sunysb.edu>
commit 6556dc02986d8610efdbc3ea29ed149e929e7910
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Mon Mar 19 20:57:49 2007 -0400
Unionfs: Introduce unionfs_mnt{get,put}
Helper inline functions to perform Unionfs's mntget/put ops on lower
branches.
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
[jsipek: cleanup branching in unionfs_mnt{get,put} and compile fixes]
Signed-off-by: Josef 'Jeff' Sipek <jsipek at cs.sunysb.edu>
commit d25c3e2d96a5ee1bef8a5422c0a9294fa142f7f2
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Mon Mar 19 20:44:12 2007 -0400
Unionfs: Bulk of branch-management remount code
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
Signed-off-by: Josef 'Jeff' Sipek <jsipek at cs.sunysb.edu>
commit 05fe5c508daad0e78a09b9ac4cd108b0f58e6051
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Thu Mar 22 19:43:29 2007 -0400
Unionfs: Introduce branch-id code
Each branch gets a unique ID, which helps during branch additions,
deletions, and changes, to locate where branches were moved to, and perform
proper reference-counting. This is useful even if the same directory was
added more than once to union.
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
Signed-off-by: Josef 'Jeff' Sipek <jsipek at cs.sunysb.edu>
commit 8b2a0a1b7a70599640865881acd7494a354167d9
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Mon Apr 9 09:57:51 2007 -0400
Unionfs: Actually verify if dentry's info node is locked
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
Signed-off-by: Josef 'Jeff' Sipek <jsipek at cs.sunysb.edu>
commit 8fb5f40153729c1c4bab154367e98e5c2fdde8ee
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Mon Mar 19 03:01:49 2007 -0400
Unionfs: Provide more helpful info on branch leaks during unmount
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
[jsipek: no need to take a read lock on the superblock private data]
Signed-off-by: Josef 'Jeff' Sipek <jsipek at cs.sunysb.edu>
commit 6f472e19a1f66910aa4db0f545d3d3e8c1ffb7df
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Mon Mar 19 00:46:03 2007 -0400
Unionfs: Rename unionfs_data sbcount field to more appropriate open_files
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
Signed-off-by: Josef 'Jeff' Sipek <jsipek at cs.sunysb.edu>
commit 257a23334ad5fd44896abf74cd9fe93be26f33ee
Author: Josef 'Jeff' Sipek <jsipek at cs.sunysb.edu>
Date: Sun Mar 18 19:37:51 2007 -0400
Unionfs: Proper comment on rwsem field
Signed-off-by: Josef 'Jeff' Sipek <jsipek at cs.sunysb.edu>
commit e0bc0eb45884812cfbb90d8672136c9d90c7de19
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Fri Mar 23 17:17:07 2007 -0400
Unionfs: Documentation updates for branch-management
Describe dynamic branch-management introduced by subsequent patches.
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
Signed-off-by: Josef 'Jeff' Sipek <jsipek at cs.sunysb.edu>
commit bed3ec97b07a7ab81bbb090e9a2390db848842fd
Author: Erez Zadok <ezkcs.sunysb.edu>
Date: Sun Mar 18 19:24:29 2007 -0400
fs: Export drop_pagecache_sb symbol
Signed-off-by: Erez Zadok <ezkcs.sunysb.edu>
Signed-off-by: Josef 'Jeff' Sipek <jsipekcs.sunysb.edu>
commit e60330d66f4bd50d561857c11649e498d615fac8
Author: Erez Zadok <ezkcs.sunysb.edu>
Date: Sun Mar 18 19:23:52 2007 -0400
fs: Introduce path{get,put}
Export drop_pagecache_sb symbol (for branch-management).
Signed-off-by: Erez Zadok <ezkcs.sunysb.edu>
Signed-off-by: Josef 'Jeff' Sipek <jsipekcs.sunysb.edu>
commit 7a770acc022d7c9a905964e5b73c5a9943ac17c4
Author: Randy Dunlap <randy.dunlap at oracle.com>
Date: Mon Mar 19 19:15:22 2007 -0400
[PATCH] Unionfs: sioq not __exit
stop_sioq() is called from both __init and __exit functions, so it
shouldn't be marked __exit.
Reported on the kernelnewbies mailing list, but no patch offered there.
Signed-off-by: Randy Dunlap <randy.dunlap at oracle.com>
Signed-off-by: Josef 'Jeff' Sipek <jsipek at cs.sunysb.edu>
commit 880575f0d8de520975259bb946185365c02c63a5
Author: Josef 'Jeff' Sipek <jsipek at cs.sunysb.edu>
Date: Sat Mar 17 19:42:25 2007 -0400
MAINTAINERS: Unionfs URL update
Signed-off-by: Josef 'Jeff' Sipek <jsipek at cs.sunysb.edu>
commit 7331b3bbebb23cd879018647475bf76de7c7b84e
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Sun Mar 4 18:02:11 2007 -0500
fs/unionfs/: Fix unlocking in error paths
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
Signed-off-by: Josef 'Jeff' Sipek <jsipek at cs.sunysb.edu>
commit fc1176cc985a3f08f6bee6d901564f70f87f5db7
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Sun Mar 4 15:21:14 2007 -0500
fs/unionfs/: Fix dentry leak in copyup_named_dentry
When we chmod a directory on a readonly branch, and have to copy it up, we
forget to dput(). If this was a file, it gets dput indirectly through other
functions we call, but not if it was a directory.
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
Signed-off-by: Josef 'Jeff' Sipek <jsipek at cs.sunysb.edu>
commit aadf0cee1000e2f48fb7df731170d51771791948
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Fri Mar 2 13:10:56 2007 -0500
fs/unionfs/: mntput in __cleanup_dentry
This fixes a mnt refleak which occured during copyup when directory
hierarchy was recreated on a writable branch.
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
Signed-off-by: Josef 'Jeff' Sipek <jsipek at cs.sunysb.edu>
commit 02e9f929061698f893a9370c4791f752e42f6a69
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Sun Mar 4 00:41:51 2007 -0500
fs/unionfs/: Fix copyup_deleted_file dentry leak
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
Signed-off-by: Josef 'Jeff' Sipek <jsipek at cs.sunysb.edu>
commit 92cabe82371669f12137ade2da5a5a8308f48902
Author: Josef 'Jeff' Sipek <jsipek at cs.sunysb.edu>
Date: Fri Mar 2 13:14:01 2007 -0500
fs/unionfs/: Miscellaneous coding style fixes
Signed-off-by: Josef 'Jeff' Sipek <jsipek at cs.sunysb.edu>
commit 67d2bd9b72589bb94694c101cd7eef6e277143e8
Author: Josef 'Jeff' Sipek <jsipek at cs.sunysb.edu>
Date: Tue Feb 27 14:27:25 2007 -0500
fs/unionfs/: Check return value of d_path
Signed-off-by: Josef 'Jeff' Sipek <jsipek at cs.sunysb.edu>
commit 738bed3108046c585e31875700f8696ac6a4bfcf
Author: Josef 'Jeff' Sipek <jsipek at cs.sunysb.edu>
Date: Sun Feb 25 17:32:46 2007 -0500
fs/unionfs/: Use SEEK_{SET,CUR} instead of hardcoded values
Signed-off-by: Josef 'Jeff' Sipek <jsipek at cs.sunysb.edu>
commit 9c04939070aa98ff1177a4547b7486ffe305e28e
Author: Josef 'Jeff' Sipek <jsipek at cs.sunysb.edu>
Date: Sun Feb 25 17:30:34 2007 -0500
fs/unionfs/: Remove alloc_filldir_node
alloc_filldir_node was used only once. Additionally, all the arguments
passed to it were ignored wasting stack space for no reason whatsoever.
Signed-off-by: Josef 'Jeff' Sipek <jsipek at cs.sunysb.edu>
commit 49dcb0acbcda00f7d8fc9a3b7d56a271624535b9
Author: Josef 'Jeff' Sipek <jsipek at cs.sunysb.edu>
Date: Sat Feb 24 16:47:45 2007 -0500
fs/unionfs/: Rename unionfs_d_revalidate_wrap
Follow the convention of "foo" calling "__foo".
Signed-off-by: Josef 'Jeff' Sipek <jsipek at cs.sunysb.edu>
commit c9132ae5b20c3037a8837b871a5dad77253195c7
Author: Josef 'Jeff' Sipek <jsipek at cs.sunysb.edu>
Date: Sat Feb 24 16:46:08 2007 -0500
fs/unionfs/: Several small cleanups in unionfs_interpose
1) No need to lock the inode - lockdep was complaining about potential
circular dependency
2) No need to use temporary variable for iunique() inode number
3) Removed unneeded comment
Signed-off-by: Josef 'Jeff' Sipek <jsipek at cs.sunysb.edu>
commit bd71762ba043362e1ffb574a2b1137f7093ab8a9
Author: Josef 'Jeff' Sipek <jsipek at cs.sunysb.edu>
Date: Fri Feb 23 01:04:09 2007 -0500
fs/unionfs/: Don't grab dentry private data mutex in unionfs_d_release
Grabbing the UNIONFS_D(dentry)->lock is completely unnecessary and there are
no other references; we are about to free the object anyway. Additionally,
grabbing the mutex produces warning when the slab object is reused - as it
was freed while there still was a reference to it.
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
Signed-off-by: Josef 'Jeff' Sipek <jsipek at cs.sunysb.edu>
commit 19e82ab11967dac0ee3689863b669c01172dcd76
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Fri Mar 2 13:35:33 2007 -0500
fs/unionfs/: Fix a memory leak in unionfs_read_super
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
Signed-off-by: Josef 'Jeff' Sipek <jsipek at cs.sunysb.edu>
commit 838126ece55378b2cd5055b220ae5aef02f57c81
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Fri Mar 2 13:00:57 2007 -0500
fs/unionfs: Fix a memory leak & null pointer dereference
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
Signed-off-by: Josef 'Jeff' Sipek <jsipek at cs.sunysb.edu>
commit 0de3667d05072a849a7e1ec1616054515ae0599e
Author: Adrian Bunk <bunk at stusta.de>
Date: Wed Feb 21 01:30:10 2007 -0500
[PATCH] UNION_FS must depend on SLAB
On Sat, Feb 17, 2007 at 09:51:46PM -0800, Andrew Morton wrote:
>...
> Changes since 2.6.20-mm1:
>...
> git-unionfs.patch
>...
> git trees
>...
<-- snip -->
...
CC fs/unionfs/copyup.o
/home/bunk/linux/kernel-2.6/linux-2.6.20-mm2/fs/unionfs/copyup.c: In function 'create_parents_named':
/home/bunk/linux/kernel-2.6/linux-2.6.20-mm2/fs/unionfs/copyup.c:620: error: 'malloc_sizes' undeclared (first use in this function)
/home/bunk/linux/kernel-2.6/linux-2.6.20-mm2/fs/unionfs/copyup.c:620: error: (Each undeclared identifier is reported only once
/home/bunk/linux/kernel-2.6/linux-2.6.20-mm2/fs/unionfs/copyup.c:620: error: for each function it appears in.)
make[3]: *** [fs/unionfs/copyup.o] Error 1
<-- snip -->
Signed-off-by: Adrian Bunk <bunk at stusta.de>
Signed-off-by: Josef 'Jeff' Sipek <jsipek at cs.sunysb.edu>
commit 1ef4c8c4f8c164291f35391c64782c84a126cf56
Author: Josef 'Jeff' Sipek <jsipek at cs.sunysb.edu>
Date: Sat Feb 17 03:25:15 2007 -0500
fs/unionfs/: Remove unused structure members & macros
This patch removes:
- hidden_mnt pointer from struct unionfs_data
- mount_flag from struct unionfs_sb_info
- mount_flag related macros
Signed-off-by: Josef 'Jeff' Sipek <jsipek at cs.sunysb.edu>
commit 17ae8862c87460096a3ccd62b17294d6c82e8376
Author: Michael Halcrow <mhalcrow at us.ibm.com>
Date: Fri Feb 16 14:09:25 2007 -0500
eCryptfs: convert lookup_one_len() to lookup_one_len_nd()
Call the new lookup_one_len_nd() rather than lookup_one_len(). This fixes an
oops when stacked on NFS.
Note that there are still some issues with eCryptfs on NFS having to do with
directory deletion (I'm not getting an oops, just an -EBUSY).
Signed-off-by: Michael Halcrow <mhalcrow at us.ibm.com>
Signed-off-by: Andrew Morton <akpm at linux-foundation.org>
Signed-off-by: Josef 'Jeff' Sipek <jsipek at cs.sunysb.edu>
commit 27ba8e96e84756c8c3d938a810ad7173235b3f31
Author: Erez Zadok <ezk at cs.sunysb.edu>
Date: Mon Feb 12 12:36:38 2007 -0500
Unionfs: Documentation update
Be little gentler & updated the URLs
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
Signed-off-by: Josef 'Jeff' Sipek <jsipek at cs.sunysb.edu>
commit 14345177b39247adbce108dfa17b7ac347e115b4
Author: Josef 'Jeff' Sipek <jsipek at cs.sunysb.edu>
Date: Mon Feb 19 23:35:32 2007 -0500
fs/: Move eCryptfs & Unionfs config options into a sub-menu
Using The Misc filesystems sub-menu for layered/stackable filesystems only
makes it harder for users to find eCryptfs/Unionfs.
Additionally, the menu can be easily turned into a menuconfig, which could
be used to turn on any VFS/VM functionality required by layered filesystems
(there is none at the moment).
Signed-off-by: Josef 'Jeff' Sipek <jsipek at cs.sunysb.edu>
Signed-off-by: Michael Halcrow <mhalcrow at us.ibm.com>
commit d52b6d9e97009f20fb7b78085b9edeb3ece61461
Author: Josef 'Jeff' Sipek <jsipek at cs.sunysb.edu>
Date: Thu Feb 1 12:14:03 2007 -0500
fs/unionfs/: Use __roundup_pow_of_two instead of custom rounding code
Signed-off-by: Josef 'Jeff' Sipek <jsipek at cs.sunysb.edu>
commit aee279534cd883048e7eabe4847cfec9b88da6f6
Author: Josef 'Jeff' Sipek <jsipek at cs.sunysb.edu>
Date: Sun Jan 28 14:20:19 2007 -0500
fs/unionfs/: Don't duplicate the struct nameidata
The only fields that we have to watch out for are the dentry and vfsmount.
Additionally, this makes Unionfs gentler on the stack as nameidata is rather
large.
Signed-off-by: Josef 'Jeff' Sipek <jsipek at cs.sunysb.edu>
commit 94e3e1851d91fd95d9c5c5e15b9a0d936293cbe9
Author: Josef 'Jeff' Sipek <jsipek at cs.sunysb.edu>
Date: Sun Jan 28 14:20:49 2007 -0500
fs/unionfs/: Andrew Morton's comments
- rename {,un}lock_dentry to unionfs_{,un}lock_dentry
- few minor coding style fixes
- removed prototypes from .c files
- replaced dbstart macros etc with static inlines
- replaced UNIONFS_D(d)->sem semaphore with a mutex
- renamed sioq struct workqueue to superio_workqueue
- made unionfs_get_nlinks and alloc_whname not inlined
Signed-off-by: Josef 'Jeff' Sipek <jsipek at cs.sunysb.edu>
commit a2e9f27e62a67e34c9cb309ae540bebde6408a26
Author: Adrian Bunk <bunk at stusta.de>
Date: Thu Jan 25 03:15:59 2007 -0500
fs/unionfs/: possible cleanups
This patch contains the following possible cleanups:
- every function should #include the headers containing the prototypes
of it's global functions
- static functions in C files shouldn't be marked "inline", gcc should
know best when to inline them
- make needlessly global code static
- #if 0 the following unused global function:
- stale_inode.c: is_stale_inode()
Signed-off-by: Adrian Bunk <bunk at stusta.de>
[removed stale inode related fixes as stale_inode.c is gone]
Signed-off-by: Josef 'Jeff' Sipek <jsipek at cs.sunysb.edu>
commit 9179579d33349e2632612c6753c9ec276f938b7d
Author: Josef 'Jeff' Sipek <jsipek at cs.sunysb.edu>
Date: Sun Jan 28 15:52:43 2007 -0500
fs/unionfs/: Remove stale_inode.c
The stale inode operations were heavily based on bad inode operations. This
patch removes stale_inode.c and converts all users of stale_inode_ops to
bad_inode_ops as there seems to be no reason to return ESTALE instead of
EIO.
This is the more appropriate than porting the bad_inode.c fix (commit
be6aab0e9fa6d3c6d75aa1e38ac972d8b4ee82b8) to stale_inode.c.
Signed-off-by: Josef 'Jeff' Sipek <jsipek at cs.sunysb.edu>
commit cf9553582a03b7a4f049009df97aaaead5510762
Author: Josef "Jeff" Sipek <jsipek at cs.sunysb.edu>
Date: Sun Jan 28 15:11:23 2007 -0500
Unionfs: Extended Attributes support
Extended attribute support.
Signed-off-by: Josef "Jeff" Sipek <jsipek at cs.sunysb.edu>
Signed-off-by: David Quigley <dquigley at fsl.cs.sunysb.edu>
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 8ab774c41cefb83536548d6214368e0b60662ed1
Author: Josef "Jeff" Sipek <jsipek at cs.sunysb.edu>
Date: Sun Jan 28 15:10:20 2007 -0500
Unionfs: Kconfig and Makefile
This patch contains the changes to fs Kconfig file, Makefiles, and Maintainers
file for Unionfs.
Signed-off-by: Josef "Jeff" Sipek <jsipek at cs.sunysb.edu>
Signed-off-by: David Quigley <dquigley at fsl.cs.sunysb.edu>
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 3a32c04da990d17b5cc6bfd9309310ebda8d59e5
Author: Josef "Jeff" Sipek <jsipek at cs.sunysb.edu>
Date: Sun Jan 21 18:47:57 2007 -0500
Unionfs: Unlink
This patch provides unlink functionality for Unionfs.
Signed-off-by: Josef "Jeff" Sipek <jsipek at cs.sunysb.edu>
Signed-off-by: David Quigley <dquigley at fsl.cs.sunysb.edu>
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 73d1e5d4ddd24da51dc6239ebeb2c3de75ed3537
Author: Josef "Jeff" Sipek <jsipek at cs.sunysb.edu>
Date: Sun Jan 21 18:47:43 2007 -0500
Unionfs: Include file
Global include file - can be included from userspace by utilities.
Signed-off-by: Josef "Jeff" Sipek <jsipek at cs.sunysb.edu>
Signed-off-by: David Quigley <dquigley at fsl.cs.sunysb.edu>
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 74c74b391743e799b2801cea9f6115136d865e49
Author: Josef "Jeff" Sipek <jsipek at cs.sunysb.edu>
Date: Sun Jan 28 15:05:29 2007 -0500
Unionfs: Internal include file
This patch contains an internal Unionfs include file. The include file is
specific to kernel code only, and therefore is separate from
include/linux/unionfs.h.
Signed-off-by: Josef "Jeff" Sipek <jsipek at cs.sunysb.edu>
Signed-off-by: David Quigley <dquigley at fsl.cs.sunysb.edu>
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit bced0ae66380708dd8d070914e3dbc62c001b8ba
Author: Josef "Jeff" Sipek <jsipek at cs.sunysb.edu>
Date: Sun Jan 21 18:46:56 2007 -0500
Unionfs: Helper macros/inlines
This patch contains many macros and inline functions used thoughout Unionfs.
Signed-off-by: Josef "Jeff" Sipek <jsipek at cs.sunysb.edu>
Signed-off-by: David Quigley <dquigley at fsl.cs.sunysb.edu>
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit bbf538ee8daf8ebbb8a52951a40528727ececac3
Author: Josef "Jeff" Sipek <jsipek at cs.sunysb.edu>
Date: Sun Jan 28 15:05:07 2007 -0500
Unionfs: Handling of stale inodes
Provides nicer handling of stale inodes.
Signed-off-by: Josef "Jeff" Sipek <jsipek at cs.sunysb.edu>
Signed-off-by: David Quigley <dquigley at fsl.cs.sunysb.edu>
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit fa5486995f8c078d09f907fc260a232adcb5aeca
Author: Josef "Jeff" Sipek <jsipek at cs.sunysb.edu>
Date: Sun Jan 21 18:46:47 2007 -0500
Unionfs: Superblock operations
This patch contains the superblock operations for Unionfs.
Signed-off-by: Josef "Jeff" Sipek <jsipek at cs.sunysb.edu>
Signed-off-by: David Quigley <dquigley at fsl.cs.sunysb.edu>
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit df28f52598298d80f51ed372fff94b023af6f85d
Author: Josef "Jeff" Sipek <jsipek at cs.sunysb.edu>
Date: Sun Jan 21 18:46:39 2007 -0500
Unionfs: Miscellaneous helper functions
This patch contains miscellaneous helper functions used thoughout Unionfs.
Signed-off-by: Josef "Jeff" Sipek <jsipek at cs.sunysb.edu>
Signed-off-by: David Quigley <dquigley at fsl.cs.sunysb.edu>
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 929d57c8bdc653d5341283976548841d412f2288
Author: Josef "Jeff" Sipek <jsipek at cs.sunysb.edu>
Date: Sun Jan 21 18:46:11 2007 -0500
Unionfs: Privileged operations workqueue
Workqueue & helper functions used to perform privileged operations on
behalf of the user process.
Signed-off-by: Josef "Jeff" Sipek <jsipek at cs.sunysb.edu>
Signed-off-by: David Quigley <dquigley at fsl.cs.sunysb.edu>
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 5754b20794abf98b18bad815985ec43f595aea15
Author: Josef "Jeff" Sipek <jsipek at cs.sunysb.edu>
Date: Sun Jan 21 18:45:56 2007 -0500
Unionfs: Rename
This patch provides rename functionality for Unionfs.
Signed-off-by: Josef "Jeff" Sipek <jsipek at cs.sunysb.edu>
Signed-off-by: David Quigley <dquigley at fsl.cs.sunysb.edu>
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 1e20e9963a4870e38d182f76b82d0e52886242c3
Author: Josef "Jeff" Sipek <jsipek at cs.sunysb.edu>
Date: Sun Jan 21 18:45:48 2007 -0500
Unionfs: Readdir state
This file contains the routines for maintaining readdir state.
Signed-off-by: Josef "Jeff" Sipek <jsipek at cs.sunysb.edu>
Signed-off-by: David Quigley <dquigley at fsl.cs.sunysb.edu>
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit c36b1f9526573b733172840fa8ad579917272d7d
Author: Josef "Jeff" Sipek <jsipek at cs.sunysb.edu>
Date: Sun Jan 21 18:45:28 2007 -0500
Unionfs: Main module functions
Module init & cleanup code, as well as interposition functions.
Signed-off-by: Josef "Jeff" Sipek <jsipek at cs.sunysb.edu>
Signed-off-by: David Quigley <dquigley at fsl.cs.sunysb.edu>
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 2f3199794dcbe7cb3e155844288f1c42b8a15853
Author: Josef "Jeff" Sipek <jsipek at cs.sunysb.edu>
Date: Sun Jan 21 18:45:13 2007 -0500
Unionfs: Lookup helper functions
This patch provides helper functions for the lookup operations in Unionfs.
Signed-off-by: Josef "Jeff" Sipek <jsipek at cs.sunysb.edu>
Signed-off-by: David Quigley <dquigley at fsl.cs.sunysb.edu>
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit a3699d4181a54d54c8fdb51a98da76d9425d7afc
Author: Josef "Jeff" Sipek <jsipek at cs.sunysb.edu>
Date: Sun Jan 21 18:44:54 2007 -0500
Unionfs: Inode operations
This patch provides the inode operations for Unionfs.
Signed-off-by: Josef "Jeff" Sipek <jsipek at cs.sunysb.edu>
Signed-off-by: David Quigley <dquigley at fsl.cs.sunysb.edu>
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 0248e326ad22bbd7adba64cfa8482bbab91a36df
Author: Josef "Jeff" Sipek <jsipek at cs.sunysb.edu>
Date: Sun Jan 21 18:44:35 2007 -0500
Unionfs: Directory manipulation helper functions
This patch contains directory manipulation helper functions.
Signed-off-by: Josef "Jeff" Sipek <jsipek at cs.sunysb.edu>
Signed-off-by: David Quigley <dquigley at fsl.cs.sunysb.edu>
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit c84802f0127391a54ef3b62dec97053c9a4d390b
Author: Josef "Jeff" Sipek <jsipek at cs.sunysb.edu>
Date: Sun Jan 21 18:44:24 2007 -0500
Unionfs: Directory file operations
This patch provides directory file operations.
Signed-off-by: Josef "Jeff" Sipek <jsipek at cs.sunysb.edu>
Signed-off-by: David Quigley <dquigley at fsl.cs.sunysb.edu>
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 145fc8059b8bfb2ca99c4e0a23bb79215ed64ed7
Author: Josef "Jeff" Sipek <jsipek at cs.sunysb.edu>
Date: Sun Jan 21 18:44:05 2007 -0500
Unionfs: File operations
This patch provides the file operations for Unionfs.
Signed-off-by: Josef "Jeff" Sipek <jsipek at cs.sunysb.edu>
Signed-off-by: David Quigley <dquigley at fsl.cs.sunysb.edu>
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 7d194b429f89e6a5f792238916b428b406b08e98
Author: Josef "Jeff" Sipek <jsipek at cs.sunysb.edu>
Date: Sun Jan 28 15:05:21 2007 -0500
Unionfs: Dentry operations
This patch contains the dentry operations for Unionfs.
Signed-off-by: Josef "Jeff" Sipek <jsipek at cs.sunysb.edu>
Signed-off-by: David Quigley <dquigley at fsl.cs.sunysb.edu>
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 12bb6cc9917e8cf59e0470e93bc2311544ac7998
Author: Josef "Jeff" Sipek <jsipek at cs.sunysb.edu>
Date: Sun Jan 21 18:42:32 2007 -0500
Unionfs: Copyup Functionality
This patch contains the functions used to perform copyup operations in unionfs.
Signed-off-by: Josef "Jeff" Sipek <jsipek at cs.sunysb.edu>
Signed-off-by: David Quigley <dquigley at fsl.cs.sunysb.edu>
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 90c3b3e8f695f26221d7903f8f6e1c0492530e04
Author: Josef "Jeff" Sipek <jsipek at cs.sunysb.edu>
Date: Sun Jan 21 18:42:16 2007 -0500
Unionfs: Common file operations
This patch contains helper functions used through the rest of the code which
pertains to files.
Signed-off-by: Josef "Jeff" Sipek <jsipek at cs.sunysb.edu>
Signed-off-by: David Quigley <dquigley at fsl.cs.sunysb.edu>
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 43d45cefb9e2ecbc2053ee326f4e3250f088ac5e
Author: Josef "Jeff" Sipek <jsipek at cs.sunysb.edu>
Date: Sun Jan 21 18:42:01 2007 -0500
Unionfs: Branch management functionality
This patch contains the ioctls to increase the union generation and to query
which branch a file exists on.
Signed-off-by: Josef "Jeff" Sipek <jsipek at cs.sunysb.edu>
Signed-off-by: David Quigley <dquigley at fsl.cs.sunysb.edu>
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit 6f4d98cbfbfc6077bcd724642230a5b2f9ee27c6
Author: Josef "Jeff" Sipek <jsipek at cs.sunysb.edu>
Date: Sun Apr 29 15:36:03 2007 -0400
lookup_one_len_nd - lookup_one_len with nameidata argument
This patch renames lookup_one_len to lookup_one_len_nd, and adds a nameidata
argument. An inline function, lookup_one_len (which calls lookup_one_len_nd
with nd == NULL) preserves original behavior.
The following Unionfs patches depend on this one.
Signed-off-by: Josef "Jeff" Sipek <jsipek at cs.sunysb.edu>
commit 7441bbb408b5a9fc397f946aaa3b7ac3ec696965
Author: Josef "Jeff" Sipek <jsipek at cs.sunysb.edu>
Date: Mon Feb 19 23:31:35 2007 -0500
Unionfs: Documentation
This patch contains documentation for Unionfs. You will find several files
outlining basic unification concepts and rename semantics.
Signed-off-by: Josef "Jeff" Sipek <jsipek at cs.sunysb.edu>
Signed-off-by: David Quigley <dquigley at fsl.cs.sunysb.edu>
Signed-off-by: Erez Zadok <ezk at cs.sunysb.edu>
commit ad41f4ca566224862fea37c46acd1af8620b6394
Author: Greg Kroah-Hartman <gregkh at suse.de>
Date: Tue Aug 10 09:57:13 2010 -0700
Linux 2.6.27.50
commit 6fcefe4aef997caa4bfcd7fd53b850dbe890bb7d
Author: Bob Peterson <rpeterso at redhat.com>
Date: Wed Jul 14 18:12:26 2010 -0400
GFS2: rename causes kernel Oops
commit 728a756b8fcd22d80e2dbba8117a8a3aafd3f203 upstream.
This patch fixes a kernel Oops in the GFS2 rename code.
The problem was in the way the gfs2 directory code was trying
to re-use sentinel directory entries.
In the failing case, gfs2's rename function was renaming a
file to another name that had the same non-trivial length.
The file being renamed happened to be the first directory
entry on the leaf block.
First, the rename code (gfs2_rename in ops_inode.c) found the
original directory entry and decided it could do its job by
simply replacing the directory entry with another. Therefore
it determined correctly that no block allocations were needed.
Next, the rename code deleted the old directory entry prior to
replacing it with the new name. Therefore, the soon-to-be
replaced directory entry was temporarily made into a directory
entry "sentinel" or a place holder at the start of a leaf block.
Lastly, it went to re-add the replacement directory entry in
that leaf block. However, when gfs2_dirent_find_space was
looking for space in the leaf block, it used the wrong value
for the sentinel. That threw off its calculations so later
it decides it can't really re-use the sentinel and therefore
must allocate a new leaf block. But because it previously decided
to re-use the directory entry, it didn't waste the time to
grab a new block allocation for the inode. Therefore, the
inode's i_alloc pointer was still NULL and it crashes trying to
reference it.
In the case of sentinel directory entries, the entire dirent is
reused, not just the "free space" portion of it, and therefore
the function gfs2_dirent_find_space should use the value 0
rather than GFS2_DIRENT_SIZE(0) for the actual dirent size.
Fixing this calculation enables the reproducer programs to work
properly.
Signed-off-by: Bob Peterson <rpeterso at redhat.com>
Signed-off-by: Steven Whitehouse <swhiteho at redhat.com>
Signed-off-by: Greg Kroah-Hartman <gregkh at suse.de>
commit a85ad775e7473d447dc5f9e35b0475ce17497cf3
Author: James Bottomley <James.Bottomley at suse.de>
Date: Fri Mar 12 16:14:42 2010 -0600
SCSI: enclosure: fix error path - actually return ERR_PTR() on error
commit a91c1be21704113b023919826c6d531da46656ef upstream.
we also need to clean up and free the cdev.
Reported-by: Jani Nikula <ext-jani.1.nikula at nokia.com>
Signed-off-by: James Bottomley <James.Bottomley at suse.de>
Signed-off-by: Greg Kroah-Hartman <gregkh at suse.de>
commit e1377aee4e4d4f5f0621b399b247b0790330b4c9
Author: Dan Rosenberg <dan.j.rosenberg at gmail.com>
Date: Thu Jun 24 12:07:47 2010 +1000
xfs: prevent swapext from operating on write-only files
commit 1817176a86352f65210139d4c794ad2d19fc6b63 upstream.
This patch prevents user "foo" from using the SWAPEXT ioctl to swap
a write-only file owned by user "bar" into a file owned by "foo" and
subsequently reading it. It does so by checking that the file
descriptors passed to the ioctl are also opened for reading.
Signed-off-by: Dan Rosenberg <dan.j.rosenberg at gmail.com>
Reviewed-by: Christoph Hellwig <hch at lst.de>
Signed-off-by: Greg Kroah-Hartman <gregkh at suse.de>
commit cf32802d7620d7f0e7b1c360cdd5821f2d10a3b0
Author: Helge Deller <deller at gmx.de>
Date: Mon Aug 2 22:46:41 2010 +0200
PARISC: led.c - fix potential stack overflow in led_proc_write()
commit 4b4fd27c0b5ec638a1f06ced9226fd95229dbbf0 upstream.
avoid potential stack overflow by correctly checking count parameter
Reported-by: Ilja <ilja at netric.org>
Signed-off-by: Helge Deller <deller at gmx.de>
Acked-by: Kyle McMartin <kyle at mcmartin.ca>
Cc: James E.J. Bottomley <jejb at parisc-linux.org>
Signed-off-by: Linus Torvalds <torvalds at linux-foundation.org>
Signed-off-by: Greg Kroah-Hartman <gregkh at suse.de>
commit 74225fccbb2c3177cf306bdd1e5cd3357cc457bd
Author: Alexey Dobriyan <adobriyan at gmail.com>
Date: Wed Oct 29 14:00:50 2008 -0700
.gitignore updates
commit c17dad6905fc82d8f523399e5c3f014e81d61df6 upstream.
Signed-off-by: Alexey Dobriyan <adobriyan at gmail.com>
Signed-off-by: Andrew Morton <akpm at linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds at linux-foundation.org>
Signed-off-by: Greg Kroah-Hartman <gregkh at suse.de>
commit ab7249d7e29c838206f93e446ff7719e01bd7b53
Author: Greg Kroah-Hartman <gregkh at suse.de>
Date: Mon Aug 2 10:19:11 2010 -0700
Linux 2.6.27.49
commit ae78a9ae2391bebf1b0ad0ff38b5a9cff3130a3e
Author: Andre Osterhues <aosterhues at escrypt.com>
Date: Tue Jul 13 15:59:17 2010 -0500
ecryptfs: Bugfix for error related to ecryptfs_hash_buckets
commit a6f80fb7b5986fda663d94079d3bba0937a6b6ff upstream.
The function ecryptfs_uid_hash wrongly assumes that the
second parameter to hash_long() is the number of hash
buckets instead of the number of hash bits.
This patch fixes that and renames the variable
ecryptfs_hash_buckets to ecryptfs_hash_bits to make it
clearer.
Fixes: CVE-2010-2492
Signed-off-by: Andre Osterhues <aosterhues at escrypt.com>
Signed-off-by: Tyler Hicks <tyhicks at linux.vnet.ibm.com>
Signed-off-by: Linus Torvalds <torvalds at linux-foundation.org>
Signed-off-by: Greg Kroah-Hartman <gregkh at suse.de>
commit 4baaa88700f665504702646b908fd7240425bdb5
Author: Krzysztof Halasa <khc at pm.waw.pl>
Date: Fri Jun 11 01:08:20 2010 +0200
kbuild: Fix modpost segfault
commit 1c938663d58b5b2965976a6f54cc51b5d6f691aa upstream.
Alan <alan at clueserver.org> writes:
> program: /home/alan/GitTrees/linux-2.6-mid-ref/scripts/mod/modpost -o
> Module.symvers -S vmlinux.o
>
> Program received signal SIGSEGV, Segmentation fault.
It just hit me.
It's the offset calculation in reloc_location() which overflows:
return (void *)elf->hdr + sechdrs[section].sh_offset +
(r->r_offset - sechdrs[section].sh_addr);
E.g. for the first rodata r entry:
r->r_offset < sechdrs[section].sh_addr
and the expression in the parenthesis produces 0xFFFFFFE0 or something
equally wise.
Reported-by: Alan <alan at clueserver.org>
Signed-off-by: Krzysztof Hałasa <khc at pm.waw.pl>
Tested-by: Alan <alan at clueserver.org>
Signed-off-by: Michal Marek <mmarek at suse.cz>
Signed-off-by: Greg Kroah-Hartman <gregkh at suse.de>
commit 1671a40d1e83733a1bc71444f9a1277b5c83336b
Author: Jiri Pirko <jpirko at redhat.com>
Date: Wed Mar 25 17:23:38 2009 -0700
bonding: select current active slave when enslaving device for mode tlb and alb
commit 5a29f7893fbe681f1334285be7e41e56f0de666c upstream.
I've hit an issue on my system when I've been using RealTek RTL8139D cards in
bonding interface in mode balancing-alb. When I enslave a card, the current
active slave (bond->curr_active_slave) is not set and the link is therefore
not functional.
----
# cat /proc/net/bonding/bond0
Ethernet Channel Bonding Driver: v3.5.0 (November 4, 2008)
Bonding Mode: adaptive load balancing
Primary Slave: None
Currently Active Slave: None
MII Status: up
MII Polling Interval (ms): 100
Up Delay (ms): 0
Down Delay (ms): 0
Slave Interface: eth1
MII Status: up
Link Failure Count: 0
Permanent HW addr: 00:1f:1f:01:2f:22
----
The thing that gets it right is when I unplug the cable and then I put it back
into the NIC. Then the current active slave is set to eth1 and link is working
just fine. Here is dmesg log with bonding DEBUG messages turned on:
----
ADDRCONF(NETDEV_UP): bond0: link is not ready
event_dev: bond0, event: 1
IFF_MASTER
event_dev: bond0, event: 8
IFF_MASTER
bond_ioctl: master=bond0, cmd=35216
slave_dev=cac5d800:
slave_dev->name=eth1:
eth1: ! NETIF_F_VLAN_CHALLENGED
event_dev: eth1, event: 8
eth1: link up, 100Mbps, full-duplex, lpa 0xC5E1
event_dev: eth1, event: 1
event_dev: eth1, event: 8
IFF_SLAVE
Initial state of slave_dev is BOND_LINK_UP
bonding: bond0: enslaving eth1 as an active interface with an up link.
ADDRCONF(NETDEV_CHANGE): bond0: link becomes ready
event_dev: bond0, event: 4
IFF_MASTER
bond0: no IPv6 routers present
<<<<cable unplug>>>>
eth1: link down
event_dev: eth1, event: 4
IFF_SLAVE
bonding: bond0: link status definitely down for interface eth1, disabling it
event_dev: bond0, event: 4
IFF_MASTER
<<<<cable plug>>>>
eth1: link up, 100Mbps, full-duplex, lpa 0xC5E1
event_dev: eth1, event: 4
IFF_SLAVE
bonding: bond0: link status definitely up for interface eth1.
bonding: bond0: making interface eth1 the new active one.
event_dev: eth1, event: 8
IFF_SLAVE
event_dev: eth1, event: 8
IFF_SLAVE
bonding: bond0: first active interface up!
event_dev: bond0, event: 4
IFF_MASTER
----
The current active slave is set by calling bond_select_active_slave() function
from bond_miimon_commit() function when the slave (eth1) link goes to state up.
I also tested this on other machine with Broadcom NetXtreme II BCM5708
1000Base-T NIC and there all works fine. The thing is that this adapter is down
and goes up after few seconds after it is enslaved.
This patch calls bond_select_active_slave() in bond_enslave() function for modes
alb and tlb and makes sure that the current active slave is set up properly even
when the slave state is already up. Tested on both systems, works fine.
Notice: The same problem can maybe also occrur in mode 8023AD but I'm unable to
test that.
Signed-off-by: Jiri Pirko <jpirko at redhat.com>
Signed-off-by: David S. Miller <davem at davemloft.net>
Cc: Jean Delvare <jdelvare at suse.de>
Signed-off-by: Greg Kroah-Hartman <gregkh at suse.de>
commit 2e06c6e67bf3bbc63f8603fe9d71106e0fab28ad
Author: Or Gerlitz <ogerlitz at voltaire.com>
Date: Sun Jun 6 04:59:16 2010 +0000
IPoIB: Fix world-writable child interface control sysfs attributes
commit 7a52b34b07122ff5f45258d47f260f8a525518f0 upstream.
Sumeet Lahorani <sumeet.lahorani at oracle.com> reported that the IPoIB
child entries are world-writable; however we don't want ordinary users
to be able to create and destroy child interfaces, so fix them to be
writable only by root.
Signed-off-by: Or Gerlitz <ogerlitz at voltaire.com>
Signed-off-by: Roland Dreier <rolandd at cisco.com>
Signed-off-by: Greg Kroah-Hartman <gregkh at suse.de>
commit 34883b011409464e6b0cf0b52a54e6b0503bd06f
Author: Darrick J. Wong <djwong at us.ibm.com>
Date: Wed Jun 30 17:45:19 2010 -0700
x86, Calgary: Limit the max PHB number to 256
commit d596043d71ff0d7b3d0bead19b1d68c55f003093 upstream.
The x3950 family can have as many as 256 PCI buses in a single system, so
change the limits to the maximum. Since there can only be 256 PCI buses in one
domain, we no longer need the BUG_ON check.
Signed-off-by: Darrick J. Wong <djwong at us.ibm.com>
LKML-Reference: <20100701004519.GQ15515 at tux1.beaverton.ibm.com>
Signed-off-by: H. Peter Anvin <hpa at zytor.com>
Signed-off-by: Greg Kroah-Hartman <gregkh at suse.de>
commit 6e992ba3c5662c42cb3b555fdf67e4dd4dcac84c
Author: Darrick J. Wong <djwong at us.ibm.com>
Date: Thu Jun 24 14:26:47 2010 -0700
x86, Calgary: Increase max PHB number
commit 499a00e92dd9a75395081f595e681629eb1eebad upstream.
Newer systems (x3950M2) can have 48 PHBs per chassis and 8
chassis, so bump the limits up and provide an explanation
of the requirements for each class.
Signed-off-by: Darrick J. Wong <djwong at us.ibm.com>
Acked-by: Muli Ben-Yehuda <muli at il.ibm.com>
Cc: Corinna Schultz <cschultz at linux.vnet.ibm.com>
LKML-Reference: <20100624212647.GI15515 at tux1.beaverton.ibm.com>
[ v2: Fixed build bug, added back PHBS_PER_CALGARY == 4 ]
Signed-off-by: Ingo Molnar <mingo at elte.hu>
Signed-off-by: Greg Kroah-Hartman <gregkh at suse.de>
commit 51fcaa5075b5996a7e5f6ea11dec855f7dcb3976
Author: Ben Hutchings <ben at decadent.org.uk>
Date: Wed Mar 24 03:36:31 2010 +0000
amd64-agp: Probe unknown AGP devices the right way
commit 6fd024893911dcb51b4a0aa71971db5ba38f7071 upstream.
The current initialisation code probes 'unsupported' AGP devices
simply by calling its own probe function. It does not lock these
devices or even check whether another driver is already bound to
them.
We must use the device core to manage this. So if the specific
device id table didn't match anything and agp_try_unsupported=1,
switch the device id table and call driver_attach() again.
Signed-off-by: Ben Hutchings <ben at decadent.org.uk>
Signed-off-by: Dave Airlie <airlied at redhat.com>
Signed-off-by: Greg Kroah-Hartman <gregkh at suse.de>
commit 4cccc4c16363508973bf6197cabd66291d2a3423
Author: Julia Lawall <julia at diku.dk>
Date: Sat May 15 11:46:12 2010 +0200
SCSI: aacraid: Eliminate use after free
commit 8a52da632ceb9d8b776494563df579e87b7b586b upstream.
The debugging code using the freed structure is moved before the kfree.
A simplified version of the semantic match that finds this problem is as
follows: (http://coccinelle.lip6.fr/)
// <smpl>
@free@
expression E;
position p;
@@
kfree at p(E)
@@
expression free.E, subE<=free.E, E1;
position free.p;
@@
kfree at p(E)
...
(
subE = E1
|
* E
)
// </smpl>
Signed-off-by: Julia Lawall <julia at diku.dk>
Signed-off-by: James Bottomley <James.Bottomley at suse.de>
commit 30b816a516ba96aa85ce0290aa63cebd3d258b72
Author: Eric Dumazet <eric.dumazet at gmail.com>
Date: Fri Jul 2 10:05:01 2010 +0200
netfilter: ip6t_REJECT: fix a dst leak in ipv6 REJECT
commit 499031ac8a3df6738f6186ded9da853e8ea18253 upstream.
We should release dst if dst->error is set.
Bug introduced in 2.6.14 by commit e104411b82f5c
([XFRM]: Always release dst_entry on error in xfrm_lookup)
Signed-off-by: Eric Dumazet <eric.dumazet at gmail.com>
Signed-off-by: Patrick McHardy <kaber at trash.net>
Signed-off-by: Greg Kroah-Hartman <gregkh at suse.de>
commit e75c279c6760282546dbc794b8368d6a8ff12c92
Author: Tim Gardner <tim.gardner at canonical.com>
Date: Tue Jun 8 11:33:02 2010 -0600
hostap: Protect against initialization interrupt
commit d6a574ff6bfb842bdb98065da053881ff527be46 upstream.
Use an irq spinlock to hold off the IRQ handler until
enough early card init is complete such that the handler
can run without faulting.
Signed-off-by: Tim Gardner <tim.gardner at canonical.com>
Signed-off-by: John W. Linville <linville at tuxdriver.com>
Signed-off-by: Greg Kroah-Hartman <gregkh at suse.de>
commit 387247ff4b68aea133a0ca440e78fb19ae3ecf16
Author: Mikael Pettersson <mikpe at it.uu.se>
Date: Tue Jul 20 18:45:14 2010 -0700
math-emu: correct test for downshifting fraction in _FP_FROM_INT()
commit f8324e20f8289dffc646d64366332e05eaacab25 upstream.
The kernel's math-emu code contains a macro _FP_FROM_INT() which is
used to convert an integer to a raw normalized floating-point value.
It does this basically in three steps:
1. Compute the exponent from the number of leading zero bits.
2. Downshift large fractions to put the MSB in the right position
for normalized fractions.
3. Upshift small fractions to put the MSB in the right position.
There is an boundary error in step 2, causing a fraction with its
MSB exactly one bit above the normalized MSB position to not be
downshifted. This results in a non-normalized raw float, which when
packed becomes a massively inaccurate representation for that input.
The impact of this depends on a number of arch-specific factors,
but it is known to have broken emulation of FXTOD instructions
on UltraSPARC III, which was originally reported as GCC bug 44631
<http://gcc.gnu.org/bugzilla/show_bug.cgi?id=44631>.
Any arch which uses math-emu to emulate conversions from integers to
same-size floats may be affected.
The fix is simple: the exponent comparison used to determine if the
fraction should be downshifted must be "<=" not "<".
I'm sending a kernel module to test this as a reply to this message.
There are also SPARC user-space test cases in the GCC bug entry.
Signed-off-by: Mikael Pettersson <mikpe at it.uu.se>
Signed-off-by: David S. Miller <davem at davemloft.net>
Signed-off-by: Greg Kroah-Hartman <gregkh at suse.de>
commit 2339fdd79dfe5f17b0b44d89a9475aa8f912be2a
Author: Brandon Philips <brandon at ifup.org>
Date: Wed Jun 16 16:21:58 2010 +0000
sky2: enable rx/tx in sky2_phy_reinit()
commit 38000a94a902e94ca8b5498f7871c6316de8957a upstream.
sky2_phy_reinit is called by the ethtool helpers sky2_set_settings,
sky2_nway_reset and sky2_set_pauseparam when netif_running.
However, at the end of sky2_phy_init GM_GP_CTRL has GM_GPCR_RX_ENA and
GM_GPCR_TX_ENA cleared. So, doing these commands causes the device to
stop working:
$ ethtool -r eth0
$ ethtool -A eth0 autoneg off
Fix this issue by enabling Rx/Tx after running sky2_phy_init in
sky2_phy_reinit.
Signed-off-by: Brandon Philips <bphilips at suse.de>
Tested-by: Brandon Philips <bphilips at suse.de>
Cc: stable at kernel.org
Tested-by: Mike McCormack <mikem at ring3k.org>
Signed-off-by: David S. Miller <davem at davemloft.net>
Signed-off-by: Greg Kroah-Hartman <gregkh at suse.de>
commit 1a9e5fa66baa4dfd6bc366fbe84b172c6da9321b
Author: Florian Fainelli <florian at openwrt.org>
Date: Sun Jun 20 22:07:48 2010 +0000
cpmac: do not leak struct net_device on phy_connect errors
commit ed770f01360b392564650bf1553ce723fa46afec upstream.
If the call to phy_connect fails, we will return directly instead of freeing
the previously allocated struct net_device.
Signed-off-by: Florian Fainelli <florian at openwrt.org>
Signed-off-by: David S. Miller <davem at davemloft.net>
Signed-off-by: Greg Kroah-Hartman <gregkh at suse.de>
commit dd3eae69495d9ad7a4424f38ec632e811f10a292
Author: Suresh Jayaraman <sjayaraman at suse.de>
Date: Wed Mar 31 12:00:03 2010 +0530
cifs: Fix a kernel BUG with remote OS/2 server (try #3)
commit 6513a81e9325d712f1bfb9a1d7b750134e49ff18 upstream.
While chasing a bug report involving a OS/2 server, I noticed the server sets
pSMBr->CountHigh to a incorrect value even in case of normal writes. This
results in 'nbytes' being computed wrongly and triggers a kernel BUG at
mm/filemap.c.
void iov_iter_advance(struct iov_iter *i, size_t bytes)
{
BUG_ON(i->count < bytes); <--- BUG here
Why the server is setting 'CountHigh' is not clear but only does so after
writing 64k bytes. Though this looks like the server bug, the client side
crash may not be acceptable.
The workaround is to mask off high 16 bits if the number of bytes written as
returned by the server is greater than the bytes requested by the client as
suggested by Jeff Layton.
Reviewed-by: Jeff Layton <jlayton at samba.org>
Signed-off-by: Suresh Jayaraman <sjayaraman at suse.de>
Signed-off-by: Steve French <sfrench at us.ibm.com>
Signed-off-by: Greg Kroah-Hartman <gregkh at suse.de>
commit 0fd85ded784c60defd59d15a6a720793b4bfcad9
Author: Jeff Layton <jlayton at redhat.com>
Date: Wed Jun 16 13:40:18 2010 -0400
cifs: remove bogus first_time check in NTLMv2 session setup code
commit 8a224d489454b7457105848610cfebebdec5638d upstream.
This bug appears to be the result of a cut-and-paste mistake from the
NTLMv1 code. The function to generate the MAC key was commented out, but
not the conditional above it. The conditional then ended up causing the
session setup key not to be copied to the buffer unless this was the
first session on the socket, and that made all but the first NTLMv2
session setup fail.
Fix this by removing the conditional and all of the commented clutter
that made it difficult to see.
Reported-by: Gunther Deschner <gdeschne at redhat.com>
Signed-off-by: Jeff Layton <jlayton at redhat.com>
Signed-off-by: Greg Kroah-Hartman <gregkh at suse.de>
commit 4fe7e0696857ed6b1980a2e5198aa4507c1fa9e9
Author: Jean Delvare <khali at linux-fr.org>
Date: Fri Jul 9 16:22:49 2010 +0200
hwmon: (coretemp) Skip duplicate CPU entries
commit d883b9f0977269d519469da72faec6a7f72cb489 upstream.
On hyper-threaded CPUs, each core appears twice in the CPU list. Skip
the second entry to avoid duplicate sensors.
Signed-off-by: Jean Delvare <khali at linux-fr.org>
Acked-by: Huaxu Wan <huaxu.wan at intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh at suse.de>
commit dccb2a9a147dbb973bca41ed67bdddf3676c77f6
Author: Jean Delvare <khali at linux-fr.org>
Date: Fri Jul 9 16:22:51 2010 +0200
hwmon: (coretemp) Properly label the sensors
commit 3f4f09b4be35d38d6e2bf22c989443e65e70fc4c upstream.
Don't assume that CPU entry number and core ID always match. It
worked in the simple cases (single CPU, no HT) but fails on
multi-CPU systems.
Signed-off-by: Jean Delvare <khali at linux-fr.org>
Acked-by: Huaxu Wan <huaxu.wan at intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh at suse.de>
commit 6b5f4c2c71c9013971c6520b6260e21a17d06882
Author: Greg Kroah-Hartman <gregkh at suse.de>
Date: Mon Jul 5 11:09:05 2010 -0700
Linux 2.6.27.48
commit 7694247af71eb2a9067c07ee716ea2ead7bd8fe2
Author: Wei Yongjun <yjwei at cn.fujitsu.com>
Date: Mon May 17 22:51:58 2010 -0700
sctp: fix append error cause to ERROR chunk correctly
commit 2e3219b5c8a2e44e0b83ae6e04f52f20a82ac0f2 upstream.
commit 5fa782c2f5ef6c2e4f04d3e228412c9b4a4c8809
sctp: Fix skb_over_panic resulting from multiple invalid \
parameter errors (CVE-2010-1173) (v4)
cause 'error cause' never be add the the ERROR chunk due to
some typo when check valid length in sctp_init_cause_fixed().
Signed-off-by: Wei Yongjun <yjwei at cn.fujitsu.com>
Reviewed-by: Neil Horman <nhorman at tuxdriver.com>
Acked-by: Vlad Yasevich <vladislav.yasevich at hp.com>
Signed-off-by: David S. Miller <davem at davemloft.net>
Signed-off-by: Greg Kroah-Hartman <gregkh at suse.de>
commit 8e3c5b14d0aa33e347569e53f42f874a83f426c5
Author: Toshiyuki Okajima <toshi.okajima at jp.fujitsu.com>
Date: Fri Apr 30 14:32:13 2010 +0100
KEYS: find_keyring_by_name() can gain access to a freed keyring
commit cea7daa3589d6b550546a8c8963599f7c1a3ae5c upstream.
find_keyring_by_name() can gain access to a keyring that has had its reference
count reduced to zero, and is thus ready to be freed. This then allows the
dead keyring to be brought back into use whilst it is being destroyed.
The following timeline illustrates the process:
|(cleaner) (user)
|
| free_user(user) sys_keyctl()
| | |
| key_put(user->session_keyring) keyctl_get_keyring_ID()
| || //=> keyring->usage = 0 |
| |schedule_work(&key_cleanup_task) lookup_user_key()
| || |
| kmem_cache_free(,user) |
| . |[KEY_SPEC_USER_KEYRING]
| . install_user_keyrings()
| . ||
| key_cleanup() [<= worker_thread()] ||
| | ||
| [spin_lock(&key_serial_lock)] |[mutex_lock(&key_user_keyr..mutex)]
| | ||
| atomic_read() == 0 ||
| |{ rb_ease(&key->serial_node,) } ||
| | ||
| [spin_unlock(&key_serial_lock)] |find_keyring_by_name()
| | |||
| keyring_destroy(keyring) ||[read_lock(&keyring_name_lock)]
| || |||
| |[write_lock(&keyring_name_lock)] ||atomic_inc(&keyring->usage)
| |. ||| *** GET freeing keyring ***
| |. ||[read_unlock(&keyring_name_lock)]
| || ||
| |list_del() |[mutex_unlock(&key_user_k..mutex)]
| || |
| |[write_unlock(&keyring_name_lock)] ** INVALID keyring is returned **
| | .
| kmem_cache_free(,keyring) .
| .
| atomic_dec(&keyring->usage)
v *** DESTROYED ***
TIME
If CONFIG_SLUB_DEBUG=y then we may see the following message generated:
=============================================================================
BUG key_jar: Poison overwritten
-----------------------------------------------------------------------------
INFO: 0xffff880197a7e200-0xffff880197a7e200. First byte 0x6a instead of 0x6b
INFO: Allocated in key_alloc+0x10b/0x35f age=25 cpu=1 pid=5086
INFO: Freed in key_cleanup+0xd0/0xd5 age=12 cpu=1 pid=10
INFO: Slab 0xffffea000592cb90 objects=16 used=2 fp=0xffff880197a7e200 flags=0x200000000000c3
INFO: Object 0xffff880197a7e200 @offset=512 fp=0xffff880197a7e300
Bytes b4 0xffff880197a7e1f0: 5a 5a 5a 5a 5a 5a 5a 5a 5a 5a 5a 5a 5a 5a 5a 5a ZZZZZZZZZZZZZZZZ
Object 0xffff880197a7e200: 6a 6b 6b 6b 6b 6b 6b 6b 6b 6b 6b 6b 6b 6b 6b 6b jkkkkkkkkkkkkkkk
Alternatively, we may see a system panic happen, such as:
BUG: unable to handle kernel NULL pointer dereference at 0000000000000001
IP: [<ffffffff810e61a3>] kmem_cache_alloc+0x5b/0xe9
PGD 6b2b4067 PUD 6a80d067 PMD 0
Oops: 0000 [#1] SMP
last sysfs file: /sys/kernel/kexec_crash_loaded
CPU 1
...
Pid: 31245, comm: su Not tainted 2.6.34-rc5-nofixed-nodebug #2 D2089/PRIMERGY
RIP: 0010:[<ffffffff810e61a3>] [<ffffffff810e61a3>] kmem_cache_alloc+0x5b/0xe9
RSP: 0018:ffff88006af3bd98 EFLAGS: 00010002
RAX: 0000000000000000 RBX: 0000000000000001 RCX: ffff88007d19900b
RDX: 0000000100000000 RSI: 00000000000080d0 RDI: ffffffff81828430
RBP: ffffffff81828430 R08: ffff88000a293750 R09: 0000000000000000
R10: 0000000000000001 R11: 0000000000100000 R12: 00000000000080d0
R13: 00000000000080d0 R14: 0000000000000296 R15: ffffffff810f20ce
FS: 00007f97116bc700(0000) GS:ffff88000a280000(0000) knlGS:0000000000000000
CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 0000000000000001 CR3: 000000006a91c000 CR4: 00000000000006e0
DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
DR3: 0000000000000000 DR6: 00000000ffff0ff0 DR7: 0000000000000400
Process su (pid: 31245, threadinfo ffff88006af3a000, task ffff8800374414c0)
Stack:
0000000512e0958e 0000000000008000 ffff880037f8d180 0000000000000001
0000000000000000 0000000000008001 ffff88007d199000 ffffffff810f20ce
0000000000008000 ffff88006af3be48 0000000000000024 ffffffff810face3
Call Trace:
[<ffffffff810f20ce>] ? get_empty_filp+0x70/0x12f
[<ffffffff810face3>] ? do_filp_open+0x145/0x590
[<ffffffff810ce208>] ? tlb_finish_mmu+0x2a/0x33
[<ffffffff810ce43c>] ? unmap_region+0xd3/0xe2
[<ffffffff810e4393>] ? virt_to_head_page+0x9/0x2d
[<ffffffff81103916>] ? alloc_fd+0x69/0x10e
[<ffffffff810ef4ed>] ? do_sys_open+0x56/0xfc
[<ffffffff81008a02>] ? system_call_fastpath+0x16/0x1b
Code: 0f 1f 44 00 00 49 89 c6 fa 66 0f 1f 44 00 00 65 4c 8b 04 25 60 e8 00 00 48 8b 45 00 49 01 c0 49 8b 18 48 85 db 74 0d 48 63 45 18 <48> 8b 04 03 49 89 00 eb 14 4c 89 f9 83 ca ff 44 89 e6 48 89 ef
RIP [<ffffffff810e61a3>] kmem_cache_alloc+0x5b/0xe9
This problem is that find_keyring_by_name does not confirm that the keyring is
valid before accepting it.
Skipping keyrings that have been reduced to a zero count seems the way to go.
To this end, use atomic_inc_not_zero() to increment the usage count and skip
the candidate keyring if that returns false.
The following script _may_ cause the bug to happen, but there's no guarantee
as the window of opportunity is small:
#!/bin/sh
LOOP=100000
USER=dummy_user
/bin/su -c "exit;" $USER || { /usr/sbin/adduser -m $USER; add=1; }
for ((i=0; i<LOOP; i++))
do
/bin/su -c "echo '$i' > /dev/null" $USER
done
(( add == 1 )) && /usr/sbin/userdel -r $USER
exit
Note that the nominated user must not be in use.
An alternative way of testing this may be:
for ((i=0; i<100000; i++))
do
keyctl session foo /bin/true || break
done >&/dev/null
as that uses a keyring named "foo" rather than relying on the user and
user-session named keyrings.
Reported-by: Toshiyuki Okajima <toshi.okajima at jp.fujitsu.com>
Signed-off-by: David Howells <dhowells at redhat.com>
Tested-by: Toshiyuki Okajima <toshi.okajima at jp.fujitsu.com>
Acked-by: Serge Hallyn <serue at us.ibm.com>
Signed-off-by: James Morris <jmorris at namei.org>
Cc: Ben Hutchings <ben at decadent.org.uk>
Cc: Chuck Ebbert <cebbert at redhat.com>
Signed-off-by: Greg Kroah-Hartman <gregkh at suse.de>
commit e24ad12540142e1ae7e24da1072e977c5b17003b
Author: Dan Carpenter <error27 at gmail.com>
Date: Mon May 17 14:42:35 2010 +0100
KEYS: Return more accurate error codes
commit 4d09ec0f705cf88a12add029c058b53f288cfaa2 upstream.
We were using the wrong variable here so the error codes weren't being returned
properly. The original code returns -ENOKEY.
Signed-off-by: Dan Carpenter <error27 at gmail.com>
Signed-off-by: David Howells <dhowells at redhat.com>
Signed-off-by: James Morris <jmorris at namei.org>
Signed-off-by: Greg Kroah-Hartman <gregkh at suse.de>
commit 648efc40754d15a7f38fc31d50bdc4e04024630d
Author: Helge Deller <deller at gmx.de>
Date: Mon May 3 20:44:21 2010 +0000
parisc: clear floating point exception flag on SIGFPE signal
commit 550f0d922286556c7ea43974bb7921effb5a5278 upstream.
Clear the floating point exception flag before returning to
user space. This is needed, else the libc trampoline handler
may hit the same SIGFPE again while building up a trampoline
to a signal handler.
Fixes debian bug #559406.
Signed-off-by: Helge Deller <deller at gmx.de>
Signed-off-by: Kyle McMartin <kyle at mcmartin.ca>
Signed-off-by: Greg Kroah-Hartman <gregkh at suse.de>
commit 670037a94e70b107a79fd9ac0f4f2c9e1d26f742
Author: Neil Horman <nhorman at tuxdriver.com>
Date: Wed Mar 3 08:31:23 2010 +0000
tipc: Fix oops on send prior to entering networked mode (v3)
commit d0021b252eaf65ca07ed14f0d66425dd9ccab9a6 upstream.
Fix TIPC to disallow sending to remote addresses prior to entering NET_MODE
user programs can oops the kernel by sending datagrams via AF_TIPC prior to
entering networked mode. The following backtrace has been observed:
ID: 13459 TASK: ffff810014640040 CPU: 0 COMMAND: "tipc-client"
[exception RIP: tipc_node_select_next_hop+90]
RIP: ffffffff8869d3c3 RSP: ffff81002d9a5ab8 RFLAGS: 00010202
RAX: 0000000000000001 RBX: 0000000000000001 RCX: 0000000000000001
RDX: 0000000000000000 RSI: 0000000000000001 RDI: 0000000001001001
RBP: 0000000001001001 R8: 0074736575716552 R9: 0000000000000000
R10: ffff81003fbd0680 R11: 00000000000000c8 R12: 0000000000000008
R13: 0000000000000001 R14: 0000000000000001 R15: ffff810015c6ca00
ORIG_RAX: ffffffffffffffff CS: 0010 SS: 0018
RIP: 0000003cbd8d49a3 RSP: 00007fffc84e0be8 RFLAGS: 00010206
RAX: 000000000000002c RBX: ffffffff8005d116 RCX: 0000000000000000
RDX: 0000000000000008 RSI: 00007fffc84e0c00 RDI: 0000000000000003
RBP: 0000000000000000 R8: 00007fffc84e0c10 R9: 0000000000000010
R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000000
R13: 00007fffc84e0d10 R14: 0000000000000000 R15: 00007fffc84e0c30
ORIG_RAX: 000000000000002c CS: 0033 SS: 002b
What happens is that, when the tipc module in inserted it enters a standalone
node mode in which communication to its own address is allowed <0.0.0> but not
to other addresses, since the appropriate data structures have not been
allocated yet (specifically the tipc_net pointer). There is nothing stopping a
client from trying to send such a message however, and if that happens, we
attempt to dereference tipc_net.zones while the pointer is still NULL, and
explode. The fix is pretty straightforward. Since these oopses all arise from
the dereference of global pointers prior to their assignment to allocated
values, and since these allocations are small (about 2k total), lets convert
these pointers to static arrays of the appropriate size. All the accesses to
these bits consider 0/NULL to be a non match when searching, so all the lookups
still work properly, and there is no longer a chance of a bad dererence
anywhere. As a bonus, this lets us eliminate the setup/teardown routines for
those pointers, and elimnates the need to preform any locking around them to
prevent access while their being allocated/freed.
I've updated the tipc_net structure to behave this way to fix the exact reported
problem, and also fixed up the tipc_bearers and media_list arrays to fix an
obvious simmilar problem that arises from issuing tipc-config commands to
manipulate bearers/links prior to entering networked mode
I've tested this for a few hours by running the sanity tests and stress test
with the tipcutils suite, and nothing has fallen over. There have been a few
lockdep warnings, but those were there before, and can be addressed later, as
they didn't actually result in any deadlock.
Signed-off-by: Neil Horman <nhorman at tuxdriver.com>
CC: Allan Stephens <allan.stephens at windriver.com>
CC: David S. Miller <davem at davemloft.net>
CC: tipc-discussion at lists.sourceforge.net
Signed-off-by: David S. Miller <davem at davemloft.net>
Signed-off-by: Greg Kroah-Hartman <gregkh at suse.de>
commit 23b5e014564bb71eb05871af019912957263f158
Author: Miklos Szeredi <mszeredi at suse.cz>
Date: Wed Feb 10 12:15:53 2010 +0100
vfs: add NOFOLLOW flag to umount(2)
commit db1f05bb85d7966b9176e293f3ceead1cb8b5d79 upstream.
Add a new UMOUNT_NOFOLLOW flag to umount(2). This is needed to prevent
symlink attacks in unprivileged unmounts (fuse, samba, ncpfs).
Additionally, return -EINVAL if an unknown flag is used (and specify
an explicitly unused flag: UMOUNT_UNUSED). This makes it possible for
the caller to determine if a flag is supported or not.
CC: Eugene Teo <eugene at redhat.com>
CC: Michael Kerrisk <mtk.manpages at gmail.com>
Signed-off-by: Miklos Szeredi <mszeredi at suse.cz>
Signed-off-by: Al Viro <viro at zeniv.linux.org.uk>
Signed-off-by: Greg Kroah-Hartman <gregkh at suse.de>
commit b1b7bf1eede2a2d954dc0e4e7db6bb94e7650f60
Author: Neil Horman <nhorman at tuxdriver.com>
Date: Wed Apr 28 10:30:59 2010 +0000
sctp: Fix skb_over_panic resulting from multiple invalid parameter errors (CVE-2010-1173) (v4)
commit 5fa782c2f5ef6c2e4f04d3e228412c9b4a4c8809 upstream.
Ok, version 4
Change Notes:
1) Minor cleanups, from Vlads notes
Summary:
Hey-
Recently, it was reported to me that the kernel could oops in the
following way:
<5> kernel BUG at net/core/skbuff.c:91!
<5> invalid operand: 0000 [#1]
<5> Modules linked in: sctp netconsole nls_utf8 autofs4 sunrpc iptable_filter
ip_tables cpufreq_powersave parport_pc lp parport vmblock(U) vsock(U) vmci(U)
vmxnet(U) vmmemctl(U) vmhgfs(U) acpiphp dm_mirror dm_mod button battery ac md5
ipv6 uhci_hcd ehci_hcd snd_ens1371 snd_rawmidi snd_seq_device snd_pcm_oss
snd_mixer_oss snd_pcm snd_timer snd_page_alloc snd_ac97_codec snd soundcore
pcnet32 mii floppy ext3 jbd ata_piix libata mptscsih mptsas mptspi mptscsi
mptbase sd_mod scsi_mod
<5> CPU: 0
<5> EIP: 0060:[<c02bff27>] Not tainted VLI
<5> EFLAGS: 00010216 (2.6.9-89.0.25.EL)
<5> EIP is at skb_over_panic+0x1f/0x2d
<5> eax: 0000002c ebx: c033f461 ecx: c0357d96 edx: c040fd44
<5> esi: c033f461 edi: df653280 ebp: 00000000 esp: c040fd40
<5> ds: 007b es: 007b ss: 0068
<5> Process swapper (pid: 0, threadinfo=c040f000 task=c0370be0)
<5> Stack: c0357d96 e0c29478 00000084 00000004 c033f461 df653280 d7883180
e0c2947d
<5> 00000000 00000080 df653490 00000004 de4f1ac0 de4f1ac0 00000004
df653490
<5> 00000001 e0c2877a 08000800 de4f1ac0 df653490 00000000 e0c29d2e
00000004
<5> Call Trace:
<5> [<e0c29478>] sctp_addto_chunk+0xb0/0x128 [sctp]
<5> [<e0c2947d>] sctp_addto_chunk+0xb5/0x128 [sctp]
<5> [<e0c2877a>] sctp_init_cause+0x3f/0x47 [sctp]
<5> [<e0c29d2e>] sctp_process_unk_param+0xac/0xb8 [sctp]
<5> [<e0c29e90>] sctp_verify_init+0xcc/0x134 [sctp]
<5> [<e0c20322>] sctp_sf_do_5_1B_init+0x83/0x28e [sctp]
<5> [<e0c25333>] sctp_do_sm+0x41/0x77 [sctp]
<5> [<c01555a4>] cache_grow+0x140/0x233
<5> [<e0c26ba1>] sctp_endpoint_bh_rcv+0xc5/0x108 [sctp]
<5> [<e0c2b863>] sctp_inq_push+0xe/0x10 [sctp]
<5> [<e0c34600>] sctp_rcv+0x454/0x509 [sctp]
<5> [<e084e017>] ipt_hook+0x17/0x1c [iptable_filter]
<5> [<c02d005e>] nf_iterate+0x40/0x81
<5> [<c02e0bb9>] ip_local_deliver_finish+0x0/0x151
<5> [<c02e0c7f>] ip_local_deliver_finish+0xc6/0x151
<5> [<c02d0362>] nf_hook_slow+0x83/0xb5
<5> [<c02e0bb2>] ip_local_deliver+0x1a2/0x1a9
<5> [<c02e0bb9>] ip_local_deliver_finish+0x0/0x151
<5> [<c02e103e>] ip_rcv+0x334/0x3b4
<5> [<c02c66fd>] netif_receive_skb+0x320/0x35b
<5> [<e0a0928b>] init_stall_timer+0x67/0x6a [uhci_hcd]
<5> [<c02c67a4>] process_backlog+0x6c/0xd9
<5> [<c02c690f>] net_rx_action+0xfe/0x1f8
<5> [<c012a7b1>] __do_softirq+0x35/0x79
<5> [<c0107efb>] handle_IRQ_event+0x0/0x4f
<5> [<c01094de>] do_softirq+0x46/0x4d
Its an skb_over_panic BUG halt that results from processing an init chunk in
which too many of its variable length parameters are in some way malformed.
The problem is in sctp_process_unk_param:
if (NULL == *errp)
*errp = sctp_make_op_error_space(asoc, chunk,
ntohs(chunk->chunk_hdr->length));
if (*errp) {
sctp_init_cause(*errp, SCTP_ERROR_UNKNOWN_PARAM,
WORD_ROUND(ntohs(param.p->length)));
sctp_addto_chunk(*errp,
WORD_ROUND(ntohs(param.p->length)),
param.v);
When we allocate an error chunk, we assume that the worst case scenario requires
that we have chunk_hdr->length data allocated, which would be correct nominally,
given that we call sctp_addto_chunk for the violating parameter. Unfortunately,
we also, in sctp_init_cause insert a sctp_errhdr_t structure into the error
chunk, so the worst case situation in which all parameters are in violation
requires chunk_hdr->length+(sizeof(sctp_errhdr_t)*param_count) bytes of data.
The result of this error is that a deliberately malformed packet sent to a
listening host can cause a remote DOS, described in CVE-2010-1173:
http://cve.mitre.org/cgi-bin/cvename.cgi?name=2010-1173
I've tested the below fix and confirmed that it fixes the issue. We move to a
strategy whereby we allocate a fixed size error chunk and ignore errors we don't
have space to report. Tested by me successfully
Signed-off-by: Neil Horman <nhorman at tuxdriver.com>
Acked-by: Vlad Yasevich <vladislav.yasevich at hp.com>
Signed-off-by: David S. Miller <davem at davemloft.net>
Signed-off-by: Greg Kroah-Hartman <gregkh at suse.de>
commit 70635511aad7493f7748aa4e42dd852dfc0eb73f
Author: Aneesh Kumar K.V <aneesh.kumar at linux.vnet.ibm.com>
Date: Fri May 28 14:27:23 2010 -0500
ext4: Implement range_cyclic in ext4_da_writepages instead of write_cache_pages
commit 2acf2c261b823d9d9ed954f348b97620297a36b5 upstream.
With delayed allocation we lock the page in write_cache_pages() and
try to build an in memory extent of contiguous blocks. This is needed
so that we can get large contiguous blocks request. If range_cyclic
mode is enabled, write_cache_pages() will loop back to the 0 index if
no I/O has been done yet, and try to start writing from the beginning
of the range. That causes an attempt to take the page lock of lower
index page while holding the page lock of higher index page, which can
cause a dead lock with another writeback thread.
The solution is to implement the range_cyclic behavior in
ext4_da_writepages() instead.
http://bugzilla.kernel.org/show_bug.cgi?id=12579
Signed-off-by: Aneesh Kumar K.V <aneesh.kumar at linux.vnet.ibm.com>
Signed-off-by: "Theodore Ts'o" <tytso at mit.edu>
Signed-off-by: Jayson R. King <dev at jaysonking.com>
Signed-off-by: Greg Kroah-Hartman <gregkh at suse.de>
commit f4a4420cd056a7dcc4134dd6df6314d0960ba39f
Author: Aneesh Kumar K.V <aneesh.kumar at linux.vnet.ibm.com>
Date: Fri May 28 14:26:57 2010 -0500
ext4: Fix file fragmentation during large file write.
commit 22208dedbd7626e5fc4339c417f8d24cc21f79d7 upstream.
The range_cyclic writeback mode uses the address_space writeback_index
as the start index for writeback. With delayed allocation we were
updating writeback_index wrongly resulting in highly fragmented file.
This patch reduces the number of extents reduced from 4000 to 27 for a
3GB file.
Signed-off-by: Aneesh Kumar K.V <aneesh.kumar at linux.vnet.ibm.com>
Signed-off-by: Theodore Ts'o <tytso at mit.edu>
[dev at jaysonking.com: Some changed lines from the original version of this patch were dropped, since they were rolled up with another cherry-picked patch applied to 2.6.27.y earlier.]
[dev at jaysonking.com: Use of wbc->no_nrwrite_index_update was dropped, since write_cache_pages_da() implies it.]
Signed-off-by: Jayson R. King <dev at jaysonking.com>
Signed-off-by: Greg Kroah-Hartman <gregkh at suse.de>
commit 14dd35b4c54e223de27d1161985eeef847a130ee
Author: Theodore Ts'o <tytso at mit.edu>
Date: Fri May 28 14:26:25 2010 -0500
ext4: Use our own write_cache_pages()
commit 8e48dcfbd7c0892b4cfd064d682cc4c95a29df32 upstream.
Make a copy of write_cache_pages() for the benefit of
ext4_da_writepages(). This allows us to simplify the code some, and
will allow us to further customize the code in future patches.
There are some nasty hacks in write_cache_pages(), which Linus has
(correctly) characterized as vile. I've just copied it into
write_cache_pages_da(), without trying to clean those bits up lest I
break something in the ext4's delalloc implementation, which is a bit
fragile right now. This will allow Dave Chinner to clean up
write_cache_pages() in mm/page-writeback.c, without worrying about
breaking ext4. Eventually write_cache_pages_da() will go away when I
rewrite ext4's delayed allocation and create a general
ext4_writepages() which is used for all of ext4's writeback. Until
now this is the lowest risk way to clean up the core
write_cache_pages() function.
Signed-off-by: "Theodore Ts'o" <tytso at mit.edu>
Cc: Dave Chinner <david at fromorbit.com>
[dev at jaysonking.com: Dropped the hunks which reverted the use of no_nrwrite_index_update, since those lines weren't ever created on 2.6.27.y]
[dev at jaysonking.com: Copied from 2.6.27.y's version of write_cache_pages(), plus the changes to it from patch "vfs: Add no_nrwrite_index_update writeback control flag"]
Signed-off-by: Jayson R. King <dev at jaysonking.com>
Signed-off-by: Greg Kroah-Hartman <gregkh at suse.de>
commit 805fe57fb54f9f66256a2c0f81b11abeb83b0142
Author: Eric Sandeen <sandeen at redhat.com>
Date: Sun May 16 01:00:00 2010 -0400
ext4: check s_log_groups_per_flex in online resize code
commit 42007efd569f1cf3bfb9a61da60ef6c2179508ca upstream.
If groups_per_flex < 2, sbi->s_flex_groups[] doesn't get filled out,
and every other access to this first tests s_log_groups_per_flex;
same thing needs to happen in resize or we'll wander off into
a null pointer when doing an online resize of the file system.
Thanks to Christoph Biedl, who came up with the trivial testcase:
# truncate --size 128M fsfile
# mkfs.ext3 -F fsfile
# tune2fs -O extents,uninit_bg,dir_index,flex_bg,huge_file,dir_nlink,extra_isize fsfile
# e2fsck -yDf -C0 fsfile
# truncate --size 132M fsfile
# losetup /dev/loop0 fsfile
# mount /dev/loop0 mnt
# resize2fs -p /dev/loop0
https://bugzilla.kernel.org/show_bug.cgi?id=13549
Reported-by: Alessandro Polverini <alex at nibbles.it>
Test-case-by: Christoph Biedl <bugzilla.kernel.bpeb at manchmal.in-ulm.de>
Signed-off-by: Eric Sandeen <sandeen at redhat.com>
Signed-off-by: "Theodore Ts'o" <tytso at mit.edu>
Signed-off-by: Greg Kroah-Hartman <gregkh at suse.de>
commit f5cdcd6bb088de9c8ce7b63a2487f7064305c03c
Author: Richard Kennedy <richard at rsk.demon.co.uk>
Date: Thu May 27 10:22:28 2010 +0100
gconfig: fix build failure on fedora 13
commit cbab05f041a4cff6ca15856bdd35238b282b64eb upstream.
Making gconfig fails on fedora 13 as the linker cannot resolve dlsym.
Adding libdl to the link command fixes this.
make shows this error :-
/usr/bin/ld: scripts/kconfig/kconfig_load.o: undefined reference to symbol 'dlsym@@GLIBC_2.2.5'
/usr/bin/ld: note: 'dlsym@@GLIBC_2.2.5' is defined in DSO /lib64/libdl.so.2 so try adding it to the linker command line
/lib64/libdl.so.2: could not read symbols: Invalid operation
tested on x86_64 fedora 13.
Signed-off-by: Richard Kennedy <richard at rsk.demon.co.uk>
Reviewed-by: WANG Cong <xiyou.wangcong at gmail.com>
Signed-off-by: Andrew Morton <akpm at linux-foundation.org>
Signed-off-by: Michal Marek <mmarek at suse.cz>
Signed-off-by: Greg Kroah-Hartman <gregkh at suse.de>
commit 310c0ab725ad1950bb1592306d583a60e9f000fb
Author: Jiri Kosina <jkosina at suse.cz>
Date: Wed May 26 14:43:53 2010 -0700
ipmi: handle run_to_completion properly in deliver_recv_msg()
commit a747c5abc329611220f16df0bb4cf0ca4a7fdf0c upstream.
If run_to_completion flag is set, it means that we are running in a
single-threaded mode, and thus no locks are held.
This fixes a deadlock when IPMI notifier is being called during panic.
Signed-off-by: Jiri Kosina <jkosina at suse.cz>
Acked-by: Corey Minyard <minyard at acm.org>
Signed-off-by: Andrew Morton <akpm at linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds at linux-foundation.org>
Signed-off-by: Greg Kroah-Hartman <gregkh at suse.de>
commit 9b698b5535523995150a8bebad483d541c5ab9cf
Author: Jeff Moyer <jmoyer at redhat.com>
Date: Wed May 26 11:49:40 2010 -0400
do_generic_file_read: clear page errors when issuing a fresh read of the page
commit 91803b499cca2fe558abad709ce83dc896b80950 upstream.
I/O errors can happen due to temporary failures, like multipath
errors or losing network contact with the iSCSI server. Because
of that, the VM will retry readpage on the page.
However, do_generic_file_read does not clear PG_error. This
causes the system to be unable to actually use the data in the
page cache page, even if the subsequent readpage completes
successfully!
The function filemap_fault has had a ClearPageError before
readpage forever. This patch simply adds the same to
do_generic_file_read.
Signed-off-by: Jeff Moyer <jmoyer at redhat.com>
Signed-off-by: Rik van Riel <riel at redhat.com>
Acked-by: Larry Woodman <lwoodman at redhat.com>
Signed-off-by: Linus Torvalds <torvalds at linux-foundation.org>
Signed-off-by: Greg Kroah-Hartman <gregkh at suse.de>
commit 789242303b22bddc1cd03a0c013bfdc091556d83
Author: Dan Williams <dan.j.williams at intel.com>
Date: Wed May 12 08:25:37 2010 +1000
md: set mddev readonly flag on blkdev BLKROSET ioctl
commit e2218350465e7e0931676b4849b594c978437bce upstream.
When the user sets the block device to readwrite then the mddev should
follow suit. Otherwise, the BUG_ON in md_write_start() will be set to
trigger.
The reverse direction, setting mddev->ro to match a set readonly
request, can be ignored because the blkdev level readonly flag precludes
the need to have mddev->ro set correctly. Nevermind the fact that
setting mddev->ro to 1 may fail if the array is in use.
Signed-off-by: Dan Williams <dan.j.williams at intel.com>
Signed-off-by: NeilBrown <neilb at suse.de>
Signed-off-by: Greg Kroah-Hartman <gregkh at suse.de>
commit f2a41e6807357c237ec2bbd61e79cb1558e48b8a
Author: NeilBrown <neilb at suse.de>
Date: Sat May 8 08:20:17 2010 +1000
md: Fix read balancing in RAID1 and RAID10 on drives > 2TB
commit af3a2cd6b8a479345786e7fe5e199ad2f6240e56 upstream.
read_balance uses a "unsigned long" for a sector number which
will get truncated beyond 2TB.
This will cause read-balancing to be non-optimal, and can cause
data to be read from the 'wrong' branch during a resync. This has a
very small chance of returning wrong data.
Reported-by: Jordan Russell <jr-list-2010 at quo.to>
Signed-off-by: NeilBrown <neilb at suse.de>
Signed-off-by: Greg Kroah-Hartman <gregkh at suse.de>
commit faeb8ec4bf76f163317e9b885c5eb35ee960f705
Author: NeilBrown <neilb at suse.de>
Date: Tue May 18 15:27:13 2010 +1000
md/raid1: fix counting of write targets.
commit 964147d5c86d63be79b442c30f3783d49860c078 upstream.
There is a very small race window when writing to a
RAID1 such that if a device is marked faulty at exactly the wrong
time, the write-in-progress will not be sent to the device,
but the bitmap (if present) will be updated to say that
the write was sent.
Then if the device turned out to still be usable as was re-added
to the array, the bitmap-based-resync would skip resyncing that
block, possibly leading to corruption. This would only be a problem
if no further writes were issued to that area of the device (i.e.
that bitmap chunk).
Suitable for any pending -stable kernel.
Signed-off-by: NeilBrown <neilb at suse.de>
Signed-off-by: Greg Kroah-Hartman <gregkh at suse.de>
commit 43bee391355ad45021579511963dfb46d6e810fb
Author: Denis Kirjanov <dkirjanov at hera.kernel.org>
Date: Tue Jun 1 15:43:34 2010 -0400
powerpc/oprofile: fix potential buffer overrun in op_model_cell.c
commit 238c1a78c957f3dc7cb848b161dcf4805793ed56 upstream.
Fix potential initial_lfsr buffer overrun.
Writing past the end of the buffer could happen when index == ENTRIES
Signed-off-by: Denis Kirjanov <dkirjanov at kernel.org>
Signed-off-by: Robert Richter <robert.richter at amd.com>
Signed-off-by: Greg Kroah-Hartman <gregkh at suse.de>
commit 21dfd35afeaf03c5fe4409d1021b2cc888c11326
Author: Michael Neuling <mikey at neuling.org>
Date: Wed Apr 28 13:39:41 2010 +0000
powerpc/pseries: Make query_cpu_stopped callable outside hotplug cpu
commit f8b67691828321f5c85bb853283aa101ae673130 upstream.
This moves query_cpu_stopped() out of the hotplug cpu code and into
smp.c so it can called in other places and renames it to
smp_query_cpu_stopped().
It also cleans up the return values by adding some #defines
Signed-off-by: Michael Neuling <mikey at neuling.org>
Signed-off-by: Benjamin Herrenschmidt <benh at kernel.crashing.org>
Signed-off-by: Greg Kroah-Hartman <gregkh at suse.de>
commit 4be4e01c7d844bbb7b88a2bcf931ac00408289c3
Author: Michael Neuling <mikey at neuling.org>
Date: Wed Apr 28 13:39:41 2010 +0000
powerpc/pseries: Only call start-cpu when a CPU is stopped
commit aef40e87d866355ffd279ab21021de733242d0d5 upstream.
Currently we always call start-cpu irrespective of if the CPU is
stopped or not. Unfortunatley on POWER7, firmware seems to not like
start-cpu being called when a cpu already been started. This was not
the case on POWER6 and earlier.
This patch checks to see if the CPU is stopped or not via an
query-cpu-stopped-state call, and only calls start-cpu on CPUs which
are stopped.
This fixes a bug with kexec on POWER7 on PHYP where only the primary
thread would make it to the second kernel.
Reported-by: Ankita Garg <ankita at linux.vnet.ibm.com>
Signed-off-by: Michael Neuling <mikey at neuling.org>
Signed-off-by: Benjamin Herrenschmidt <benh at kernel.crashing.org>
Signed-off-by: Greg Kroah-Hartman <gregkh at suse.de>
commit ae7aff994d0934d86a3278a65889f34629c778a7
Author: Jeff Mahoney <jeffm at suse.com>
Date: Wed Mar 17 10:55:51 2010 +0000
powerpc: Fix handling of strncmp with zero len
commit 637a99022fb119b90fb281715d13172f0394fc12 upstream.
Commit 0119536c, which added the assembly version of strncmp to
powerpc, mentions that it adds two instructions to the version from
boot/string.S to allow it to handle len=0. Unfortunately, it doesn't
always return 0 when that is the case. The length is passed in r5, but
the return value is passed back in r3. In certain cases, this will
happen to work. Otherwise it will pass back the address of the first
string as the return value.
This patch lifts the len <= 0 handling code from memcpy to handle that
case.
Reported by: Christian_Sellars at symantec.com
Signed-off-by: Jeff Mahoney <jeffm at suse.com>
Signed-off-by: Benjamin Herrenschmidt <benh at kernel.crashing.org>
Signed-off-by: Greg Kroah-Hartman <gregkh at suse.de>
commit 88102a584bf833892493a514430bcebd53d8f017
Author: Andreas Bombe <aeb at debian.org>
Date: Mon May 17 23:12:46 2010 -0700
ARCNET: Limit com20020 PCI ID matches for SOHARD cards
commit e7971c80a8e0299f91272ad8e8ac4167623e1862 upstream.
The SH SOHARD ARCNET cards are implemented using generic PLX Technology
PCI<->IOBus bridges. Subvendor and subdevice IDs were not specified,
causing the driver to attach to any such bridge and likely crash the
system by attempting to initialize an unrelated device.
Fix by specifying subvendor and subdevice according to the values found
in the PCI-ID Repository at http://pci-ids.ucw.cz/ .
Signed-off-by: Andreas Bombe <aeb at debian.org>
Signed-off-by: David S. Miller <davem at davemloft.net>
Signed-off-by: Greg Kroah-Hartman <gregkh at suse.de>
commit b9cb946fac3288e7a35571525ef09946e2ba6d7f
Author: Pavel Emelyanov <xemul at openvz.org>
Date: Fri May 14 15:33:36 2010 +0400
NFSD: don't report compiled-out versions as present
commit 15ddb4aec54422ead137b03ea4e9b3f5db3f7cc2 upstream.
The /proc/fs/nfsd/versions file calls nfsd_vers() to check whether
the particular nfsd version is present/available. The problem is
that once I turn off e.g. NFSD-V4 this call returns -1 which is
true from the callers POV which is wrong.
The proposal is to report false in that case.
The bug has existed since 6658d3a7bbfd1768 "[PATCH] knfsd: remove
nfsd_versbits as intermediate storage for desired versions".
Signed-off-by: Pavel Emelyanov <xemul at openvz.org>
Acked-by: NeilBrown <neilb at suse.de>
Signed-off-by: J. Bruce Fields <bfields at citi.umich.edu>
Signed-off-by: Greg Kroah-Hartman <gregkh at suse.de>
commit 90bfd720bcda3a04e22be93b66138a117c0bcf28
Author: Tejun Heo <tj at kernel.org>
Date: Wed May 19 15:38:58 2010 +0200
libata: disable ATAPI AN by default
commit e7ecd435692ca9bde9d124be30b3a26e672ea6c2 upstream.
There are ATAPI devices which raise AN when hit by commands issued by
open(). This leads to infinite loop of AN -> MEDIA_CHANGE uevent ->
udev open() to check media -> AN.
Both ACS and SerialATA standards don't define in which case ATAPI
devices are supposed to raise or not raise AN. They both list media
insertion event as a possible use case for ATAPI ANs but there is no
clear description of what constitutes such events. As such, it seems
a bit too naive to export ANs directly to userland as MEDIA_CHANGE
events without further verification (which should behave similarly to
windows as it apparently is the only thing that some hardware vendors
are testing against).
This patch adds libata.atapi_an module parameter and disables ATAPI AN
by default for now.
Signed-off-by: Tejun Heo <tj at kernel.org>
Cc: Kay Sievers <kay.sievers at vrfy.org>
Cc: Nick Bowler <nbowler at elliptictech.com>
Cc: David Zeuthen <david at fubar.dk>
Signed-off-by: Jeff Garzik <jgarzik at redhat.com>
Signed-off-by: Greg Kroah-Hartman <gregkh at suse.de>
commit a9a5c1f8a527bd150ce044b8c9acce1c97c557a4
Author: Greg Kroah-Hartman <gregkh at suse.de>
Date: Wed May 26 14:27:20 2010 -0700
Linux 2.6.27.47
commit c0ac27236d86f07e1b24126bd7ee0eeb9008eaaf
Author: Junjiro R. Okajima <hooanon05 at yahoo.co.jp>
Date: Tue Dec 2 10:31:46 2008 -0800
nfsd: fix vm overcommit crash fix #2
commit 1b79cd04fab80be61dcd2732e2423aafde9a4c1c upstream.
The previous patch from Alan Cox ("nfsd: fix vm overcommit crash",
commit 731572d39fcd3498702eda4600db4c43d51e0b26) fixed the problem where
knfsd crashes on exported shmemfs objects and strict overcommit is set.
But the patch forgot supporting the case when CONFIG_SECURITY is
disabled.
This patch copies a part of his fix which is mainly for detecting a bug
earlier.
Acked-by: James Morris <jmorris at namei.org>
Signed-off-by: Alan Cox <alan at redhat.com>
Signed-off-by: Junjiro R. Okajima <hooanon05 at yahoo.co.jp>
Signed-off-by: Andrew Morton <akpm at linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds at linux-foundation.org>
Signed-off-by: Greg Kroah-Hartman <gregkh at suse.de>
commit 3f955fe683ffdda7fd68e0b61779001cb9b50011
Author: Alan Cox <alan at redhat.com>
Date: Wed Oct 29 14:01:20 2008 -0700
nfsd: fix vm overcommit crash
commit 731572d39fcd3498702eda4600db4c43d51e0b26 upstream.
Junjiro R. Okajima reported a problem where knfsd crashes if you are
using it to export shmemfs objects and run strict overcommit. In this
situation the current->mm based modifier to the overcommit goes through a
NULL pointer.
We could simply check for NULL and skip the modifier but we've caught
other real bugs in the past from mm being NULL here - cases where we did
need a valid mm set up (eg the exec bug about a year ago).
To preserve the checks and get the logic we want shuffle the checking
around and add a new helper to the vm_ security wrappers
Also fix a current->mm reference in nommu that should use the passed mm
[akpm at linux-foundation.org: coding-style fixes]
[akpm at linux-foundation.org: fix build]
Reported-by: Junjiro R. Okajima <hooanon05 at yahoo.co.jp>
Acked-by: James Morris <jmorris at namei.org>
Signed-off-by: Alan Cox <alan at redhat.com>
Signed-off-by: Andrew Morton <akpm at linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds at linux-foundation.org>
Signed-off-by: Greg Kroah-Hartman <gregkh at suse.de>
commit 0ce0dd4ec9890eefb7b656c74bc5256c60626a85
Author: Jean Delvare <khali at linux-fr.org>
Date: Fri Feb 5 17:48:13 2010 +0100
i2c-tiny-usb: Fix on big-endian systems
commit 1c010ff8912cbc08d80e865aab9c32b6b00c527d upstream.
The functionality bit vector is always returned as a little-endian
32-bit number by the device, so it must be byte-swapped to the host
endianness.
On the other hand, the delay value is handled by the USB stack, so no
byte swapping is needed on our side.
This fixes bug #15105:
http://bugzilla.kernel.org/show_bug.cgi?id=15105
Reported-by: Jens Richter <jens at richter-stutensee.de>
Signed-off-by: Jean Delvare <khali at linux-fr.org>
Tested-by: Jens Richter <jens at richter-stutensee.de>
Cc: Till Harbaum <till at harbaum.org>
Signed-off-by: Greg Kroah-Hartman <gregkh at suse.de>
commit ae3936ed1af0224a2d38d6b6b1ee62fb8f4c3a5c
Author: Jean Delvare <khali at linux-fr.org>
Date: Sat Mar 13 20:56:53 2010 +0100
i2c-i801: Don't use the block buffer for I2C block writes
commit c074c39d62306efa5ba7c69c1a1531bc7333d252 upstream.
Experience has shown that the block buffer can only be used for SMBus
(not I2C) block transactions, even though the datasheet doesn't
mention this limitation.
Reported-by: Felix Rubinstein <felixru at gmail.com>
Signed-off-by: Jean Delvare <khali at linux-fr.org>
Cc: Oleg Ryjkov <oryjkov at gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh at suse.de>
commit 6dfbed036e8116f31015d33377cba2c156889dd2
Author: Jean Delvare <khali at linux-fr.org>
Date: Fri Feb 5 19:58:36 2010 +0100
hwmon: (w83781d) Request I/O ports individually for probing
commit b0bcdd3cd0adb85a7686b396ba50493871b1135c upstream.
Different motherboards have different PNP declarations for
W83781D/W83782D chips. Some declare the whole range of I/O ports (8
ports), some declare only the useful ports (2 ports at offset 5) and
some declare fancy ranges, for example 4 ports at offset 4. To
properly handle all cases, request all ports individually for probing.
After we have determined that we really have a W83781D or W83782D
chip, the useful port range will be requested again, as a single
block.
I did not see a board which needs this yet, but I know of one for lm78
driver and I'd like to keep the logic of these two drivers in sync.
Signed-off-by: Jean Delvare <khali at linux-fr.org>
Signed-off-by: Greg Kroah-Hartman <gregkh at suse.de>
commit 60f30297ff9403dec857f23292bc82ecdc5b4a57
Author: Tom Tucker <tom at opengridcomputing.com>
Date: Mon Jan 5 15:21:19 2009 -0600
svc: Clean up deferred requests on transport destruction
commit 22945e4a1c7454c97f5d8aee1ef526c83fef3223 upstream.
A race between svc_revisit and svc_delete_xprt can result in
deferred requests holding references on a transport that can never be
recovered because dead transports are not enqueued for subsequent
processing.
Check for XPT_DEAD in revisit to clean up completing deferrals on a dead
transport and sweep a transport's deferred queue to do the same for queued
but unprocessed deferrals.
Signed-off-by: Tom Tucker <tom at opengridcomputing.com>
Signed-off-by: J. Bruce Fields <bfields at citi.umich.edu>
Cc: roma1390 <roma1390 at gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh at suse.de>
commit ce58c0ab4bcf38482dfc095af0c4ed55a5a88698
Author: Tejun Heo <tj at kernel.org>
Date: Thu Jan 14 16:18:09 2010 +0900
libata: retry FS IOs even if it has failed with AC_ERR_INVALID
commit 534ead709235b967b659947c55d9130873a432c4 upstream.
libata currently doesn't retry if a command fails with AC_ERR_INVALID
assuming that retrying won't get it any further even if retried.
However, a failure may be classified as invalid through hardware
glitch (incorrect reading of the error register or firmware bug) and
there isn't whole lot to gain by not retrying as actually invalid
commands will be failed immediately. Also, commands serving FS IOs
are extremely unlikely to be invalid. Retry FS IOs even if it's
marked invalid.
Transient and incorrect invalid failure was seen while debugging
firmware related issue on Samsung n130 on bko#14314.
http://bugzilla.kernel.org/show_bug.cgi?id=14314
Signed-off-by: Tejun Heo <tj at kernel.org>
Reported-by: Johannes Stezenbach <js at sig21.net>
Signed-off-by: Jeff Garzik <jgarzik at redhat.com>
Signed-off-by: Greg Kroah-Hartman <gregkh at suse.de>
commit bf3d0e3c484815ea68c671a4da71fd2e01cc1ac6
Author: Jeff Garzik <jeff at garzik.org>
Date: Thu Apr 22 21:59:13 2010 -0400
libata: ensure NCQ error result taskfile is fully initialized before returning it via qc->result_tf.
commit a09bf4cd53b8ab000197ef81f15d50f29ecf973c upstream.
Signed-off-by: Jeff Garzik <jgarzik at redhat.com>
Signed-off-by: Greg Kroah-Hartman <gregkh at suse.de>
commit ba1531fcc11249827750298495c27e34f869b629
Author: Jean Delvare <khali at linux-fr.org>
Date: Tue May 4 11:09:28 2010 +0200
i2c: Fix probing of FSC hardware monitoring chips
commit b1d4b390ea4bb480e65974ce522a04022608a8df upstream.
Some FSC hardware monitoring chips (Syleus at least) doesn't like
quick writes we typically use to probe for I2C chips. Use a regular
byte read instead for the address they live at (0x73). These are the
only known chips living at this address on PC systems.
For clarity, this fix should not be needed for kernels 2.6.30 and
later, as we started instantiating the hwmon devices explicitly based
on DMI data. Still, this fix is valuable in the following two cases:
* Support for recent FSC chips on older kernels. The DMI-based device
instantiation is more difficult to backport than the device support
itself.
* Case where the DMI-based device instantiation fails, whatever the
reason. We fall back to probing in that case, so it should work.
This fixes kernel bug #15634:
https://bugzilla.kernel.org/show_bug.cgi?id=15634
Signed-off-by: Jean Delvare <khali at linux-fr.org>
Acked-by: Hans de Goede <hdegoede at redhat.com>
Signed-off-by: Greg Kroah-Hartman <gregkh at suse.de>
commit e3f8d35996e73d5192c33ce5e6f11b4770a7062d
Author: Chuck Lever <chuck.lever at oracle.com>
Date: Thu Apr 22 15:35:56 2010 -0400
NFS: rsize and wsize settings ignored on v4 mounts
commit 356e76b855bdbfd8d1c5e75bcf0c6bf0dfe83496 upstream.
NFSv4 mounts ignore the rsize and wsize mount options, and always use
the default transfer size for both. This seems to be because all
NFSv4 mounts are now cloned, and the cloning logic doesn't copy the
rsize and wsize settings from the parent nfs_server.
I tested Fedora's 2.6.32.11-99 and it seems to have this problem as
well, so I'm guessing that .33, .32, and perhaps older kernels have
this issue as well.
Signed-off-by: Chuck Lever <chuck.lever at oracle.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust at netapp.com>
Signed-off-by: Greg Kroah-Hartman <gregkh at suse.de>
commit 5ea176dcda8200cce3ca9e208fba5ab49ebb786d
Author: Al Viro <viro at ZenIV.linux.org.uk>
Date: Thu Apr 29 03:10:43 2010 +0100
nfs d_revalidate() is too trigger-happy with d_drop()
commit d9e80b7de91db05c1c4d2e5ebbfd70b3b3ba0e0f upstream.
If dentry found stale happens to be a root of disconnected tree, we
can't d_drop() it; its d_hash is actually part of s_anon and d_drop()
would simply hide it from shrink_dcache_for_umount(), leading to
all sorts of fun, including busy inodes on umount and oopsen after
that.
Bug had been there since at least 2006 (commit c636eb already has it),
so it's definitely -stable fodder.
Signed-off-by: Al Viro <viro at zeniv.linux.org.uk>
Signed-off-by: Linus Torvalds <torvalds at linux-foundation.org>
Signed-off-by: Greg Kroah-Hartman <gregkh at suse.de>
commit d130b918879aa06a82cfac3bec5ec88e79a05f30
Author: Dan Carpenter <error27 at gmail.com>
Date: Thu Apr 22 12:00:52 2010 +0200
USB: fix testing the wrong variable in fs_create_by_name()
commit fa7fe7af146a7b613e36a311eefbbfb5555325d1 upstream.
There is a typo here. We should be testing "*dentry" which was just
assigned instead of "dentry". This could result in dereferencing an
ERR_PTR inside either usbfs_mkdir() or usbfs_create().
Signed-off-by: Dan Carpenter <error27 at gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh at suse.de>
commit dc116e1abdbfe4afc934e62c42f1963806469e6b
Author: Neil Brown <neilb at suse.de>
Date: Tue Apr 20 12:16:52 2010 +1000
nfsd4: bug in read_buf
commit 2bc3c1179c781b359d4f2f3439cb3df72afc17fc upstream.
When read_buf is called to move over to the next page in the pagelist
of an NFSv4 request, it sets argp->end to essentially a random
number, certainly not an address within the page which argp->p now
points to. So subsequent calls to READ_BUF will think there is much
more than a page of spare space (the cast to u32 ensures an unsigned
comparison) so we can expect to fall off the end of the second
page.
We never encountered thsi in testing because typically the only
operations which use more than two pages are write-like operations,
which have their own decoding logic. Something like a getattr after a
write may cross a page boundary, but it would be very unusual for it to
cross another boundary after that.
Signed-off-by: J. Bruce Fields <bfields at citi.umich.edu>
Signed-off-by: Greg Kroah-Hartman <gregkh at suse.de>
commit 843447c62b771a9ad12f0e7f4a791804b4cc99f5
Author: Suresh Siddha <suresh.b.siddha at intel.com>
Date: Thu Apr 22 11:47:51 2010 +0200
clockevent: Prevent dead lock on clockevents_lock
This is a merge of two mainline commits, intended
for stable at kernel.org submission for 2.6.27 kernel.
commit f833bab87fca5c3ce13778421b1365845843b976
and
commit 918aae42aa9b611a3663b16ae849fdedc67c2292
Changelog of both:
Currently clockevents_notify() is called with interrupts enabled at
some places and interrupts disabled at some other places.
This results in a deadlock in this scenario.
cpu A holds clockevents_lock in clockevents_notify() with irqs enabled
cpu B waits for clockevents_lock in clockevents_notify() with irqs disabled
cpu C doing set_mtrr() which will try to rendezvous of all the cpus.
This will result in C and A come to the rendezvous point and waiting
for B. B is stuck forever waiting for the spinlock and thus not
reaching the rendezvous point.
Fix the clockevents code so that clockevents_lock is taken with
interrupts disabled and thus avoid the above deadlock.
Also call lapic_timer_propagate_broadcast() on the destination cpu so
that we avoid calling smp_call_function() in the clockevents notifier
chain.
This issue left us wondering if we need to change the MTRR rendezvous
logic to use stop machine logic (instead of smp_call_function) or add
a check in spinlock debug code to see if there are other spinlocks
which gets taken under both interrupts enabled/disabled conditions.
Signed-off-by: Suresh Siddha <suresh.b.siddha at intel.com>
Cc: "Brown Len" <len.brown at intel.com>
Cc: stable at kernel.org
LKML-Reference: <1250544899.2709.210.camel at sbs-t61.sc.intel.com>
Signed-off-by: Thomas Gleixner <tglx at linutronix.de>
I got following warning on ia64 box:
In function 'acpi_processor_power_verify':
642: warning: passing argument 2 of 'smp_call_function_single' from
incompatible pointer type
This smp_call_function_single() was introduced by a commit
f833bab87fca5c3ce13778421b1365845843b976:
The problem is that the lapic_timer_propagate_broadcast() has 2 versions:
One is real code that modified in the above commit, and the other is NOP
code that used when !ARCH_APICTIMER_STOPS_ON_C3:
static void lapic_timer_propagate_broadcast(struct acpi_processor *pr) { }
So I got warning because of !ARCH_APICTIMER_STOPS_ON_C3.
We really want to do nothing here on !ARCH_APICTIMER_STOPS_ON_C3, so
modify lapic_timer_propagate_broadcast() of real version to use
smp_call_function_single() in it.
Signed-off-by: Hidetoshi Seto <seto.hidetoshi at jp.fujitsu.com>
Acked-by: Suresh Siddha <suresh.b.siddha at intel.com>
Signed-off-by: Len Brown <len.brown at intel.com>
Signed-off-by: Thomas Renninger <trenn at suse.de>
Signed-off-by: Greg Kroah-Hartman <gregkh at suse.de>
commit 0851f4563b9e0770d4b3c071e605cb5e150c6ed3
Author: Wang Sheng-Hui <crosslonelyover at gmail.com>
Date: Tue Apr 13 21:04:10 2010 +0800
trace: Fix inappropriate substraction on tracing_pages_allocated in trace_free_page()
[No matching upstream git commit id as it was fixed differently due to a
rewrite of the tracing code there.]
For normal case, the code in trace_free_page() do once more substraction
on tracing_pages_allocated, but for CONFIG_TRACER_MAX_TRACE Â it doesn't
take the freed page into account. That's not consistent with
trace_alloc_page(). Well, for there are no message related with this,
so we cannot observe its incorrect state when the kernel doesn't define
"CONFIG_TRACER_MAX_TRACE". If you add some pr_info() as
trace_alloc_page(), you may notice it.
Cc: Steven Rostedt <rostedt at goodmis.org>
Cc: Frederic Weisbecker <fweisbec at gmail.com>
Cc: Ingo Molnar <mingo at redhat.com>
Cc: Li Zefan <lizf at cn.fujitsu.com>
Signed-off-by: Wang Sheng-Hui <crosslonelyover at gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh at suse.de>
commit 4531e534fec25888d8645ef9b2ecf6146e96c2a7
Author: Tomas Henzl <thenzl at redhat.com>
Date: Thu Feb 11 18:01:50 2010 +0100
megaraid_sas: fix for 32bit apps
commit b3dc1a212e5167984616445990c76056034f8eeb upstream.
It looks like this patch -
commit 7b2519afa1abd1b9f63aa1e90879307842422dae
Author: Yang, Bo <Bo.Yang at lsi.com>
Date: Tue Oct 6 14:52:20 2009 -0600
[SCSI] megaraid_sas: fix 64 bit sense pointer truncation
has caused a problem for 32bit programs with 64bit os -
http://bugzilla.kernel.org/show_bug.cgi?id=15001
fix by converting the user space 32bit pointer to a 64 bit one when
needed.
[jejb: fix up some 64 bit warnings]
Signed-off-by: Tomas Henzl <thenzl at redhat.com>
Cc: Bo Yang <Bo.Yang at lsi.com>
Signed-off-by: James Bottomley <James.Bottomley at suse.de>
Signed-off-by: Greg Kroah-Hartman <gregkh at suse.de>
commit 1ae9213b109c56470b79df5af1e36e780916eb57
Author: Oleg Nesterov <oleg at redhat.com>
Date: Fri Apr 2 18:05:12 2010 +0200
tty: release_one_tty() forgets to put pids
commit 6da8d866d0d39e9509ff826660f6a86a6757c966 upstream.
release_one_tty(tty) can be called when tty still has a reference
to pgrp/session. In this case we leak the pid.
Signed-off-by: Oleg Nesterov <oleg at redhat.com>
Reported-by: Catalin Marinas <catalin.marinas at arm.com>
Reported-and-tested-by: Tetsuo Handa <penguin-kernel at I-love.SAKURA.ne.jp>
Acked-by: Linus Torvalds <torvalds at linux-foundation.org>
Acked-by: Eric W. Biederman <ebiederm at xmission.com>
Signed-off-by: Linus Torvalds <torvalds at linux-foundation.org>
Signed-off-by: Greg Kroah-Hartman <gregkh at suse.de>
commit c18cb57f81d42eb408fa7f0fb15b9f4f3f9998fb
Author: Aneesh Kumar K.V <aneesh.kumar at linux.vnet.ibm.com>
Date: Mon Mar 15 20:26:02 2010 -0400
vfs: Remove the range_cont writeback mode.
commit 74baaaaec8b4f22e1ae279f5ecca4ff705b28912 upstream.
Ext4 was the only user of range_cont writeback mode and ext4 switched
to a different method. So remove the range_cont mode which is not used
in the kernel.
Signed-off-by: Aneesh Kumar K.V <aneesh.kumar at linux.vnet.ibm.com>
Signed-off-by: "Theodore Ts'o" <tytso at mit.edu>
CC: linux-fsdevel at vger.kernel.org
Signed-off-by: Jayson R. King <dev at jaysonking.com>
Signed-off-by: Theodore Ts'o <tytso at mit.edu>
Signed-off-by: Greg Kroah-Hartman <gregkh at suse.de>
commit c5b9b87a471f1226978d2dcca15e5fd72ac07af5
Author: Aneesh Kumar K.V <aneesh.kumar at linux.vnet.ibm.com>
Date: Mon Mar 15 20:26:01 2010 -0400
ext4: Use tag dirty lookup during mpage_da_submit_io
commit af6f029d3836eb7264cd3fbb13a6baf0e5fdb5ea upstream.
This enables us to drop the range_cont writeback mode
use from ext4_da_writepages.
Signed-off-by: Aneesh Kumar K.V <aneesh.kumar at linux.vnet.ibm.com>
Signed-off-by: Jayson R. King <dev at jaysonking.com>
Signed-off-by: Theodore Ts'o <tytso at mit.edu>
Signed-off-by: Greg Kroah-Hartman <gregkh at suse.de>
commit df104d2bff4a2d6cf32c29aa599c79d8009fe1a7
Author: Aneesh Kumar K.V <aneesh.kumar at linux.vnet.ibm.com>
Date: Mon Mar 15 20:26:00 2010 -0400
ext4: Retry block allocation if we have free blocks left
commit df22291ff0fde0d350cf15dac3e5cc33ac528875 upstream.
When we truncate files, the meta-data blocks released are not reused
untill we commit the truncate transaction. That means delayed get_block
request will return ENOSPC even if we have free blocks left. Force a
journal commit and retry block allocation if we get ENOSPC with free
blocks left.
Signed-off-by: Aneesh Kumar K.V <aneesh.kumar at linux.vnet.ibm.com>
Signed-off-by: Mingming Cao <cmm at us.ibm.com>
Signed-off-by: "Theodore Ts'o" <tytso at mit.edu>
Signed-off-by: Jayson R. King <dev at jaysonking.com>
Signed-off-by: Theodore Ts'o <tytso at mit.edu>
Signed-off-by: Greg Kroah-Hartman <gregkh at suse.de>
commit 8afab7e6fc2a9cedba2d0d3663046c140ef6d60b
Author: Aneesh Kumar K.V <aneesh.kumar at linux.vnet.ibm.com>
Date: Mon Mar 15 20:25:59 2010 -0400
ext4: Retry block reservation
commit 030ba6bc67b4f2bc5cd174f57785a1745c929abe upstream.
During block reservation if we don't have enough blocks left, retry
block reservation with smaller block counts. This makes sure we try
fallocate and DIO with smaller request size and don't fail early. The
delayed allocation reservation cannot try with smaller block count. So
retry block reservation to handle temporary disk full conditions. Also
print free blocks details if we fail block allocation during writepages.
Signed-off-by: Aneesh Kumar K.V <aneesh.kumar at linux.vnet.ibm.com>
Signed-off-by: Mingming Cao <cmm at us.ibm.com>
Signed-off-by: "Theodore Ts'o" <tytso at mit.edu>
Signed-off-by: Jayson R. King <dev at jaysonking.com>
Signed-off-by: Theodore Ts'o <tytso at mit.edu>
Signed-off-by: Greg Kroah-Hartman <gregkh at suse.de>
commit afb4e5de9ec8ca49e2f4a043117b39dbb94d6227
Author: Aneesh Kumar K.V <aneesh.kumar at linux.vnet.ibm.com>
Date: Mon Mar 15 20:25:58 2010 -0400
ext4: Add percpu dirty block accounting.
commit 6bc6e63fcd7dac9e633ea29f1fddd9580ab28f3f upstream.
This patch adds dirty block accounting using percpu_counters. Delayed
allocation block reservation is now done by updating dirty block
counter. In a later patch we switch to non delalloc mode if the
filesystem free blocks is greater than 150% of total filesystem dirty
blocks
Signed-off-by: Aneesh Kumar K.V <aneesh.kumar at linux.vnet.ibm.com>
Signed-off-by: Mingming Cao<cmm at us.ibm.com>
Signed-off-by: "Theodore Ts'o" <tytso at mit.edu>
Signed-off-by: Jayson R. King <dev at jaysonking.com>
Signed-off-by: Theodore Ts'o <tytso at mit.edu>
Signed-off-by: Greg Kroah-Hartman <gregkh at suse.de>
commit 05b6ea26438ab615144075c14a484d0d7940934f
Author: Aneesh Kumar K.V <aneesh.kumar at linux.vnet.ibm.com>
Date: Mon Mar 15 20:25:57 2010 -0400
ext4: Make sure all the block allocation paths reserve blocks
commit a30d542a0035b886ffaafd0057ced0a2b28c3a4f upstream.
With delayed allocation we need to make sure block are reserved before
we attempt to allocate them. Otherwise we get block allocation failure
(ENOSPC) during writepages which cannot be handled. This would mean
silent data loss (We do a printk stating data will be lost). This patch
updates the DIO and fallocate code path to do block reservation before
block allocation. This is needed to make sure parallel DIO and fallocate
request doesn't take block out of delayed reserve space.
When free blocks count go below a threshold we switch to a slow patch
which looks at other CPU's accumulated percpu counter values.
Signed-off-by: Aneesh Kumar K.V <aneesh.kumar at linux.vnet.ibm.com>
Signed-off-by: "Theodore Ts'o" <tytso at mit.edu>
Signed-off-by: Jayson R. King <dev at jaysonking.com>
Signed-off-by: Theodore Ts'o <tytso at mit.edu>
Signed-off-by: Greg Kroah-Hartman <gregkh at suse.de>
commit ac6016e3a8c7967cf8e3fe9102a9b87d7092b4bf
Author: Mingming Cao <cmm at us.ibm.com>
Date: Mon Mar 15 20:25:56 2010 -0400
percpu counter: clean up percpu_counter_sum_and_set()
commit 1f7c14c62ce63805f9574664a6c6de3633d4a354 upstream.
percpu_counter_sum_and_set() and percpu_counter_sum() is the same except
the former updates the global counter after accounting. Since we are
taking the fbc->lock to calculate the precise value of the counter in
percpu_counter_sum() anyway, it should simply set fbc->count too, as the
percpu_counter_sum_and_set() does.
This patch merges these two interfaces into one.
Signed-off-by: Mingming Cao <cmm at us.ibm.com>
Acked-by: Peter Zijlstra <a.p.zijlstra at chello.nl>
Cc: <linux-ext4 at vger.kernel.org>
Signed-off-by: Andrew Morton <akpm at linux-foundation.org>
Signed-off-by: "Theodore Ts'o" <tytso at mit.edu>
Signed-off-by: Jayson R. King <dev at jaysonking.com>
Signed-off-by: Theodore Ts'o <tytso at mit.edu>
commit ee39e52e834ebfd523980bd518943ae4ca340868
Author: Aneesh Kumar K.V <aneesh.kumar at linux.vnet.ibm.com>
Date: Mon Mar 15 20:25:55 2010 -0400
ext4: invalidate pages if delalloc block allocation fails.
commit c4a0c46ec92c194c873232b88debce4e1a448483 upstream.
We are a bit agressive in invalidating all the pages. But
it is ok because we really don't know why the block allocation
failed and it is better to come of the writeback path
so that user can look for more info.
Signed-off-by: Aneesh Kumar K.V <aneesh.kumar at linux.vnet.ibm.com>
Signed-off-by: Jayson R. King <dev at jaysonking.com>
Signed-off-by: Theodore Ts'o <tytso at mit.edu>
Signed-off-by: Greg Kroah-Hartman <gregkh at suse.de>
commit 8a63de3a1462918dcba19f19ba0304284654a193
Author: Dan Carpenter <error27 at gmail.com>
Date: Tue Apr 6 19:31:26 2010 +0300
ALSA: mixart: range checking proc file
commit b0cc58a25d04160d39a80e436847eaa2fbc5aa09 upstream.
The original code doesn't take into consideration that the value of
MIXART_BA0_SIZE - pos can be less than zero which would lead to a large
unsigned value for "count".
Also I moved the check that read size is a multiple of 4 bytes below
the code that adjusts "count".
Signed-off-by: Dan Carpenter <error27 at gmail.com>
Acked-by: Linus Torvalds <torvalds at linux-foundation.org>
Signed-off-by: Takashi Iwai <tiwai at suse.de>
Signed-off-by: Greg Kroah-Hartman <gregkh at suse.de>
commit ce8838c66d56085122fb275c1f7d3821245fca54
Author: Greg Kroah-Hartman <gregkh at suse.de>
Date: Thu Apr 1 15:53:33 2010 -0700
Linux 2.6.27.46
commit afcb843f52a4db224bc5f138e136253205feffa3
Author: Dean Nelson <dnelson at redhat.com>
Date: Mon Mar 29 22:03:00 2010 +0200
hwmon: (coretemp) Add missing newline to dev_warn() message
commit 4d7a5644e4adfafe76c2bd8ee168e3f3b5dae3a8 upstream.
Add missing newline to dev_warn() message string. This is more of an issue
with older kernels that don't automatically add a newline if it was missing
from the end of the previous line.
Signed-off-by: Dean Nelson <dnelson at redhat.com>
Signed-off-by: Jean Delvare <khali at linux-fr.org>
Signed-off-by: Greg Kroah-Hartman <gregkh at suse.de>
commit aaaa549b386fdd80b93b447541f42b313b103f95
Author: Alan Stern <stern at rowland.harvard.edu>
Date: Sat Mar 6 15:04:03 2010 -0500
USB: fix usbfs regression
commit 7152b592593b9d48b33f8997b1dfd6df9143f7ec upstream.
This patch (as1352) fixes a bug in the way isochronous input data is
returned to userspace for usbfs transfers. The entire buffer must be
copied, not just the first actual_length bytes, because the individual
packets will be discontiguous if any of them are short.
Reported-by: Markus Rechberger <mrechberger at gmail.com>
Signed-off-by: Alan Stern <stern at rowland.harvard.edu>
Signed-off-by: Greg Kroah-Hartman <gregkh at suse.de>
commit e3dc90e7cd7328ffae169ba41500d50aa1c893d3
Author: KOSAKI Motohiro <kosaki.motohiro at jp.fujitsu.com>
Date: Tue Mar 23 13:35:32 2010 -0700
tmpfs: cleanup mpol_parse_str()
commit 926f2ae04f183098cf9a30521776fb2759c8afeb upstream.
mpol_parse_str() made lots 'err' variable related bug. Because it is ugly
and reviewing unfriendly.
This patch simplifies it.
Signed-off-by: KOSAKI Motohiro <kosaki.motohiro at jp.fujitsu.com>
Cc: Ravikiran Thirumalai <kiran at scalex86.org>
Cc: Christoph Lameter <cl at linux-foundation.org>
Cc: Mel Gorman <mel at csn.ul.ie>
Acked-by: Lee Schermerhorn <lee.schermerhorn at hp.com>
Cc: Hugh Dickins <hugh.dickins at tiscali.co.uk>
Signed-off-by: Andrew Morton <akpm at linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds at linux-foundation.org>
Signed-off-by: Greg Kroah-Hartman <gregkh at suse.de>
commit 46a1c81e34c152179c287d87e763b6938e9e7914
Author: KOSAKI Motohiro <kosaki.motohiro at jp.fujitsu.com>
Date: Tue Mar 23 13:35:33 2010 -0700
doc: add the documentation for mpol=local
commit 5574169613b40b85d6f4c67208fa4846b897a0a1 upstream.
commit 3f226aa1c (mempolicy: support mpol=local tmpfs mount option) added
new mpol=local mount option. but it didn't add a documentation.
This patch does it.
Signed-off-by: KOSAKI Motohiro <kosaki.motohiro at jp.fujitsu.com>
Cc: Ravikiran Thirumalai <kiran at scalex86.org>
Cc: Christoph Lameter <cl at linux-foundation.org>
Cc: Mel Gorman <mel at csn.ul.ie>
Acked-by: Lee Schermerhorn <lee.schermerhorn at hp.com>
Cc: Hugh Dickins <hugh.dickins at tiscali.co.uk>
Signed-off-by: Andrew Morton <akpm at linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds at linux-foundation.org>
Signed-off-by: Greg Kroah-Hartman <gregkh at suse.de>
commit 7ec7aa7a91a38a36b392059e7307e09d0136d1e4
Author: KOSAKI Motohiro <kosaki.motohiro at jp.fujitsu.com>
Date: Tue Mar 23 13:35:31 2010 -0700
tmpfs: handle MPOL_LOCAL mount option properly
commit 12821f5fb942e795f8009ece14bde868893bd811 upstream.
commit 71fe804b6d5 (mempolicy: use struct mempolicy pointer in
shmem_sb_info) added mpol=local mount option. but its feature is broken
since it was born. because such code always return 1 (i.e. mount
failure).
This patch fixes it.
Signed-off-by: KOSAKI Motohiro <kosaki.motohiro at jp.fujitsu.com>
Cc: Ravikiran Thirumalai <kiran at scalex86.org>
Cc: Christoph Lameter <cl at linux-foundation.org>
Cc: Mel Gorman <mel at csn.ul.ie>
Acked-by: Lee Schermerhorn <lee.schermerhorn at hp.com>
Cc: Hugh Dickins <hugh.dickins at tiscali.co.uk>
Signed-off-by: Andrew Morton <akpm at linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds at linux-foundation.org>
Signed-off-by: Greg Kroah-Hartman <gregkh at suse.de>
commit 6b200155aefee405a74149df740fb92b10d727bc
Author: KOSAKI Motohiro <kosaki.motohiro at jp.fujitsu.com>
Date: Tue Mar 23 13:35:30 2010 -0700
tmpfs: mpol=bind:0 don't cause mount error.
commit d69b2e63e9172afb4d07c305601b79a55509ac4c upstream.
Currently, following mount operation cause mount error.
% mount -t tmpfs -ompol=bind:0 none /tmp
Because commit 71fe804b6d5 (mempolicy: use struct mempolicy pointer in
shmem_sb_info) corrupted MPOL_BIND parse code.
This patch restore the needed one.
Signed-off-by: KOSAKI Motohiro <kosaki.motohiro at jp.fujitsu.com>
Cc: Ravikiran Thirumalai <kiran at scalex86.org>
Cc: Christoph Lameter <cl at linux-foundation.org>
Cc: Mel Gorman <mel at csn.ul.ie>
Acked-by: Lee Schermerhorn <lee.schermerhorn at hp.com>
Cc: Hugh Dickins <hugh.dickins at tiscali.co.uk>
Signed-off-by: Andrew Morton <akpm at linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds at linux-foundation.org>
Signed-off-by: Greg Kroah-Hartman <gregkh at suse.de>
commit 6af438190daa4b53c1570c09244f99f2db447f78
Author: Ravikiran G Thirumalai <kiran at scalex86.org>
Date: Tue Mar 23 13:35:28 2010 -0700
tmpfs: fix oops on mounts with mpol=default
commit 413b43deab8377819aba1dbad2abf0c15d59b491 upstream.
Fix an 'oops' when a tmpfs mount point is mounted with the mpol=default
mempolicy.
Upon remounting a tmpfs mount point with 'mpol=default' option, the mount
code crashed with a null pointer dereference. The initial problem report
was on 2.6.27, but the problem exists in mainline 2.6.34-rc as well. On
examining the code, we see that mpol_new returns NULL if default mempolicy
was requested. This 'NULL' mempolicy is accessed to store the node mask
resulting in oops.
The following patch fixes it.
Signed-off-by: Ravikiran Thirumalai <kiran at scalex86.org>
Signed-off-by: KOSAKI Motohiro <kosaki.motohiro at jp.fujitsu.com>
Cc: Christoph Lameter <cl at linux-foundation.org>
Cc: Mel Gorman <mel at csn.ul.ie>
Acked-by: Lee Schermerhorn <lee.schermerhorn at hp.com>
Cc: Hugh Dickins <hugh.dickins at tiscali.co.uk>
Signed-off-by: Andrew Morton <akpm at linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds at linux-foundation.org>
Signed-off-by: Greg Kroah-Hartman <gregkh at suse.de>
commit 68cd8670ee25e0d6b0a7472672dcd3843f70a1c6
Author: Stanislav Brabec <sbrabec at suse.cz>
Date: Tue Dec 8 21:00:22 2009 -0800
b44 WOL setup: one-bit-off stack corruption kernel panic fix
commit e0188829cb724e7d12a2d4e343b368ff1d6e1471 upstream.
About 50% of shutdowns of b44 Ethernet adapter ends by kernel panic
with kernels compiled with stack-protector.
Checking b44_magic_pattern() return values, one call of
b44_magic_pattern() returns 127. It means, that set_bit(128, pmask)
was called on line 1509. It means that bit 0 of 17th byte of pmask was
overwritten. But pmask has only 16 bytes. Stack corruption happens.
It seems that set_bit() on line 1509 always writes one bit off.
The fix does not only solve the stack corruption, but also makes Wake
On LAN working on my onboard B44 on Asus A7V-333X mainboard.
It seems that this problem affects all kernel versions since commit
725ad800 ([PATCH] b44: add wol for old nic) on 2006-06-20.
Signed-off-by: Stanislav Brabec <sbrabec at suse.cz>
Signed-off-by: David S. Miller <davem at davemloft.net>
Signed-off-by: Greg Kroah-Hartman <gregkh at suse.de>
commit 8314375b8f9447e74221ad2116121ca40cbfc1bb
Author: Francesco Lavra <francescolavra at interfree.it>
Date: Thu Dec 31 08:47:11 2009 -0300
V4L/DVB (13961): em28xx-dvb: fix memleak in dvb_fini()
commit 19f48cb105b7fa18d0dcab435919a3a29b7a7c4c upstream.
this patch fixes a memory leak which occurs when an em28xx card with DVB
extension is unplugged or its DVB extension driver is unloaded. In
dvb_fini(), dev->dvb must be freed before being set to NULL, as is done
in dvb_init() in case of error.
Note that this bug is also present in the latest stable kernel release.
Signed-off-by: Francesco Lavra <francescolavra at interfree.it>
Signed-off-by: Mauro Carvalho Chehab <mchehab at redhat.com>
Signed-off-by: Greg Kroah-Hartman <gregkh at suse.de>
commit 9776e39de376c2dd759f1d8d7f568111139b330e
Author: Jiri Pirko <jpirko at redhat.com>
Date: Fri Apr 24 03:57:29 2009 +0000
bonding: ignore updelay param when there is no active slave
commit 41f8910040639eb106b1a5b5301aab79ecde4940 upstream.
Pointed out by Sean E. Millichamp.
Quote from Documentation/networking/bonding.txt:
"Note that when a bonding interface has no active links, the
driver will immediately reuse the first link that goes up, even if the
updelay parameter has been specified (the updelay is ignored in this
case). If there are slave interfaces waiting for the updelay timeout
to expire, the interface that first went into that state will be
immediately reused. This reduces down time of the network if the
value of updelay has been overestimated, and since this occurs only in
cases with no connectivity, there is no additional penalty for
ignoring the updelay."
This patch actually changes the behaviour in this way.
Signed-off-by: Jiri Pirko <jpirko at redhat.com>
Signed-off-by: David S. Miller <davem at davemloft.net>
Cc: Jean Delvare <jdelvare at suse.de>
Signed-off-by: Greg Kroah-Hartman <gregkh at suse.de>
commit cf1322b5bad073b5c39e2915d7cdbb15b6874321
Author: Neil Horman <nhorman at tuxdriver.com>
Date: Fri Mar 5 13:44:16 2010 -0800
coredump: suppress uid comparison test if core output files are pipes
commit 76595f79d76fbe6267a51b3a866a028d150f06d4 upstream.
Modify uid check in do_coredump so as to not apply it in the case of
pipes.
This just got noticed in testing. The end of do_coredump validates the
uid of the inode for the created file against the uid of the crashing
process to ensure that no one can pre-create a core file with different
ownership and grab the information contained in the core when they
shouldn' tbe able to. This causes failures when using pipes for a core
dumps if the crashing process is not root, which is the uid of the pipe
when it is created.
The fix is simple. Since the check for matching uid's isn't relevant for
pipes (a process can't create a pipe that the uermodehelper code will open
anyway), we can just just skip it in the event ispipe is non-zero
Reverts a pipe-affecting change which was accidentally made in
: commit c46f739dd39db3b07ab5deb4e3ec81e1c04a91af
: Author: Ingo Molnar <mingo at elte.hu>
: AuthorDate: Wed Nov 28 13:59:18 2007 +0100
: Commit: Linus Torvalds <torvalds at woody.linux-foundation.org>
: CommitDate: Wed Nov 28 10:58:01 2007 -0800
:
: vfs: coredumping fix
Signed-off-by: Neil Horman <nhorman at tuxdriver.com>
Cc: Andi Kleen <andi at firstfloor.org>
Cc: Oleg Nesterov <oleg at redhat.com>
Cc: Alan Cox <alan at lxorguk.ukuu.org.uk>
Cc: Al Viro <viro at zeniv.linux.org.uk>
Cc: Ingo Molnar <mingo at elte.hu>
Signed-off-by: Andrew Morton <akpm at linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds at linux-foundation.org>
Cc: maximilian attems <max at stro.at>
Signed-off-by: Greg Kroah-Hartman <gregkh at suse.de>
commit 4e6d03059d809ab08dd75c19203ccbdd94a58273
Author: Jiri Slaby <jslaby at suse.cz>
Date: Wed Feb 10 20:55:16 2010 +0100
x86, ia32_aout: do not kill argument mapping
commit 318f6b228ba88a394ef560efc1bfe028ad5ae6b6 upstream.
Do not set current->mm->mmap to NULL in 32-bit emulation on 64-bit
load_aout_binary after flush_old_exec as it would destroy already
set brpm mapping with arguments.
Introduced by b6a2fea39318e43fee84fa7b0b90d68bed92d2ba
mm: variable length argument support
where the argument mapping in bprm was added.
[ hpa: this is a regression from 2.6.22... time to kill a.out? ]
Signed-off-by: Jiri Slaby <jslaby at suse.cz>
LKML-Reference: <1265831716-7668-1-git-send-email-jslaby at suse.cz>
Cc: Ingo Molnar <mingo at elte.hu>
Cc: Thomas Gleixner <tglx at linutronix.de>
Cc: Ollie Wild <aaw at google.com>
Cc: x86 at kernel.org
Signed-off-by: H. Peter Anvin <hpa at zytor.com>
Signed-off-by: Greg Kroah-Hartman <gregkh at suse.de>
commit 9e7ad5ae520b5cc242f7840bb8750a02c7c590c1
Author: Al Viro <viro at ZenIV.linux.org.uk>
Date: Tue Feb 16 18:09:36 2010 +0000
fix LOOKUP_FOLLOW on automount "symlinks"
commit ac278a9c505092dd82077a2446af8f9fc0d9c095 upstream.
Make sure that automount "symlinks" are followed regardless of LOOKUP_FOLLOW;
it should have no effect on them.
Signed-off-by: Al Viro <viro at zeniv.linux.org.uk>
Signed-off-by: Greg Kroah-Hartman <gregkh at suse.de>
commit de2a051fb93911ce098404a46d46e5a1da652561
Author: Marcelo Tosatti <mtosatti at redhat.com>
Date: Thu Apr 16 08:30:44 2009 -0300
KVM: x86: check for cr3 validity in ioctl_set_sregs
commit 59839dfff5eabca01cc4e20b45797a60a80af8cb upstream.
Matt T. Yourst notes that kvm_arch_vcpu_ioctl_set_sregs lacks validity
checking for the new cr3 value:
"Userspace callers of KVM_SET_SREGS can pass a bogus value of cr3 to
the kernel. This will trigger a NULL pointer access in gfn_to_rmap()
when userspace next tries to call KVM_RUN on the affected VCPU and kvm
attempts to activate the new non-existent page table root.
This happens since kvm only validates that cr3 points to a valid guest
physical memory page when code *inside* the guest sets cr3. However, kvm
currently trusts the userspace caller (e.g. QEMU) on the host machine to
always supply a valid page table root, rather than properly validating
it along with the rest of the reloaded guest state."
http://sourceforge.net/tracker/?func=detail&atid=893831&aid=2687641&group_id=180599
Check for a valid cr3 address in kvm_arch_vcpu_ioctl_set_sregs, triple
fault in case of failure.
Signed-off-by: Marcelo Tosatti <mtosatti at redhat.com>
Signed-off-by: Avi Kivity <avi at redhat.com>
Signed-off-by: Greg Kroah-Hartman <gregkh at suse.de>
commit 1f059b24d2a9f0f15766d0f77acaaa3c8a163a3a
Author: Michael Buesch <mb at bu3sch.de>
Date: Mon Jul 20 22:58:44 2009 +0000
parisc: isa-eeprom - Fix loff_t usage
commit 6b4dbcd86a9d464057fcc7abe4d0574093071fcc upstream.
loff_t is a signed type. If userspace passes a negative ppos, the "count"
range check is weakened. "count"s bigger than HPEE_MAX_LENGTH will pass the check.
Also, if ppos is negative, the readb(eisa_eeprom_addr + *ppos) will poke in random
memory.
Signed-off-by: Michael Buesch <mb at bu3sch.de>
Signed-off-by: Helge Deller <deller at gmx.de>
Signed-off-by: Greg Kroah-Hartman <gregkh at suse.de>
commit 910e88a0698da1f483603c603b04c780cb87dd08
Author: Eric Dumazet <eric.dumazet at gmail.com>
Date: Wed Sep 2 02:40:09 2009 +0000
tc: Fix unitialized kernel memory leak
commit 16ebb5e0b36ceadc8186f71d68b0c4fa4b6e781b upstream.
Three bytes of uninitialized kernel memory are currently leaked to user
Signed-off-by: Eric Dumazet <eric.dumazet at gmail.com>
Reviewed-by: Jiri Pirko <jpirko at redhat.com>
Signed-off-by: David S. Miller <davem at davemloft.net>
Signed-off-by: Greg Kroah-Hartman <gregkh at suse.de>
commit 3807f5c31534736f3c23630b11bd4a259eaa46fd
Author: Ben Hutchings <ben at decadent.org.uk>
Date: Sun Aug 23 16:59:04 2009 +0100
drm/r128: Add test for initialisation to all ioctls that require it
commit 7dc482dfeeeefcfd000d4271c4626937406756d7 upstream.
Almost all r128's private ioctls require that the CCE state has
already been initialised. However, most do not test that this has
been done, and will proceed to dereference a null pointer. This may
result in a security vulnerability, since some ioctls are
unprivileged.
This adds a macro for the common initialisation test and changes all
ioctl implementations that require prior initialisation to use that
macro.
Also, r128_do_init_cce() does not test that the CCE state has not
been initialised already. Repeated initialisation may lead to a crash
or resource leak. This adds that test.
Signed-off-by: Ben Hutchings <ben at decadent.org.uk>
Signed-off-by: Dave Airlie <airlied at redhat.com>
Signed-off-by: Greg Kroah-Hartman <gregkh at suse.de>
commit 0a32cd3d6adbe5cbfdfb411e1b1fccceec75e36a
Author: Avi Kivity <avi at redhat.com>
Date: Tue Sep 1 12:03:25 2009 +0300
KVM: VMX: Check cpl before emulating debug register access
commit 0a79b009525b160081d75cef5dbf45817956acf2 upstream.
Debug registers may only be accessed from cpl 0. Unfortunately, vmx will
code to emulate the instruction even though it was issued from guest
userspace, possibly leading to an unexpected trap later.
Signed-off-by: Avi Kivity <avi at redhat.com>
Signed-off-by: Marcelo Tosatti <mtosatti at redhat.com>
Signed-off-by: Greg Kroah-Hartman <gregkh at suse.de>
commit a3edfd184017a67b30080c1e0d46b91d7306b3d9
Author: Theodore Ts'o <tytso at mit.edu>
Date: Mon Jul 27 23:09:47 2009 -0400
ext4: Avoid null pointer dereference when decoding EROFS w/o a journal
commit 78f1ddbb498283c2445c11b0dfa666424c301803 upstream.
We need to check to make sure a journal is present before checking the
journal flags in ext4_decode_error().
Signed-off-by: Eric Sesterhenn <eric.sesterhenn at lsexperts.de>
Signed-off-by: "Theodore Ts'o" <tytso at mit.edu>
Signed-off-by: Greg Kroah-Hartman <gregkh at suse.de>
commit 8b91c56fd291670294e197bc2d25ba3844cc53fa
Author: Avi Kivity <avi at redhat.com>
Date: Tue Nov 24 13:20:15 2009 +0200
KVM: x86 emulator: limit instructions to 15 bytes
commit eb3c79e64a70fb8f7473e30fa07e89c1ecc2c9bb upstream
[ <cebbert at redhat.com>: backport to 2.6.27 ]
While we are never normally passed an instruction that exceeds 15 bytes,
smp games can cause us to attempt to interpret one, which will cause
large latencies in non-preempt hosts.
Signed-off-by: Avi Kivity <avi at redhat.com>
Signed-off-by: Greg Kroah-Hartman <gregkh at suse.de>
commit 6758be586812a95341a06b04e780fdde9c252ba2
Author: Alan Stern <stern at rowland.harvard.edu>
Date: Fri Jul 31 10:41:40 2009 -0400
USB: EHCI: fix counting of transaction error retries
commit ef4638f955f2c4a667c8af20769d03f5ed3781ca upstream.
This patch (as1274) simplifies the counting of transaction-error
retries. Now we will count up from 0 to QH_XACTERR_MAX instead of
down from QH_XACTERR_MAX to 0.
The patch also fixes a small bug: qh->xacterr was not getting
initialized for interrupt endpoints.
Signed-off-by: Alan Stern <stern at rowland.harvard.edu>
Tested-by: Matthijs Kooijman <matthijs at stdin.nl>
Cc: Reinoud Koornstra <koornstra at hp.com>
Signed-off-by: Greg Kroah-Hartman <gregkh at suse.de>
commit ffa27b3ddf12952737dcf30b83e56e3da4e965bd
Author: Linus Torvalds <torvalds at linux-foundation.org>
Date: Tue Feb 16 12:35:07 2010 -0800
USB: usbfs: properly clean up the as structure on error paths
commit ddeee0b2eec2a51b0712b04de4b39e7bec892a53 upstream.
I notice that the processcompl_compat() function seems to be leaking the
'struct async *as' in the error paths.
I think that the calling convention is fundamentally buggered. The
caller is the one that did the "reap_as()" to get the as thing, the
caller should be the one to free it too.
Freeing it in the caller also means that it very clearly always gets
freed, and avoids the need for any "free in the error case too".
From: Linus Torvalds <torvalds at linux-foundation.org>
Cc: Alan Stern <stern at rowland.harvard.edu>
Cc: Marcus Meissner <meissner at suse.de>
Signed-off-by: Greg Kroah-Hartman <gregkh at suse.de>
commit 00400c98e8359ec5ecec199d66fbf25b944b8834
Author: Greg KH <greg at kroah.com>
Date: Mon Feb 15 09:37:46 2010 -0800
USB: usbfs: only copy the actual data received
commit d4a4683ca054ed9917dfc9e3ff0f7ecf74ad90d6 upstream.
We need to only copy the data received by the device to userspace, not
the whole kernel buffer, which can contain "stale" data.
Thanks to Marcus Meissner for pointing this out and testing the fix.
Reported-by: Marcus Meissner <meissner at suse.de>
Tested-by: Marcus Meissner <meissner at suse.de>
Cc: Alan Stern <stern at rowland.harvard.edu>
Cc: Linus Torvalds <torvalds at linux-foundation.org>
Signed-off-by: Greg Kroah-Hartman <gregkh at suse.de>
commit 540a2c33ffcf76ac804668839b89d79b9cc3b831
Author: Dick Hollenbeck <dick at softplc.com>
Date: Wed Dec 9 12:31:34 2009 -0800
serial: 8250: add serial transmitter fully empty test
commit bca476139d2ded86be146dae09b06e22548b67f3 upstream.
When controlling an industrial radio modem it can be necessary to
manipulate the handshake lines in order to control the radio modem's
transmitter, from userspace.
The transmitter should not be turned off before all characters have been
transmitted. serial8250_tx_empty() was reporting that all characters were
transmitted before they actually were.
===
Discovered in parallel with more testing and analysis by Kees Schoenmakers
as follows:
I ran into an NetMos 9835 serial pci board which behaves a little
different than the standard. This type of expansion board is very common.
"Standard" 8250 compatible devices clear the 'UART_LST_TEMT" bit together
with the "UART_LSR_THRE" bit when writing data to the device.
The NetMos device does it slightly different
I believe that the TEMT bit is coupled to the shift register. The problem
is that after writing data to the device and very quickly after that one
does call serial8250_tx_empty, it returns the wrong information.
My patch makes the test more robust (and solves the problem) and it does
not affect the already correct devices.
Alan:
We may yet need to quirk this but now we know which chips we have a
way to do that should we find this breaks some other 8250 clone with
dodgy THRE.
Signed-off-by: Dick Hollenbeck <dick at softplc.com>
Signed-off-by: Alan Cox <alan at linux.intel.com>
Cc: Kees Schoenmakers <k.schoenmakers at sigmae.nl>
Signed-off-by: Andrew Morton <akpm at linux-foundation.org>
Signed-off-by: Greg Kroah-Hartman <gregkh at suse.de>
commit 582ab0e1e4004672a389a10e2d1ed27edaff119e
Author: Thadeu Lima de Souza Cascardo <cascardo at holoscopio.com>
Date: Sun Jan 17 19:05:58 2010 +0100
i2c: Do not use device name after device_unregister
In Linus' tree:
http://git.kernel.org/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commit;h=c556752109794a5ff199b80a1673336b4df8433a
dev_dbg outputs dev_name, which is released with device_unregister. This bug
resulted in output like this:
i2c Xy2�0: adapter [SMBus I801 adapter at 1880] unregistered
The right output would be:
i2c i2c-0: adapter [SMBus I801 adapter at 1880] unregistered
Signed-off-by: Thadeu Lima de Souza Cascardo <cascardo at holoscopio.com>
Signed-off-by: Jean Delvare <khali at linux-fr.org>
Signed-off-by: Greg Kroah-Hartman <gregkh at suse.de>
commit 77c68f845135db9396b4e227a92b5de10429071a
Author: Salman Qazi <sqazi at google.com>
Date: Thu Jun 4 15:20:39 2009 -0700
drivers/char/mem.c: avoid OOM lockup during large reads from /dev/zero
commit 730c586ad5228c339949b2eb4e72b80ae167abc4 upstream.
While running 20 parallel instances of dd as follows:
#!/bin/bash
for i in `seq 1 20`; do
dd if=/dev/zero of=/export/hda3/dd_$i bs=1073741824 count=1 &
done
wait
on a 16G machine, we noticed that rather than just killing the processes,
the entire kernel went down. Stracing dd reveals that it first does an
mmap2, which makes 1GB worth of zero page mappings. Then it performs a
read on those pages from /dev/zero, and finally it performs a write.
The machine died during the reads. Looking at the code, it was noticed
that /dev/zero's read operation had been changed by
557ed1fa2620dc119adb86b34c614e152a629a80 ("remove ZERO_PAGE") from giving
zero page mappings to actually zeroing the page.
The zeroing of the pages causes physical pages to be allocated to the
process. But, when the process exhausts all the memory that it can, the
kernel cannot kill it, as it is still in the kernel mode allocating more
memory. Consequently, the kernel eventually crashes.
To fix this, I propose that when a fatal signal is pending during
/dev/zero read operation, we simply return and let the user process die.
Signed-off-by: Salman Qazi <sqazi at google.com>
Cc: Nick Piggin <nickpiggin at yahoo.com.au>
Signed-off-by: Andrew Morton <akpm at linux-foundation.org>
[ Modified error return and comment trivially. - Linus]
Signed-off-by: Linus Torvalds <torvalds at linux-foundation.org>
Signed-off-by: Greg Kroah-Hartman <gregkh at suse.de>
commit ecfb7fb9b13c617447a7f6b5925da26798c1a8a1
Author: Peter Zijlstra <a.p.zijlstra at chello.nl>
Date: Sat Sep 20 23:38:02 2008 +0200
sched: wakeup preempt when small overlap
commit 15afe09bf496ae10c989e1a375a6b5da7bd3e16e upstream.
Lin Ming reported a 10% OLTP regression against 2.6.27-rc4.
The difference seems to come from different preemption agressiveness,
which affects the cache footprint of the workload and its effective
cache trashing.
Aggresively preempt a task if its avg overlap is very small, this should
avoid the task going to sleep and find it still running when we schedule
back to it - saving a wakeup.
Reported-by: Lin Ming <ming.m.lin at intel.com>
Signed-off-by: Peter Zijlstra <a.p.zijlstra at chello.nl>
Signed-off-by: Ingo Molnar <mingo at elte.hu>
Signed-off-by: Greg Kroah-Hartman <gregkh at suse.de>
commit aa7659a10684907bec7c0c6887f8755767fb8dea
Author: Ingo Molnar <mingo at elte.hu>
Date: Fri Nov 7 16:09:23 2008 +0100
sched: fine-tune SD_SIBLING_INIT
commit 52c642f33b14bfa1b00ef2b68296effb34a573f3 upstream.
fine-tune the HT sched-domains parameters as well.
On a HT capable box, this increases lat_ctx performance from 23.87
usecs to 1.49 usecs:
# before
$ ./lat_ctx -s 0 2
"size=0k ovr=1.89
2 23.87
# after
$ ./lat_ctx -s 0 2
"size=0k ovr=1.84
2 1.49
Signed-off-by: Ingo Molnar <mingo at elte.hu>
Signed-off-by: Greg Kroah-Hartman <gregkh at suse.de>
commit ab0fcb9bdab0106011209d5c8b873bdf0fbd1955
Author: Mike Galbraith <efault at gmx.de>
Date: Fri Nov 7 15:26:50 2008 +0100
sched: fine-tune SD_MC_INIT
commit 14800984706bf6936bbec5187f736e928be5c218 upstream.
Tune SD_MC_INIT the same way as SD_CPU_INIT:
unset SD_BALANCE_NEWIDLE, and set SD_WAKE_BALANCE.
This improves vmark by 5%:
vmark 132102 125968 125497 messages/sec avg 127855.66 .984
vmark 139404 131719 131272 messages/sec avg 134131.66 1.033
Signed-off-by: Mike Galbraith <efault at gmx.de>
Acked-by: Peter Zijlstra <a.p.zijlstra at chello.nl>
Signed-off-by: Ingo Molnar <mingo at elte.hu>
Signed-off-by: Greg Kroah-Hartman <gregkh at suse.de>
commit 698051b7655e0289f7a49b4a7e363cb6cec10735
Author: Mike McCormack <mikem at ring3k.org>
Date: Mon Sep 21 04:08:52 2009 +0000
sky2: Set SKY2_HW_RAM_BUFFER in sky2_init
commit 74a61ebf653c6abe459f228eb40e9f24f7ef1fb7 upstream.
The SKY2_HW_RAM_BUFFER bit in hw->flags was checked in sky2_mac_init(),
before being set later in sky2_up().
Setting SKY2_HW_RAM_BUFFER in sky2_init() where other hw->flags are set
should avoid this problem recurring.
Signed-off-by: Mike McCormack <mikem at ring3k.org>
Acked-by: Stephen Hemminger <shemminger at vyatta.com>
Signed-off-by: David S. Miller <davem at davemloft.net>
Signed-off-by: Greg Kroah-Hartman <gregkh at suse.de>
commit e965c3dcb699d946bf7faac5a6b0e3149ec66780
Author: Samuel Thibault <samuel.thibault at ens-lyon.org>
Date: Thu Oct 1 15:44:02 2009 -0700
x86: fix csum_ipv6_magic asm memory clobber
commit 392d814daf460a9564d29b2cebc51e1ea34e0504 upstream.
Just like ip_fast_csum, the assembly snippet in csum_ipv6_magic needs a
memory clobber, as it is only passed the address of the buffer, not a
memory reference to the buffer itself.
This caused failures in Hurd's pfinetv4 when we tried to compile it with
gcc-4.3 (bogus checksums).
Signed-off-by: Samuel Thibault <samuel.thibault at ens-lyon.org>
Cc: Ingo Molnar <mingo at elte.hu>
Cc: Thomas Gleixner <tglx at linutronix.de>
Cc: "H. Peter Anvin" <hpa at zytor.com>
Acked-by: "David S. Miller" <davem at davemloft.net>
Cc: Andi Kleen <andi at firstfloor.org>
Signed-off-by: Andrew Morton <akpm at linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds at linux-foundation.org>
Signed-off-by: Greg Kroah-Hartman <gregkh at suse.de>
commit 7224283df47b5ff9f309371b60030f07037cd51e
Author: Robert Varga <nite at hq.alert.sk>
Date: Tue Sep 15 23:49:21 2009 -0700
tcp: fix CONFIG_TCP_MD5SIG + CONFIG_PREEMPT timer BUG()
commit 657e9649e745b06675aa5063c84430986cdc3afa upstream.
I have recently came across a preemption imbalance detected by:
<4>huh, entered ffffffff80644630 with preempt_count 00000102, exited with 00000101?
<0>------------[ cut here ]------------
<2>kernel BUG at /usr/src/linux/kernel/timer.c:664!
<0>invalid opcode: 0000 [1] PREEMPT SMP
with ffffffff80644630 being inet_twdr_hangman().
This appeared after I enabled CONFIG_TCP_MD5SIG and played with it a
bit, so I looked at what might have caused it.
One thing that struck me as strange is tcp_twsk_destructor(), as it
calls tcp_put_md5sig_pool() -- which entails a put_cpu(), causing the
detected imbalance. Found on 2.6.23.9, but 2.6.31 is affected as well,
as far as I can tell.
Signed-off-by: Robert Varga <nite at hq.alert.sk>
Signed-off-by: David S. Miller <davem at davemloft.net>
Signed-off-by: Greg Kroah-Hartman <gregkh at suse.de>
commit f02363178930a9fb73c88f88c3c347d27d62a082
Author: Sascha Hlusiak <contact at saschahlusiak.de>
Date: Tue Sep 29 11:27:05 2009 +0000
sit: fix off-by-one in ipip6_tunnel_get_prl
commit 298bf12ddb25841804f26234a43b89da1b1c0e21 upstream.
When requesting all prl entries (kprl.addr == INADDR_ANY) and there are
more prl entries than there is space passed from userspace, the existing
code would always copy cmax+1 entries, which is more than can be handled.
This patch makes the kernel copy only exactly cmax entries.
Signed-off-by: Sascha Hlusiak <contact at saschahlusiak.de>
Acked-By: Fred L. Templin <Fred.L.Templin at boeing.com>
Signed-off-by: David S. Miller <davem at davemloft.net>
Signed-off-by: Greg Kroah-Hartman <gregkh at suse.de>
commit 140d894f72c42b58de16c7587241fdd369fc81da
Author: Miklos Szeredi <mszeredi at suse.cz>
Date: Fri Sep 11 11:31:45 2009 -0700
net: unix: fix sending fds in multiple buffers
commit 8ba69ba6a324b13e1190fc31e41954d190fd4f1d upstream.
Kalle Olavi Niemitalo reported that:
"..., when one process calls sendmsg once to send 43804 bytes of
data and one file descriptor, and another process then calls recvmsg
three times to receive the 16032+16032+11740 bytes, each of those
recvmsg calls returns the file descriptor in the ancillary data. I
confirmed this with strace. The behaviour differs from Linux
2.6.26, where reportedly only one of those recvmsg calls (I think
the first one) returned the file descriptor."
This bug was introduced by a patch from me titled "net: unix: fix inflight
counting bug in garbage collector", commit 6209344f5.
And the reason is, quoting Kalle:
"Before your patch, unix_attach_fds() would set scm->fp = NULL, so
that if the loop in unix_stream_sendmsg() ran multiple iterations,
it could not call unix_attach_fds() again. But now,
unix_attach_fds() leaves scm->fp unchanged, and I think this causes
it to be called multiple times and duplicate the same file
descriptors to each struct sk_buff."
Fix this by introducing a flag that is cleared at the start and set
when the fds attached to the first buffer. The resulting code should
work equivalently to the one on 2.6.26.
Reported-by: Kalle Olavi Niemitalo <kon at iki.fi>
Signed-off-by: Miklos Szeredi <mszeredi at suse.cz>
Signed-off-by: David S. Miller <davem at davemloft.net>
Signed-off-by: Greg Kroah-Hartman <gregkh at suse.de>
commit d59e55cb2c8bc73f885de7242223849b3d051cd5
Author: Jarek Poplawski <jarkao2 at gmail.com>
Date: Sun Sep 27 10:57:02 2009 +0000
ax25: Fix possible oops in ax25_make_new
commit 8c185ab6185bf5e67766edb000ce428269364c86 upstream.
In ax25_make_new, if kmemdup of digipeat returns an error, there would
be an oops in sk_free while calling sk_destruct, because sk_protinfo
is NULL at the moment; move sk->sk_destruct initialization after this.
BTW of reported-by: Bernard Pidoux F6BVP <f6bvp at free.fr>
Signed-off-by: Jarek Poplawski <jarkao2 at gmail.com>
Signed-off-by: David S. Miller <davem at davemloft.net>
Signed-off-by: Greg Kroah-Hartman <gregkh at suse.de>
commit 88b60df09c5ce701e308e27932fcf1c8a6bc6375
Author: Alan Stern <stern at rowland.harvard.edu>
Date: Mon Feb 8 09:43:22 2010 -0500
EHCI: fix bug in keeping track of resuming ports
This patch fixes a bug caused by backporting commit
cec3a53c7fe794237b582e8e77fc0e48465e65ee (USB: EHCI & UHCI: fix race
between root-hub suspend and port resume) to 2.6.27.stable without
also backporting commit eafe5b99f2135488b21cf17a262c54997c44f784 (USB:
EHCI: fix remote-wakeup support for ARC/TDI core). This extracts the
necessary changes from the earlier patch and backports them.
The symptom of the bug is that the system will fail to suspend more
than once. The problem is caused by setting ehci->reset_done[i] but
never clearing it. When ehci_bus_suspend() sees a nonzero value
there, it assumes this means the port is in the middle of resuming so
it aborts the bus suspend.
Signed-off-by: Alan Stern <stern at rowland.harvard.edu>
Cc: Corey Wright <undefined at pobox.com>
Signed-off-by: Greg Kroah-Hartman <gregkh at suse.de>
commit e2db86fdddfbf179ebc8e717b50770cf7acf78b6
Author: Raimonds Cicans <ray at apollo.lv>
Date: Fri Nov 13 10:52:19 2009 +0000
r8169: Fix receive buffer length when MTU is between 1515 and 1536
commit 8812304cf1110ae16b0778680f6022216cf4716a upstream.
In r8169 driver MTU is used to calculate receive buffer size.
Receive buffer size is used to configure hardware incoming packet filter.
For jumbo frames:
Receive buffer size = Max frame size = MTU + 14 (ethernet header) + 4
(vlan header) + 4 (ethernet checksum) = MTU + 22
Bug:
driver for all MTU up to 1536 use receive buffer size 1536
As you can see from formula, this mean all IP packets > 1536 - 22
(for vlan tagged, 1536 - 18 for not tagged) are dropped by hardware
filter.
Example:
host_good> ifconfig eth0 mtu 1536
host_r8169> ifconfig eth0 mtu 1536
host_good> ping host_r8169
Ok
host_good> ping -s 1500 host_r8169
Fail
host_good> ifconfig eth0 mtu 7000
host_r8169> ifconfig eth0 mtu 7000
host_good> ping -s 1500 host_r8169
Ok
Bonus: got rid of magic number 8
Signed-off-by: Raimonds Cicans <ray at apollo.lv>
Signed-off-by: David S. Miller <davem at davemloft.net>
Cc: Jean Delvare <khali at linux-fr.org>
Signed-off-by: Greg Kroah-Hartman <gregkh at suse.de>
commit 5d0698d14afc8179e681d1baa6a76a814f8f2fcf
Author: Jean Delvare <khali at linux-fr.org>
Date: Tue Feb 9 18:33:29 2010 +0100
hwmon: (lm78) Fix I/O resource conflict with PNP
This fix is the combination of the following two upstream patches:
http://git.kernel.org/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commitdiff;h=197027e6ef830d60e10f76efc8d12bf3b6c35db5
http://git.kernel.org/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commitdiff;h=47c15532ddcd6818f51cb15f914d63864b3ee9ab
Only request I/O ports 0x295-0x296 instead of the full I/O address
range. This solves a conflict with PNP resources on a few motherboards.
Also request the I/O ports individually during device detection,
otherwise the PNP resource may cause the request (and thus the
detection) fail.
Signed-off-by: Jean Delvare <khali at linux-fr.org>
Signed-off-by: Greg Kroah-Hartman <gregkh at suse.de>
commit 4594467f733524ec6ef31648b8f5b7fce1856852
Author: Peter Zijlstra <a.p.zijlstra at chello.nl>
Date: Wed Aug 20 09:31:26 2008 +0200
printk: robustify printk, fix #2
commit fa33507a22623b3bd543b15a21c362cf364b6cff upstream.
Dmitry Adamushko reported:
> [*] btw., with DEBUG being enabled, pr_debug() generates [1] when
> debug_smp_processor_id() is used (CONFIG_DEBUG_PREEMPT).
>
> the problem seems to be caused by the following commit:
> commit b845b517b5e3706a3729f6ea83b88ab85f0725b0
> Author: Peter Zijlstra <a.p.zijlstra at chello.nl>
> Date: Fri Aug 8 21:47:09 2008 +0200
>
> printk: robustify printk
>
>
> wake_up_klogd() -> __get_cpu_var() -> smp_processor_id()
>
> and that's being called from release_console_sem() which is, in turn,
> said to be "may be called from any context" [2]
>
> and in this case, it seems to be called from some non-preemptible
> context (although, it can't be printk()...
> although, I haven't looked carefully yet).
>
> Provided [2], __get_cpu_var() is perhaps not the right solution there.
>
>
> [1]
>
> [ 7697.942005] BUG: using smp_processor_id() in preemptible [00000000] code: syslogd/3542
> [ 7697.942005] caller is wake_up_klogd+0x1b/0x50
> [ 7697.942005] Pid: 3542, comm: syslogd Not tainted 2.6.27-rc3-tip-git #2
> [ 7697.942005] Call Trace:
> [ 7697.942005] [<ffffffff8036b398>] debug_smp_processor_id+0xe8/0xf0
> [ 7697.942005] [<ffffffff80239d3b>] wake_up_klogd+0x1b/0x50
> [ 7697.942005] [<ffffffff8023a047>] release_console_sem+0x1e7/0x200
> [ 7697.942005] [<ffffffff803c0f17>] do_con_write+0xb7/0x1f30
> [ 7697.942005] [<ffffffff8020d920>] ? show_trace+0x10/0x20
> [ 7697.942005] [<ffffffff8020dc42>] ? dump_stack+0x72/0x80
> [ 7697.942005] [<ffffffff8036392d>] ? __ratelimit+0xbd/0xe0
> [ 7697.942005] [<ffffffff8036b398>] ? debug_smp_processor_id+0xe8/0xf0
> [ 7697.942005] [<ffffffff80239d3b>] ? wake_up_klogd+0x1b/0x50
> [ 7697.942005] [<ffffffff8023a047>] ? release_console_sem+0x1e7/0x200
> [ 7697.942005] [<ffffffff803c2de9>] con_write+0x19/0x30
> [ 7697.942005] [<ffffffff803b37b6>] write_chan+0x276/0x3c0
> [ 7697.942005] [<ffffffff80232b20>] ? default_wake_function+0x0/0x10
> [ 7697.942005] [<ffffffff804cb872>] ? _spin_lock_irqsave+0x22/0x50
> [ 7697.942005] [<ffffffff803b1334>] tty_write+0x194/0x260
> [ 7697.942005] [<ffffffff803b3540>] ? write_chan+0x0/0x3c0
> [ 7697.942005] [<ffffffff803b14a4>] redirected_tty_write+0xa4/0xb0
> [ 7697.942005] [<ffffffff803b1400>] ? redirected_tty_write+0x0/0xb0
> [ 7697.942005] [<ffffffff802a88c2>] do_loop_readv_writev+0x52/0x80
> [ 7697.942005] [<ffffffff802a939d>] do_readv_writev+0x1bd/0x1d0
> [ 7697.942005] [<ffffffff802a93e9>] vfs_writev+0x39/0x60
> [ 7697.942005] [<ffffffff802a9870>] sys_writev+0x50/0x90
> [ 7697.942005] [<ffffffff8020bb3b>] system_call_fastpath+0x16/0x1b
Signed-off-by: Peter Zijlstra <a.p.zijlstra at chello.nl>
Reported-by: Dmitry Adamushko <dmitry.adamushko at gmail.com>
Signed-off-by: Ingo Molnar <mingo at elte.hu>
Cc: Paul Gortmaker <paul.gortmaker at windriver.com>
Signed-off-by: Greg Kroah-Hartman <gregkh at suse.de>
commit 1626749d7bbbc00b362b632d993289128651d075
Author: Jiri Slaby <jslaby at suse.cz>
Date: Thu Nov 19 17:16:37 2009 +0100
resource: add helpers for fetching rlimits
commit 3e10e716abf3c71bdb5d86b8f507f9e72236c9cd upstream.
We want to be sure that compiler fetches the limit variable only
once, so add helpers for fetching current and maximal resource
limits which do that.
Add them to sched.h (instead of resource.h) due to circular dependency
sched.h->resource.h->task_struct
Alternative would be to create a separate res_access.h or similar.
Signed-off-by: Jiri Slaby <jslaby at suse.cz>
Cc: James Morris <jmorris at namei.org>
Cc: Heiko Carstens <heiko.carstens at de.ibm.com>
Cc: Andrew Morton <akpm at linux-foundation.org>
Cc: Ingo Molnar <mingo at elte.hu>
Signed-off-by: Greg Kroah-Hartman <gregkh at suse.de>
commit 873b48a4cf4a64dd77faef25ddcf1651cef49a32
Author: Thomas Gleixner <tglx at linutronix.de>
Date: Tue Feb 2 11:40:27 2010 +0100
futex: Handle user space corruption gracefully
commit 51246bfd189064079c54421507236fd2723b18f3 upstream.
If the owner of a PI futex dies we fix up the pi_state and set
pi_state->owner to NULL. When a malicious or just sloppy programmed
user space application sets the futex value to 0 e.g. by calling
pthread_mutex_init(), then the futex can be acquired again. A new
waiter manages to enqueue itself on the pi_state w/o damage, but on
unlock the kernel dereferences pi_state->owner and oopses.
Prevent this by checking pi_state->owner in the unlock path. If
pi_state->owner is not current we know that user space manipulated the
futex value. Ignore the mess and return -EINVAL.
This catches the above case and also the case where a task hijacks the
futex by setting the tid value and then tries to unlock it.
Reported-by: Jermome Marchand <jmarchan at redhat.com>
Signed-off-by: Thomas Gleixner <tglx at linutronix.de>
Acked-by: Darren Hart <dvhltc at us.ibm.com>
Acked-by: Peter Zijlstra <a.p.zijlstra at chello.nl>
Signed-off-by: Greg Kroah-Hartman <gregkh at suse.de>
commit 268ec2564310a552681bcbfb412c35804c06efad
Author: Thomas Gleixner <tglx at linutronix.de>
Date: Wed Feb 3 09:33:05 2010 +0100
futex: Handle futex value corruption gracefully
commit 59647b6ac3050dd964bc556fe6ef22f4db5b935c upstream.
The WARN_ON in lookup_pi_state which complains about a mismatch
between pi_state->owner->pid and the pid which we retrieved from the
user space futex is completely bogus.
The code just emits the warning and then continues despite the fact
that it detected an inconsistent state of the futex. A conveniant way
for user space to spam the syslog.
Replace the WARN_ON by a consistency check. If the values do not match
return -EINVAL and let user space deal with the mess it created.
This also fixes the missing task_pid_vnr() when we compare the
pi_state->owner pid with the futex value.
Reported-by: Jermome Marchand <jmarchan at redhat.com>
Signed-off-by: Thomas Gleixner <tglx at linutronix.de>
Acked-by: Darren Hart <dvhltc at us.ibm.com>
Acked-by: Peter Zijlstra <a.p.zijlstra at chello.nl>
Signed-off-by: Greg Kroah-Hartman <gregkh at suse.de>
commit 24fce8f6a79db04afef0c6118f6ecdcfec12ffc4
Author: Linus Torvalds <torvalds at linux-foundation.org>
Date: Sun Feb 7 10:11:23 2010 -0800
Fix race in tty_fasync() properly
commit 80e1e823989ec44d8e35bdfddadbddcffec90424 upstream.
This reverts commit 703625118069 ("tty: fix race in tty_fasync") and
commit b04da8bfdfbb ("fnctl: f_modown should call write_lock_irqsave/
restore") that tried to fix up some of the fallout but was incomplete.
It turns out that we really cannot hold 'tty->ctrl_lock' over calling
__f_setown, because not only did that cause problems with interrupt
disables (which the second commit fixed), it also causes a potential
ABBA deadlock due to lock ordering.
Thanks to Tetsuo Handa for following up on the issue, and running
lockdep to show the problem. It goes roughly like this:
- f_getown gets filp->f_owner.lock for reading without interrupts
disabled, so an interrupt that happens while that lock is held can
cause a lockdep chain from f_owner.lock -> sighand->siglock.
- at the same time, the tty->ctrl_lock -> f_owner.lock chain that
commit 703625118069 introduced, together with the pre-existing
sighand->siglock -> tty->ctrl_lock chain means that we have a lock
dependency the other way too.
So instead of extending tty->ctrl_lock over the whole __f_setown() call,
we now just take a reference to the 'pid' structure while holding the
lock, and then release it after having done the __f_setown. That still
guarantees that 'struct pid' won't go away from under us, which is all
we really ever needed.
Reported-and-tested-by: Tetsuo Handa <penguin-kernel at I-love.SAKURA.ne.jp>
Acked-by: Greg Kroah-Hartman <gregkh at suse.de>
Acked-by: Américo Wang <xiyou.wangcong at gmail.com>
Signed-off-by: Linus Torvalds <torvalds at linux-foundation.org>
Signed-off-by: Greg Kroah-Hartman <gregkh at suse.de>
commit ffa211737de4c26d0d6fd61091d59acfcac1d03a
Author: Linus Torvalds <torvalds at linux-foundation.org>
Date: Fri Feb 5 16:16:50 2010 -0800
Fix potential crash with sys_move_pages
commit 6f5a55f1a6c5abee15a0e878e5c74d9f1569b8b0 upstream.
We incorrectly depended on the 'node_state/node_isset()' functions
testing the node range, rather than checking it explicitly. That's not
reliable, even if it might often happen to work. So do the proper
explicit test.
Reported-by: Marcus Meissner <meissner at suse.de>
Acked-and-tested-by: Brice Goglin <Brice.Goglin at inria.fr>
Acked-by: Hugh Dickins <hugh.dickins at tiscali.co.uk>
Signed-off-by: Linus Torvalds <torvalds at linux-foundation.org>
Signed-off-by: Greg Kroah-Hartman <gregkh at suse.de>
commit 69f4dd6978cc487e49360c50dce75a267a99f3d5
Author: Mika Westerberg <ext-mika.1.westerberg at nokia.com>
Date: Tue Jan 26 17:47:05 2010 +0200
UBI: fix volume creation input checking
commit c5ce5b46af76f52dea21f467397d24c4ae6cb3ff upstream.
Do not use an unchecked variable UBI_IOCMKVOL ioctl.
Signed-off-by: Mika Westerberg <ext-mika.1.westerberg at nokia.com>
Signed-off-by: Artem Bityutskiy <Artem.Bityutskiy at nokia.com>
Signed-off-by: Greg Kroah-Hartman <gregkh at suse.de>
More information about the unionfs-cvs
mailing list