From: Jeremy Kerr Date: Fri, 7 Mar 2014 01:05:00 +0000 (+0800) Subject: discover: don't retry mount without ro option X-Git-Tag: v1.0.0~221 X-Git-Url: http://git.ozlabs.org/?p=petitboot;a=commitdiff_plain;h=d8d61e648ebf6a3336820db94244c4251361cf2f discover: don't retry mount without ro option Currently, if the read-only mount fails during device discovery, we retry without the '-o ro' option. This was originally due to the read-only mount failing when a device was already mounted elsewhere. Since we check for exsiting mounts now, we can drop this retry. Signed-off-by: Jeremy Kerr --- diff --git a/discover/device-handler.c b/discover/device-handler.c index f1845a9..eaa85de 100644 --- a/discover/device-handler.c +++ b/discover/device-handler.c @@ -836,17 +836,6 @@ static int mount_device(struct discover_device *dev) return 0; } - /* Retry mount without ro option. */ - rc = process_run_simple(dev, pb_system_apps.mount, - dev->device_path, dev->mount_path, NULL); - - if (!rc) { - dev->mounted = true; - dev->mounted_rw = true; - dev->unmount = true; - return 0; - } - pb_rmdir_recursive(mount_base(), dev->mount_path); err_free: talloc_free(dev->mount_path);