diff options
Diffstat (limited to 'src/vppinfra/linux')
-rw-r--r-- | src/vppinfra/linux/sysfs.c | 26 | ||||
-rw-r--r-- | src/vppinfra/linux/sysfs.h | 2 |
2 files changed, 0 insertions, 28 deletions
diff --git a/src/vppinfra/linux/sysfs.c b/src/vppinfra/linux/sysfs.c index a3e122cf1e0..6d9f859640c 100644 --- a/src/vppinfra/linux/sysfs.c +++ b/src/vppinfra/linux/sysfs.c @@ -87,32 +87,6 @@ clib_sysfs_read (char *file_name, char *fmt, ...) return 0; } -__clib_export u8 * -clib_sysfs_link_to_name (char *link) -{ - char *p, buffer[64]; - unformat_input_t in; - u8 *s = 0; - int r; - - r = readlink (link, buffer, sizeof (buffer) - 1); - - if (r < 0) - return 0; - - buffer[r] = 0; - p = strrchr (buffer, '/'); - - if (!p) - return 0; - - unformat_init_string (&in, p + 1, strlen (p + 1)); - if (unformat (&in, "%s", &s) != 1) - clib_unix_warning ("no string?"); - unformat_free (&in); - - return s; -} clib_error_t * clib_sysfs_set_nr_hugepages (int numa_node, int log2_page_size, int nr) diff --git a/src/vppinfra/linux/sysfs.h b/src/vppinfra/linux/sysfs.h index 9cbc34823dd..a616fa422a1 100644 --- a/src/vppinfra/linux/sysfs.h +++ b/src/vppinfra/linux/sysfs.h @@ -22,8 +22,6 @@ clib_error_t *clib_sysfs_write (char *file_name, char *fmt, ...); clib_error_t *clib_sysfs_read (char *file_name, char *fmt, ...); -u8 *clib_sysfs_link_to_name (char *link); - clib_error_t *clib_sysfs_set_nr_hugepages (int numa_node, int log2_page_size, int nr); clib_error_t *clib_sysfs_get_nr_hugepages (int numa_node, |