From 3a5bcbcc94f01b1ef1ed0571b31434ed57162224 Mon Sep 17 00:00:00 2001 From: Justus Winter <4winter@informatik.uni-hamburg.de> Date: Tue, 30 Jul 2013 11:59:20 +0200 Subject: libnetfs: add fsys_get_source Add a user overridable function netfs_get_source with a default implementation returning EOPNOTSUPP. Add a server function for fsys-get-source. * libnetfs/Makefile: Add fsys-get-source.c and get-source.c * libnetfs/netfs.h: Add netfs_get_source. * libnetfs/fsys-get-source.c: New file. * libnetfs/get-source.c: Likewise. --- libnetfs/netfs.h | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) (limited to 'libnetfs/netfs.h') diff --git a/libnetfs/netfs.h b/libnetfs/netfs.h index 2b9454a9..e10ccae0 100644 --- a/libnetfs/netfs.h +++ b/libnetfs/netfs.h @@ -1,6 +1,6 @@ /* - Copyright (C) 1994,95,96,97,99,2000,02 Free Software Foundation, Inc. + Copyright (C) 1994,95,96,97,99,2000,02,13 Free Software Foundation, Inc. This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as @@ -313,6 +313,12 @@ error_t netfs_file_get_storage_info (struct iouser *cred, mach_msg_type_number_t *num_offsets, char **data, mach_msg_type_number_t *data_len); + +/* The user may define this function. The function must set source to + the source device of the filesystem. The function may return an + EOPNOTSUPP to indicate that the concept of a source device is not + applicable. The default function always returns EOPNOTSUPP. */ +error_t netfs_get_source (char *source); /* Option parsing */ -- cgit v1.2.3