diff options
author | Christoph Hellwig <hch@lst.de> | 2008-05-05 19:24:24 -0400 |
---|---|---|
committer | Jeremy Kerr <jk@ozlabs.org> | 2008-05-05 19:24:24 -0400 |
commit | 826be063eee9b4c2703fd86cfc9723bc391ff1cb (patch) | |
tree | ed16f042baad4cd30b4faf18996d30a5c1921c9f /arch/powerpc | |
parent | de1028927ae3487e2e450dacf50fbf32042aee18 (diff) |
[POWERPC] spufs: spu_create should send inotify IM_CREATE event
Creating a spufs context or gand using spu_create should send an inotify
event so that things like performance monitors have an easy way to find
out about newly created contexts.
Signed-off-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
Diffstat (limited to 'arch/powerpc')
-rw-r--r-- | arch/powerpc/platforms/cell/spufs/inode.c | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/arch/powerpc/platforms/cell/spufs/inode.c b/arch/powerpc/platforms/cell/spufs/inode.c index 0c32a05ab068..5faedf5a09a0 100644 --- a/arch/powerpc/platforms/cell/spufs/inode.c +++ b/arch/powerpc/platforms/cell/spufs/inode.c | |||
@@ -23,6 +23,7 @@ | |||
23 | 23 | ||
24 | #include <linux/file.h> | 24 | #include <linux/file.h> |
25 | #include <linux/fs.h> | 25 | #include <linux/fs.h> |
26 | #include <linux/fsnotify.h> | ||
26 | #include <linux/backing-dev.h> | 27 | #include <linux/backing-dev.h> |
27 | #include <linux/init.h> | 28 | #include <linux/init.h> |
28 | #include <linux/ioctl.h> | 29 | #include <linux/ioctl.h> |
@@ -618,12 +619,15 @@ long spufs_create(struct nameidata *nd, unsigned int flags, mode_t mode, | |||
618 | mode &= ~current->fs->umask; | 619 | mode &= ~current->fs->umask; |
619 | 620 | ||
620 | if (flags & SPU_CREATE_GANG) | 621 | if (flags & SPU_CREATE_GANG) |
621 | return spufs_create_gang(nd->path.dentry->d_inode, | 622 | ret = spufs_create_gang(nd->path.dentry->d_inode, |
622 | dentry, nd->path.mnt, mode); | 623 | dentry, nd->path.mnt, mode); |
623 | else | 624 | else |
624 | return spufs_create_context(nd->path.dentry->d_inode, | 625 | ret = spufs_create_context(nd->path.dentry->d_inode, |
625 | dentry, nd->path.mnt, flags, mode, | 626 | dentry, nd->path.mnt, flags, mode, |
626 | filp); | 627 | filp); |
628 | if (ret >= 0) | ||
629 | fsnotify_mkdir(nd->path.dentry->d_inode, dentry); | ||
630 | return ret; | ||
627 | 631 | ||
628 | out_dput: | 632 | out_dput: |
629 | dput(dentry); | 633 | dput(dentry); |