Messages in this thread Patch in this message | | | Date | Wed, 3 Mar 1999 20:40:48 +0000 (GMT) | From | Matthew Kirkwood <> | Subject | Re: [2.2.1 bug: loop remounts] |
| |
On Wed, 3 Mar 1999, Chris Evans wrote:
> I think this is a bug although of course it might be a case of us simply > not supporting this. > > mount -o remount,ro /some/loopfile/based/mount > > I get > ioctl: LOOP_SET_FD: Device or resource busy
Look at what it's doing - you'll probably find that it's a mount bug, rather than a kernel one.
strace it and you'll probably find it trying to change the loop device fd.
This: --- loop.c.orig Wed Mar 3 20:35:13 1999 +++ loop.c Wed Mar 3 20:39:13 1999 @@ -344,14 +344,15 @@ MOD_INC_USE_COUNT; - error = -EBUSY; - if (lo->lo_dentry) - goto out; - error = -EBADF; file = fget(arg); if (!file) goto out; + + if (lo->lo_dentry) { + error = (lo->lo_dentry->d_inode == file->f_dentry->d_inode) ? 0 : -EBUSY; + goto out; + } error = -EINVAL; inode = file->f_dentry->d_inode;
might be an acceptable workaround, though.
Matthew.
- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.rutgers.edu Please read the FAQ at http://www.tux.org/lkml/
| |