mount_root: convert to ulog() api
authorJo-Philipp Wich <jow@openwrt.org>
Wed, 25 Feb 2015 20:16:56 +0000 (21:16 +0100)
committerJo-Philipp Wich <jow@openwrt.org>
Wed, 25 Feb 2015 20:21:21 +0000 (21:21 +0100)
Signed-off-by: Jo-Philipp Wich <jow@openwrt.org>
mount_root.c

index cc39b44..3c38a29 100644 (file)
@@ -15,6 +15,8 @@
 #include <stdio.h>
 #include <stdlib.h>
 
+#include <libubox/ulog.h>
+
 #include "libfstools/libfstools.h"
 #include "libfstools/volume.h"
 
@@ -34,7 +36,7 @@ start(int argc, char *argv[1])
        if (!data) {
                root = volume_find("rootfs");
                volume_init(root);
-               fprintf(stderr, "mounting /dev/root\n");
+               ULOG_NOTE("mounting /dev/root\n");
                mount("/dev/root", "/", NULL, MS_NOATIME | MS_REMOUNT, 0);
        }
 
@@ -45,7 +47,7 @@ start(int argc, char *argv[1])
         */
        extroot_prefix = "";
        if (!mount_extroot()) {
-               fprintf(stderr, "fs-state: switched to extroot\n");
+               ULOG_NOTE("switched to extroot\n");
                return 0;
        }