/*-1* SPDX-License-Identifier: BSD-2-Clause2*3* Copyright (c) 2013 The FreeBSD Foundation4*5* This software was developed by Edward Tomasz Napierala under sponsorship6* from the FreeBSD Foundation.7*8* Redistribution and use in source and binary forms, with or without9* modification, are permitted provided that the following conditions10* are met:11* 1. Redistributions of source code must retain the above copyright12* notice, this list of conditions and the following disclaimer.13* 2. Redistributions in binary form must reproduce the above copyright14* notice, this list of conditions and the following disclaimer in the15* documentation and/or other materials provided with the distribution.16*17* THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND18* ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE19* IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE20* ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE21* FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL22* DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS23* OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)24* HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT25* LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY26* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF27* SUCH DAMAGE.28*/2930#ifndef AUTOFS_IOCTL_H31#define AUTOFS_IOCTL_H3233#define AUTOFS_PATH "/dev/autofs"3435struct autofs_daemon_request {36/*37* Request identifier.38*/39int adr_id;4041/*42* The "from" field, containing map name. For example,43* when accessing '/net/192.168.1.3/tank/vm/', that would44* be '-hosts'.45*/46char adr_from[MAXPATHLEN];4748/*49* Full path to the node being looked up; for requests that result50* in actual mount it is the full mount path.51*/52char adr_path[MAXPATHLEN];5354/*55* Prefix, which is basically the mountpoint from auto_master(5).56* In example above that would be "/net"; for direct maps it is "/".57*/58char adr_prefix[MAXPATHLEN];5960/*61* Map key, also used as command argument for dynamic maps; in example62* above that would be '192.168.1.3'.63*/64char adr_key[MAXPATHLEN];6566/*67* Mount options from auto_master(5).68*/69char adr_options[MAXPATHLEN];70};7172/*73* Compatibility with 10.1-RELEASE automountd(8).74*/75struct autofs_daemon_done_101 {76/*77* Identifier, copied from adr_id.78*/79int add_id;8081/*82* Error number, possibly returned to userland.83*/84int add_error;85};8687struct autofs_daemon_done {88/*89* Identifier, copied from adr_id.90*/91int add_id;9293/*94* Set to 1 if the map may contain wildcard entries;95* otherwise autofs will do negative caching.96*/97int add_wildcards;9899/*100* Error number, possibly returned to userland.101*/102int add_error;103104/*105* Reserved for future use.106*/107int add_spare[7];108};109110#define AUTOFSREQUEST _IOR('I', 0x01, struct autofs_daemon_request)111#define AUTOFSDONE101 _IOW('I', 0x02, struct autofs_daemon_done_101)112#define AUTOFSDONE _IOW('I', 0x03, struct autofs_daemon_done)113114#endif /* !AUTOFS_IOCTL_H */115116117