]> git.ozlabs.org Git - petitboot/commitdiff
Retry device mount without 'ro' option
authorGeoff Levand <geoff@infradead.org>
Fri, 9 Mar 2012 01:41:15 +0000 (17:41 -0800)
committerGeoff Levand <geoff@infradead.org>
Fri, 9 Mar 2012 04:51:14 +0000 (20:51 -0800)
Signed-off-by: Geoff Levand <geoff@infradead.org>
discover/device-handler.c

index c72390b438d7222540b467619d6f2865117eb503..6457dce6b68c5acf39ff8b8e5525a25b7caf9612 100644 (file)
@@ -201,6 +201,9 @@ static int mount_device(struct discover_context *ctx)
        argv[4] = "ro";
        argv[5] = NULL;
 
        argv[4] = "ro";
        argv[5] = NULL;
 
+       if (pb_run_cmd(argv))
+               argv[3] = NULL; /* try without ro */
+
        if (pb_run_cmd(argv))
                goto out_rmdir;
 
        if (pb_run_cmd(argv))
                goto out_rmdir;