From cfbba40d2f08a1c4748fafb9a89327b40468ee7b Mon Sep 17 00:00:00 2001 From: root Date: Sat, 1 Jan 2000 01:16:29 +0900 Subject: add function to find root mount point --- instr-daemon.c | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) diff --git a/instr-daemon.c b/instr-daemon.c index f155fab..4c72997 100644 --- a/instr-daemon.c +++ b/instr-daemon.c @@ -16,6 +16,7 @@ #include #include #include +#include #define STDIN_BUF_SIZE 1024 @@ -197,6 +198,22 @@ static gpointer vxithreadfunc (gpointer data) } +static void get_root_mount () +{ + struct fstab *sys_fstab; + + sys_fstab = getfsfile ("/"); + + if (sys_fstab == NULL) { + return; + } + + strcpy (globals.HWDetect.remount_point, sys_fstab->fs_spec); + + printf ("root mount = %s\n", globals.HWDetect.remount_point); + + return; +} int main(int argc, char **argv) { @@ -207,6 +224,7 @@ int main(int argc, char **argv) g_type_init (); g_thread_init (NULL); + get_root_mount(); bus_init(); LCD_initialize(); -- cgit