X-Git-Url: http://git.ozlabs.org/?p=petitboot;a=blobdiff_plain;f=discover%2Fdevice-handler.c;h=9c8dea8f47a1bc55293f807c5ba6cfae52652e7e;hp=80187ff49474a186cfb5b7e5bb7bceb0f4209404;hb=43f340b66d8323c6e797868d07fc98482052ba35;hpb=bb3ddd63720501f451d3f2797f315c25efd3bd4a diff --git a/discover/device-handler.c b/discover/device-handler.c index 80187ff..9c8dea8 100644 --- a/discover/device-handler.c +++ b/discover/device-handler.c @@ -806,6 +806,7 @@ static bool check_existing_mount(struct discover_device *dev) static int mount_device(struct discover_device *dev) { + const char *fstype; int rc; if (!dev->device_path) @@ -817,6 +818,10 @@ static int mount_device(struct discover_device *dev) if (check_existing_mount(dev)) return 0; + fstype = discover_device_get_param(dev, "ID_FS_TYPE"); + if (!fstype) + return 0; + dev->mount_path = join_paths(dev, mount_base(), dev->device_path); @@ -828,7 +833,7 @@ static int mount_device(struct discover_device *dev) rc = process_run_simple(dev, pb_system_apps.mount, dev->device_path, dev->mount_path, - "-o", "ro", NULL); + "-t", fstype, "-o", "ro", NULL); if (!rc) { dev->mounted = true; dev->mounted_rw = false;