* [PATCH] xfs: Fix missing xfs_iunlock() on error recovery path in xfs_readlink()
@ 2012-01-11 18:52 Jan Kara
2012-01-11 19:13 ` Ben Myers
` (2 more replies)
0 siblings, 3 replies; 6+ messages in thread
From: Jan Kara @ 2012-01-11 18:52 UTC (permalink / raw)
To: Alex Elder; +Cc: Ben Myers, Jan Kara, stable, Carlos Maiolino, xfs
Commit b52a360b forgot to call xfs_iunlock() when it detected corrupted
symplink and bailed out. Fix it by jumping to 'out' instead of doing return.
CC: stable@kernel.org
CC: Carlos Maiolino <cmaiolino@redhat.com>
Signed-off-by: Jan Kara <jack@suse.cz>
---
fs/xfs/xfs_vnodeops.c | 3 ++-
1 files changed, 2 insertions(+), 1 deletions(-)
diff --git a/fs/xfs/xfs_vnodeops.c b/fs/xfs/xfs_vnodeops.c
index f2fea86..6156cd6 100644
--- a/fs/xfs/xfs_vnodeops.c
+++ b/fs/xfs/xfs_vnodeops.c
@@ -131,7 +131,8 @@ xfs_readlink(
__func__, (unsigned long long) ip->i_ino,
(long long) pathlen);
ASSERT(0);
- return XFS_ERROR(EFSCORRUPTED);
+ error = XFS_ERROR(EFSCORRUPTED);
+ goto out;
}
--
1.7.1
_______________________________________________
xfs mailing list
xfs@oss.sgi.com
http://oss.sgi.com/mailman/listinfo/xfs
^ permalink raw reply related [flat|nested] 6+ messages in thread
* Re: [PATCH] xfs: Fix missing xfs_iunlock() on error recovery path in xfs_readlink()
2012-01-11 18:52 [PATCH] xfs: Fix missing xfs_iunlock() on error recovery path in xfs_readlink() Jan Kara
@ 2012-01-11 19:13 ` Ben Myers
2012-01-24 18:01 ` Christoph Hellwig
2012-01-11 20:30 ` Alex Elder
2012-01-11 20:39 ` Dave Chinner
2 siblings, 1 reply; 6+ messages in thread
From: Ben Myers @ 2012-01-11 19:13 UTC (permalink / raw)
To: Jan Kara; +Cc: Alex Elder, stable, Carlos Maiolino, xfs
On Wed, Jan 11, 2012 at 07:52:10PM +0100, Jan Kara wrote:
> Commit b52a360b forgot to call xfs_iunlock() when it detected corrupted
> symplink and bailed out. Fix it by jumping to 'out' instead of doing return.
>
> CC: stable@kernel.org
> CC: Carlos Maiolino <cmaiolino@redhat.com>
> Signed-off-by: Jan Kara <jack@suse.cz>
> ---
> fs/xfs/xfs_vnodeops.c | 3 ++-
> 1 files changed, 2 insertions(+), 1 deletions(-)
>
> diff --git a/fs/xfs/xfs_vnodeops.c b/fs/xfs/xfs_vnodeops.c
> index f2fea86..6156cd6 100644
> --- a/fs/xfs/xfs_vnodeops.c
> +++ b/fs/xfs/xfs_vnodeops.c
> @@ -131,7 +131,8 @@ xfs_readlink(
> __func__, (unsigned long long) ip->i_ino,
> (long long) pathlen);
> ASSERT(0);
> - return XFS_ERROR(EFSCORRUPTED);
> + error = XFS_ERROR(EFSCORRUPTED);
> + goto out;
> }
Looks good to me.
Reviewed-by: Ben Myers <bpm@sgi.com>
_______________________________________________
xfs mailing list
xfs@oss.sgi.com
http://oss.sgi.com/mailman/listinfo/xfs
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [PATCH] xfs: Fix missing xfs_iunlock() on error recovery path in xfs_readlink()
2012-01-11 18:52 [PATCH] xfs: Fix missing xfs_iunlock() on error recovery path in xfs_readlink() Jan Kara
2012-01-11 19:13 ` Ben Myers
@ 2012-01-11 20:30 ` Alex Elder
2012-01-11 20:39 ` Dave Chinner
2 siblings, 0 replies; 6+ messages in thread
From: Alex Elder @ 2012-01-11 20:30 UTC (permalink / raw)
To: Jan Kara; +Cc: Ben Myers, Alex Elder, stable, Carlos Maiolino, xfs
On Wed, 2012-01-11 at 19:52 +0100, Jan Kara wrote:
> Commit b52a360b forgot to call xfs_iunlock() when it detected corrupted
> symplink and bailed out. Fix it by jumping to 'out' instead of doing return.
Whoops. Sorry I didn't catch that. Your fix looks good.
Reviewed-by: Alex Elder <elder@kernel.org>
> CC: stable@kernel.org
> CC: Carlos Maiolino <cmaiolino@redhat.com>
> Signed-off-by: Jan Kara <jack@suse.cz>
> ---
> fs/xfs/xfs_vnodeops.c | 3 ++-
> 1 files changed, 2 insertions(+), 1 deletions(-)
>
> diff --git a/fs/xfs/xfs_vnodeops.c b/fs/xfs/xfs_vnodeops.c
> index f2fea86..6156cd6 100644
> --- a/fs/xfs/xfs_vnodeops.c
> +++ b/fs/xfs/xfs_vnodeops.c
> @@ -131,7 +131,8 @@ xfs_readlink(
> __func__, (unsigned long long) ip->i_ino,
> (long long) pathlen);
> ASSERT(0);
> - return XFS_ERROR(EFSCORRUPTED);
> + error = XFS_ERROR(EFSCORRUPTED);
> + goto out;
> }
>
>
_______________________________________________
xfs mailing list
xfs@oss.sgi.com
http://oss.sgi.com/mailman/listinfo/xfs
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [PATCH] xfs: Fix missing xfs_iunlock() on error recovery path in xfs_readlink()
2012-01-11 18:52 [PATCH] xfs: Fix missing xfs_iunlock() on error recovery path in xfs_readlink() Jan Kara
2012-01-11 19:13 ` Ben Myers
2012-01-11 20:30 ` Alex Elder
@ 2012-01-11 20:39 ` Dave Chinner
2 siblings, 0 replies; 6+ messages in thread
From: Dave Chinner @ 2012-01-11 20:39 UTC (permalink / raw)
To: Jan Kara; +Cc: Ben Myers, Alex Elder, stable, Carlos Maiolino, xfs
On Wed, Jan 11, 2012 at 07:52:10PM +0100, Jan Kara wrote:
> Commit b52a360b forgot to call xfs_iunlock() when it detected corrupted
> symplink and bailed out. Fix it by jumping to 'out' instead of doing return.
>
> CC: stable@kernel.org
> CC: Carlos Maiolino <cmaiolino@redhat.com>
> Signed-off-by: Jan Kara <jack@suse.cz>
> ---
> fs/xfs/xfs_vnodeops.c | 3 ++-
> 1 files changed, 2 insertions(+), 1 deletions(-)
>
> diff --git a/fs/xfs/xfs_vnodeops.c b/fs/xfs/xfs_vnodeops.c
> index f2fea86..6156cd6 100644
> --- a/fs/xfs/xfs_vnodeops.c
> +++ b/fs/xfs/xfs_vnodeops.c
> @@ -131,7 +131,8 @@ xfs_readlink(
> __func__, (unsigned long long) ip->i_ino,
> (long long) pathlen);
> ASSERT(0);
> - return XFS_ERROR(EFSCORRUPTED);
> + error = XFS_ERROR(EFSCORRUPTED);
> + goto out;
> }
Heh, you beat me to it. I was testing an identical patch yesterday
for this problem which was tripped over by RH QA....
Reviewed-by: Dave Chinner <dchinner@redhat.com>
--
Dave Chinner
david@fromorbit.com
_______________________________________________
xfs mailing list
xfs@oss.sgi.com
http://oss.sgi.com/mailman/listinfo/xfs
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [PATCH] xfs: Fix missing xfs_iunlock() on error recovery path in xfs_readlink()
2012-01-11 19:13 ` Ben Myers
@ 2012-01-24 18:01 ` Christoph Hellwig
2012-01-25 16:15 ` Ben Myers
0 siblings, 1 reply; 6+ messages in thread
From: Christoph Hellwig @ 2012-01-24 18:01 UTC (permalink / raw)
To: Ben Myers; +Cc: Alex Elder, Jan Kara, stable, Carlos Maiolino, xfs
On Wed, Jan 11, 2012 at 01:13:30PM -0600, Ben Myers wrote:
> Looks good to me.
>
> Reviewed-by: Ben Myers <bpm@sgi.com>
Can you send it on to Linus ASAP, please?
_______________________________________________
xfs mailing list
xfs@oss.sgi.com
http://oss.sgi.com/mailman/listinfo/xfs
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [PATCH] xfs: Fix missing xfs_iunlock() on error recovery path in xfs_readlink()
2012-01-24 18:01 ` Christoph Hellwig
@ 2012-01-25 16:15 ` Ben Myers
0 siblings, 0 replies; 6+ messages in thread
From: Ben Myers @ 2012-01-25 16:15 UTC (permalink / raw)
To: Christoph Hellwig; +Cc: Alex Elder, Jan Kara, stable, Carlos Maiolino, xfs
On Tue, Jan 24, 2012 at 01:01:02PM -0500, Christoph Hellwig wrote:
> On Wed, Jan 11, 2012 at 01:13:30PM -0600, Ben Myers wrote:
> > Looks good to me.
> >
> > Reviewed-by: Ben Myers <bpm@sgi.com>
>
> Can you send it on to Linus ASAP, please?
Yes.
_______________________________________________
xfs mailing list
xfs@oss.sgi.com
http://oss.sgi.com/mailman/listinfo/xfs
^ permalink raw reply [flat|nested] 6+ messages in thread
end of thread, other threads:[~2012-01-25 16:15 UTC | newest]
Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-01-11 18:52 [PATCH] xfs: Fix missing xfs_iunlock() on error recovery path in xfs_readlink() Jan Kara
2012-01-11 19:13 ` Ben Myers
2012-01-24 18:01 ` Christoph Hellwig
2012-01-25 16:15 ` Ben Myers
2012-01-11 20:30 ` Alex Elder
2012-01-11 20:39 ` Dave Chinner
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox