diff options
author | Nishanth Menon <nm@ti.com> | 2011-09-20 11:31:17 +0200 |
---|---|---|
committer | Daniel Lezcano <daniel.lezcano@linaro.org> | 2011-09-20 11:31:17 +0200 |
commit | a14971baa6070fc37bc9ae5a35aabda6f109fe34 (patch) | |
tree | 8f0b7d37e8627b082bec2825015f147863840ccf | |
parent | 960b4e9154d68ee36ba5361fc5882d0a15e3da5f (diff) |
clock.c: use standard kernel/debug location
getmntent and family is not supported on Bionic. instead
use the standard kernel debugfs mount point.
Signed-off-by: Nishanth Menon <nm@ti.com>
Signed-off-by: Daniel Lezcano <daniel.lezcano@linaro.org>
-rw-r--r-- | clocks.c | 23 |
1 files changed, 2 insertions, 21 deletions
@@ -48,27 +48,8 @@ static struct tree *clock_tree = NULL; static int locate_debugfs(char *clk_path) { - const char *mtab = "/proc/mounts"; - struct mntent *mntent; - int ret = -1; - FILE *file = NULL; - - file = setmntent(mtab, "r"); - if (!file) - return -1; - - while ((mntent = getmntent(file))) { - - if (strcmp(mntent->mnt_type, "debugfs")) - continue; - - strcpy(clk_path, mntent->mnt_dir); - ret = 0; - break; - } - - fclose(file); - return ret; + strcpy(clk_path, "/sys/kernel/debug"); + return 0; } static struct clock_info *clock_alloc(void) |