Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 26 Sep 2004 10:36:44 +0930
From:      Lucas James <Lucas.James@LDJcs.Com.Au>
To:        freebsd-current@freebsd.org
Subject:   Re: USB memory stick hotswap problems
Message-ID:  <200409261036.49484.Lucas.James@LDJcs.Com.Au>
In-Reply-To: <20040926005943.GA61350@parodius.com>
References:  <41555396.4030009@fer.hr> <20040926021347.721a025f.benlutz@datacomm.ch> <20040926005943.GA61350@parodius.com>

next in thread | previous in thread | raw e-mail | index | archive | help
--nextPart2644352.oJSfmMxJ0x
Content-Type: text/plain;
  charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable
Content-Disposition: inline

On Sun, 26 Sep 2004 10:29 am, Jeremy Chadwick wrote:
> Can't usbd (or better yet, usbd.conf) be modified or changed in some way
> to automatically handle the unmounting of any existing filesystems that
> match the device which is mounted?

that won't work because usbd only gets the notification of something being=
=20
unplugged *after* the fact, and it's too late to do unmounting then.

And it can't be modified, because the kernel has no idea when the user is=20
going to yank out the cable.

> Seems like we're eventually going to need this to make hot-swappable USB
> devices more friendly.  I understand why you must unmount a device
> before SCSI CAM gets disconnected from it, but it just seems that this
> should be a job for usbd.

the only way you can ensure data integrity on user-removable devices is to=
=20
mount them with -o sync.

We should be telling the kernel at some point that this is a removable devi=
ce,=20
and not have the kernel complain if we umount it when the device has alread=
y=20
disappeared (assuming that we have mounted it with -o sync).


Lucas James
=2D-=20
The only possible interpretation of any research whatever in the
`social sciences' is: some do, some don't.
  -- Ernest Rutherford

--nextPart2644352.oJSfmMxJ0x
Content-Type: application/pgp-signature

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.6 (FreeBSD)

iD8DBQBBVhYpS5LuBv475s8RAlcEAKCnhphekybbPc7kaLFhpatuHaaIXgCgpYTa
npTVKjqr4wjwz5o7bQaDJJU=
=p3FG
-----END PGP SIGNATURE-----

--nextPart2644352.oJSfmMxJ0x--



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200409261036.49484.Lucas.James>