devfs_ops.c File Reference

Implementation of VFS operations for the devfs file system server. More...

#include <macros.h>
#include <bool.h>
#include <errno.h>
#include <malloc.h>
#include <str.h>
#include <libfs.h>
#include <fibril_synch.h>
#include <adt/hash_table.h>
#include <ipc/devmap.h>
#include <sys/stat.h>
#include <assert.h>
#include "devfs.h"
#include "devfs_ops.h"

Go to the source code of this file.

Data Structures

struct  devfs_node_t
struct  device_t
 Opened devices structure. More...

Defines

#define DEVICES_BUCKETS   256
#define DEVICES_KEY_HANDLE   0
#define DEVICES_KEYS   1

Functions

void devfs_close (ipc_callid_t rid, ipc_call_t *request)
static int devfs_create_node (fs_node_t **rfn, devmap_handle_t devmap_handle, int lflag)
void devfs_destroy (ipc_callid_t rid, ipc_call_t *request)
static int devfs_destroy_node (fs_node_t *fn)
static devmap_handle_t devfs_device_get (fs_node_t *fn)
static int devfs_has_children (bool *has_children, fs_node_t *fn)
static fs_index_t devfs_index_get (fs_node_t *fn)
bool devfs_init (void)
static bool devfs_is_directory (fs_node_t *fn)
static bool devfs_is_file (fs_node_t *fn)
static int devfs_link_node (fs_node_t *pfn, fs_node_t *cfn, const char *nm)
static unsigned int devfs_lnkcnt_get (fs_node_t *fn)
void devfs_lookup (ipc_callid_t rid, ipc_call_t *request)
static int devfs_match (fs_node_t **rfn, fs_node_t *pfn, const char *component)
void devfs_mount (ipc_callid_t rid, ipc_call_t *request)
void devfs_mounted (ipc_callid_t rid, ipc_call_t *request)
static int devfs_node_get (fs_node_t **rfn, devmap_handle_t devmap_handle, fs_index_t index)
static int devfs_node_get_internal (fs_node_t **rfn, devmap_handle_type_t type, devmap_handle_t handle)
static int devfs_node_open (fs_node_t *fn)
static int devfs_node_put (fs_node_t *fn)
void devfs_open_node (ipc_callid_t rid, ipc_call_t *request)
static char devfs_plb_get_char (unsigned pos)
void devfs_read (ipc_callid_t rid, ipc_call_t *request)
static int devfs_root_get (fs_node_t **rfn, devmap_handle_t devmap_handle)
static aoff64_t devfs_size_get (fs_node_t *fn)
void devfs_stat (ipc_callid_t rid, ipc_call_t *request)
void devfs_sync (ipc_callid_t rid, ipc_call_t *request)
void devfs_truncate (ipc_callid_t rid, ipc_call_t *request)
static int devfs_unlink_node (fs_node_t *pfn, fs_node_t *cfn, const char *nm)
void devfs_unmount (ipc_callid_t rid, ipc_call_t *request)
void devfs_unmounted (ipc_callid_t rid, ipc_call_t *request)
void devfs_write (ipc_callid_t rid, ipc_call_t *request)
static int devices_compare (unsigned long key[], hash_count_t keys, link_t *item)
static hash_index_t devices_hash (unsigned long key[])
static void devices_remove_callback (link_t *item)
static FIBRIL_MUTEX_INITIALIZE (devices_mutex)
 Hash table mutex.

Variables

libfs_ops_t devfs_libfs_ops
 libfs operations
static hash_table_t devices
 Hash table of opened devices.
static hash_table_operations_t devices_ops


Detailed Description

Implementation of VFS operations for the devfs file system server.

Definition in file devfs_ops.c.


Generated on Thu Jun 2 07:45:54 2011 for HelenOS/USB by  doxygen 1.4.7