summaryrefslogtreecommitdiffstats
path: root/svm/svmdb.h
diff options
context:
space:
mode:
authorDave Barach <dave@barachs.net>2016-07-18 14:23:36 -0400
committerDave Barach <dave@barachs.net>2016-07-18 14:29:04 -0400
commit98cfc1aab07d311b53b0171fad62a4031c96fcfd (patch)
tree7779590482e032169590f2a5d1c4f4fcab66678f /svm/svmdb.h
parent2221cd8dd18e66bcdb9bb9a4114ba0c3dddcd00c (diff)
Add uid/gid config parameters to shared-vm database map operator
So vpp_get_metrics and similar will not need to run as root Change-Id: I635e830834c82990ad84ddaae06f2e50e55fd616 Signed-off-by: Dave Barach <dave@barachs.net>
Diffstat (limited to 'svm/svmdb.h')
-rw-r--r--svm/svmdb.h16
1 files changed, 9 insertions, 7 deletions
diff --git a/svm/svmdb.h b/svm/svmdb.h
index 5f44b33280d..a113c22d10d 100644
--- a/svm/svmdb.h
+++ b/svm/svmdb.h
@@ -81,19 +81,21 @@ typedef struct
u32 opaque:28;
} svmdb_notification_args_t;
+typedef struct
+{
+ char *root_path;
+ uword size;
+ u32 uid;
+ u32 gid;
+} svmdb_map_args_t;
+
/*
* Must be a reasonable number, several mb smaller than
* SVM_GLOBAL_REGION_SIZE, or no donut for you...
*/
#define SVMDB_DEFAULT_SIZE (4<<20)
-svmdb_client_t *svmdb_map (void);
-
-svmdb_client_t *svmdb_map_size (uword size);
-
-svmdb_client_t *svmdb_map_chroot (char *root_path);
-
-svmdb_client_t *svmdb_map_chroot_size (char *root_path, uword size);
+svmdb_client_t *svmdb_map (svmdb_map_args_t *);
void svmdb_unmap (svmdb_client_t * client);
void svmdb_local_unset_string_variable (svmdb_client_t * client, char *var);