On Sun, 30 Jan 2005, Oliver Lehmann wrote:
> Hi,
>
> I mounted a write-pretected floppy on 5-STABLE and now I'm not able to
> unmount the floppy
For the record I can reproduce this. There is #ifdef notyet'd code in fdc
that would avoid this case. I'm hoping phk can explain what changes are
still necessary to activate that code. It appears some GEOM knowledge
needs to make it into the filesystems on RELENG_5.
Since the code is active in HEAD it shouldn't allow mounting RO floppies.
> root@kartoffel /root> mount_msdosfs /dev/fd0 /mnt/tmp
> root@kartoffel /root> touch /mnt/tmp/test
> touch: /mnt/tmp/test: Read-only file system
> Exit 1
> root@kartoffel /root> mount
> /dev/ad0s1a on / (ufs, local)
> devfs on /dev (devfs, local)
> /dev/ad0s1e on /tmp (ufs, local, soft-updates)
> /dev/ad0s1f on /usr (ufs, local, soft-updates)
> /dev/ad0s1d on /var (ufs, local, soft-updates)
> /dev/ad0s3e on /usr/home (ufs, local, soft-updates)
> /dev/ad0s4e on /mnt/movies (ufs, local, soft-updates)
> file:/usr/ports on /usr/ports (nfs)
> file:/usr/src on /usr/src (nfs)
> file:/mnt/backups on /mnt/backups (nfs)
> file:/mnt/documents on /mnt/documents (nfs)
> file:/mnt/files on /mnt/files (nfs)
> www:/usr/local/www on /mnt/www (nfs)
> /dev/fd0 on /mnt/tmp (msdosfs, local)
> root@kartoffel /root> umount /mnt/tmp
> umount: unmount of /mnt/tmp failed: Resource temporarily unavailable
> Exit 1
> root@kartoffel /root>
>
> what works is
>
> root@kartoffel /root> umount -f /mnt/tmp
> root@kartoffel /root>
>
> CURRENT correctly detects that the floppy is write-protected, and fails to
> mount it unless -o ro is specified. umount on CURRENT is also possible.
>
> root@kartoffel /root> uname -a
> FreeBSD kartoffel.salatschuessel.net 5.3-STABLE FreeBSD 5.3-STABLE #0: Sun
> Jan 16 15:35:29 CET 2005
> olivleh1@kartoffel.salatschuessel.net:/usr/obj/usr/src/sys/KARTOFFEL i386
>
> please keep me CCed - I'm not subscribed
>
>
--
Doug White | FreeBSD: The Power to Serve
dwhite@gumbysoft.com | www.FreeBSD.org