source: rtems/cpukit/libmisc/fsmount/fsmount.h @ 6f77f16f

4.104.114.84.95
Last change on this file since 6f77f16f was 6f77f16f, checked in by Joel Sherrill <joel.sherrill@…>, on 09/17/04 at 17:00:19

2004-09-17 Joel Sherrill <joel@…>

PR 677/misc

  • libmisc/dumpbuf/dumpbuf.h, libmisc/fsmount/fsmount.h, libmisc/rtmonuse/rtmonuse.h, libmisc/serdbg/serdbg.h, libmisc/serdbg/serdbgcnf.h, libmisc/serdbg/termios_printk.h, libmisc/serdbg/termios_printk_cnf.h, libmisc/untar/untar.h: Add extern C wrappers.
  • Property mode set to 100644
File size: 3.6 KB
Line 
1/*===============================================================*\
2| Project: RTEMS fsmount                                          |
3+-----------------------------------------------------------------+
4| File: fsmount.h                                                 |
5+-----------------------------------------------------------------+
6|                    Copyright (c) 2003 IMD                       |
7|      Ingenieurbuero fuer Microcomputertechnik Th. Doerfler      |
8|               <Thomas.Doerfler@imd-systems.de>                  |
9|                       all rights reserved                       |
10+-----------------------------------------------------------------+
11| this file contains the fsmount functions. These functions       |
12| are used to mount a list of filesystems (and create their mount |
13| points before)                                                  |
14|                                                                 |
15|  The license and distribution terms for this file may be        |
16|  found in the file LICENSE in this distribution or at           |
17|  http://www.rtems.com/license/LICENSE.                     |
18|                                                                 |
19+-----------------------------------------------------------------+
20|   date                      history                        ID   |
21| ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
22| 02.07.03  creation                                         doe  |
23\*===============================================================*/
24
25#ifndef _FSMOUNT_H
26#define _FSMOUNT_H
27
28#include <rtems.h>
29#include <rtems/libio.h>
30#include <rtems/libcsupport.h>
31
32#ifdef __cplusplus
33extern "C" {
34#endif
35
36/*
37 * bits to define, what errors will cause reporting (via printf) and
38 * abort of mount processing
39 * Use a combination of these bits
40 * for the fields "report_reasons" and "abort_reasons"
41 */
42#define FSMOUNT_MNT_OK        0x0001 /* mounted ok                 */
43#define FSMOUNT_MNTPNT_CRTERR 0x0002 /* cannot create mount point  */
44#define FSMOUNT_MNT_FAILED    0x0004 /* mounting failed            */
45
46typedef struct {
47  char *dev;
48  char *mount_point;
49  rtems_filesystem_operations_table *fs_ops;
50  rtems_filesystem_options_t mount_options;
51  uint16_t   report_reasons;
52  uint16_t   abort_reasons;
53} fstab_t;
54
55
56/*=========================================================================*\
57| Function:                                                                 |
58\*-------------------------------------------------------------------------*/
59int rtems_fsmount
60(
61/*-------------------------------------------------------------------------*\
62| Purpose:                                                                  |
63|  This function will create the mount points listed and mount the file     |
64|   systems listed in the calling parameters                                |
65+---------------------------------------------------------------------------+
66| Input Parameters:                                                         |
67\*-------------------------------------------------------------------------*/
68 const fstab_t *fstab_ptr,              /* Ptr to filesystem mount table   */
69 int fstab_count,                       /* number of entries in mount table*/
70 int *fail_idx                          /* return: index of failed entry   */
71 );
72/*-------------------------------------------------------------------------*\
73| Return Value:                                                             |
74|    0, if success, -1 and errno if failed                                  |
75\*=========================================================================*/
76
77#ifdef __cplusplus
78}
79#endif
80
81#endif /* _FSMOUNT_H */
Note: See TracBrowser for help on using the repository browser.