aboutsummaryrefslogtreecommitdiff
path: root/procfs.c
diff options
context:
space:
mode:
authorJustus Winter <4winter@informatik.uni-hamburg.de>2013-07-16 10:51:22 +0200
committerSamuel Thibault <samuel.thibault@ens-lyon.org>2013-07-20 17:55:16 +0200
commit890f987c15029d7e29f7deea0bba0b8d4ecaeaeb (patch)
treea8d6b438f9792c5fddb2c9b17fb9f18f4ddcec5f /procfs.c
parent641249f6b143c4e22825e18e0dbe22bb04d21138 (diff)
downloadhurd-890f987c15029d7e29f7deea0bba0b8d4ecaeaeb.tar.gz
hurd-890f987c15029d7e29f7deea0bba0b8d4ecaeaeb.tar.bz2
hurd-890f987c15029d7e29f7deea0bba0b8d4ecaeaeb.zip
Add the necessary infrastructure to serve passive translators
* netfs.c (netfs_get_translator): New function. * procfs.c (procfs_get_translator): Likewise. * procfs.h (struct procfs_node_ops): New field get_translator. (procfs_get_translator): New function declaration.
Diffstat (limited to 'procfs.c')
-rw-r--r--procfs.c12
1 files changed, 12 insertions, 0 deletions
diff --git a/procfs.c b/procfs.c
index 44e4f7e7..cae4a519 100644
--- a/procfs.c
+++ b/procfs.c
@@ -205,3 +205,15 @@ void procfs_cleanup (struct node *np)
free (np->nn);
}
+
+error_t procfs_get_translator (struct node *np,
+ char **argz,
+ size_t *argz_len)
+{
+ if (np->nn->ops->get_translator)
+ return np->nn->ops->get_translator (np->nn->hook, argz, argz_len);
+
+ *argz = NULL;
+ *argz_len = 0;
+ return 0;
+}