nfs-ganesha 1.4
|
#include "fsal_convert.h"
#include "fsal_internal.h"
#include <sys/types.h>
#include <errno.h>
#include <hpss_errno.h>
Go to the source code of this file.
Defines | |
#define | MAX_2(x, y) ( (x) > (y) ? (x) : (y) ) |
#define | MAX_3(x, y, z) ( (x) > (y) ? MAX_2((x),(z)) : MAX_2((y),(z)) ) |
Functions | |
int | hpss2fsal_error (int hpss_errorcode) |
int | fsal2hpss_testperm (fsal_accessflags_t testperm) |
int | fsal2hpss_openflags (fsal_openflags_t fsal_flags, int *p_hpss_flags) |
fsal_nodetype_t | hpss2fsal_type (unsigned32 hpss_type_in) |
fsal_time_t | hpss2fsal_time (timestamp_sec_t tsec) |
fsal_u64_t | hpss2fsal_64 (u_signed64 hpss_size_in) |
u_signed64 | fsal2hpss_64 (fsal_u64_t fsal_size_in) |
fsal_fsid_t | hpss2fsal_fsid (u_signed64 hpss_fsid_in) |
fsal_accessmode_t | hpss2fsal_mode (unsigned32 uid_bit, unsigned32 gid_bit, unsigned32 sticky_bit, unsigned32 user_perms, unsigned32 group_perms, unsigned32 other_perms) |
void | fsal2hpss_mode (fsal_accessmode_t fsal_mode, unsigned32 *uid_bit, unsigned32 *gid_bit, unsigned32 *sticky_bit, unsigned32 *user_perms, unsigned32 *group_perms, unsigned32 *other_perms) |
fsal_status_t | hpss2fsal_attributes (ns_ObjHandle_t *p_hpss_handle_in, hpss_Attrs_t *p_hpss_attr_in, fsal_attrib_list_t *p_fsalattr_out) |
fsal_status_t | hpssHandle2fsalAttributes (ns_ObjHandle_t *p_hpsshandle_in, fsal_attrib_list_t *p_fsalattr_out) |
fsal_status_t | fsal2hpss_attribset (hpssfsal_handle_t *p_fsal_handle, fsal_attrib_list_t *p_attrib_set, hpss_fileattrbits_t *p_hpss_attrmask, hpss_Attrs_t *p_hpss_attrs) |
Definition at line 24 of file FSAL_HPSS/fsal_convert.c.
Definition at line 25 of file FSAL_HPSS/fsal_convert.c.
u_signed64 fsal2hpss_64 | ( | fsal_u64_t | fsal_size_in | ) |
fsal2hpss_64: Convert fsal_u64_t type to HPSS u_signed64 type.
fsal_size_in | (input): The FSAL 64 bits number. |
Definition at line 389 of file FSAL_HPSS/fsal_convert.c.
fsal_status_t fsal2hpss_attribset | ( | hpssfsal_handle_t * | p_fsal_handle, |
fsal_attrib_list_t * | p_attrib_set, | ||
hpss_fileattrbits_t * | p_hpss_attrmask, | ||
hpss_Attrs_t * | p_hpss_attrs | ||
) |
fsal2hpss_attribset: Converts an fsal attrib list to a hpss attrib list and values to be used in Setattr.
p_fsal_handle | (input): Pointer to the FSAL object handle. |
p_attrib_set | (input): Pointer to the FSAL attributes to be set. |
p_hpss_attrmask | (output): Pointer to the HPSS attribute list associated to the FSAL asked_attributes. |
p_hpss_attrs | (output): Pointer to the HPSS attribute values associated to input attributes. |
Definition at line 883 of file FSAL_HPSS/fsal_convert.c.
void fsal2hpss_mode | ( | fsal_accessmode_t | fsal_mode, |
unsigned32 * | uid_bit, | ||
unsigned32 * | gid_bit, | ||
unsigned32 * | sticky_bit, | ||
unsigned32 * | user_perms, | ||
unsigned32 * | group_perms, | ||
unsigned32 * | other_perms | ||
) |
fsal2hpss_mode: converts FSAL mode to HPSS mode.
fsal_mode | (input): The fsal mode to be translated. |
uid_bit | (output): The uid_bit field to be set in HPSS object attributes. |
gid_bit | (output): The gid_bit field to be set in HPSS object attributes. |
sticky_bit | (output): The sticky_bit field to be set in HPSS object attributes. |
user_perms | (output): The user_perms field to be set in HPSS object attributes. |
group_perms | (output): The group_perms field to be set in HPSS object attributes. |
other_perms | (output): The other_perms field to be set in HPSS object attributes. |
Definition at line 505 of file FSAL_HPSS/fsal_convert.c.
int fsal2hpss_openflags | ( | fsal_openflags_t | fsal_flags, |
int * | p_hpss_flags | ||
) |
fsal2hpss_openflags: Convert FSAL open flags to (HPSS) Posix open flags.
fsal_flags | (input): The FSAL open flags to be translated. |
p_hpss_flags | (output): Pointer to the HPSS open flags. |
Definition at line 252 of file FSAL_HPSS/fsal_convert.c.
int fsal2hpss_testperm | ( | fsal_accessflags_t | testperm | ) |
fsal2hpss_testperm: Convert FSAL permission flags to (HPSS) Posix permission flags.
testperm | (input): The FSAL permission flags to be tested. |
Definition at line 221 of file FSAL_HPSS/fsal_convert.c.
fsal_u64_t hpss2fsal_64 | ( | u_signed64 | hpss_size_in | ) |
hpss2fsal_64: Convert HPSS u_signed64 type to fsal_u64_t type.
hpss_size_in | (input): The HPSS 64 bits number. |
Definition at line 371 of file FSAL_HPSS/fsal_convert.c.
fsal_status_t hpss2fsal_attributes | ( | ns_ObjHandle_t * | p_hpss_handle_in, |
hpss_Attrs_t * | p_hpss_attr_in, | ||
fsal_attrib_list_t * | p_fsalattr_out | ||
) |
hpss2fsal_attributes: Fills an FSAL attributes structure with the info provided by the hpss handle and the hpss attributes of an object.
p_hpss_handle_in | (input): Pointer to the HPSS NS object handle. |
p_hpss_attr_in | (input): Pointer to the HPSS attributes. |
p_fsalattr_out | (input/output): Pointer to the FSAL attributes. As input, it defines the attributes that the caller wants to retrieve (by positioning flags into this structure) and the output is built considering this input (it fills the structure according to the flags it contains). |
p_cred | (input) HPSS Credential. |
Definition at line 602 of file FSAL_HPSS/fsal_convert.c.
int hpss2fsal_error | ( | int | hpss_errorcode | ) |
hpss2fsal_error : Convert HPSS error codes to FSAL error codes.
hpss_errorcode | (input): The error code returned from HPSS. |
Definition at line 38 of file FSAL_HPSS/fsal_convert.c.
fsal_fsid_t hpss2fsal_fsid | ( | u_signed64 | hpss_fsid_in | ) |
hpss2fsal_fsid: Convert HPSS fsid type to FSAL fsid type.
hpss_fsid_in | (input): The HPSS fsid to be translated. |
Definition at line 408 of file FSAL_HPSS/fsal_convert.c.
fsal_accessmode_t hpss2fsal_mode | ( | unsigned32 | uid_bit, |
unsigned32 | gid_bit, | ||
unsigned32 | sticky_bit, | ||
unsigned32 | user_perms, | ||
unsigned32 | group_perms, | ||
unsigned32 | other_perms | ||
) |
hpss2fsal_mode: Convert HPSS mode to FSAL mode.
uid_bit | (input): The uid_bit field from HPSS object attributes. |
gid_bit | (input): The gid_bit field from HPSS object attributes. |
sticky_bit | (input): The sticky_bit field from HPSS object attributes. |
user_perms | (input): The user_perms field from HPSS object attributes. |
group_perms | (input): The group_perms field from HPSS object attributes. |
other_perms | (input): The other_perms field from HPSS object attributes. |
Definition at line 439 of file FSAL_HPSS/fsal_convert.c.
fsal_time_t hpss2fsal_time | ( | timestamp_sec_t | tsec | ) |
hpss2fsal_time: Convert HPSS time structure (timestamp_sec_t) to FSAL time type (fsal_time_t).
Definition at line 350 of file FSAL_HPSS/fsal_convert.c.
fsal_nodetype_t hpss2fsal_type | ( | unsigned32 | hpss_type_in | ) |
hpss2fsal_type: Convert HPSS NS object type to FSAL node type.
hpss_type_in | (input): The HPSS NS object type from NSObjHandle.Type. |
Definition at line 319 of file FSAL_HPSS/fsal_convert.c.
fsal_status_t hpssHandle2fsalAttributes | ( | ns_ObjHandle_t * | p_hpsshandle_in, |
fsal_attrib_list_t * | p_fsalattr_out | ||
) |
hpssHandle2fsalAttributes: Fills an FSAL attributes structure with the info provided (only) by the hpss handle of an object.
p_hpsshandle_in | (input): Pointer to the HPSS NS object handle. |
p_fsalattr_out | (input/output): Pointer to the FSAL attributes. As input, it defines the attributes that the caller wants to retrieve (by positioning flags into this structure) and the output is built considering this input (it fills the structure according to the flags it contains). |
Definition at line 817 of file FSAL_HPSS/fsal_convert.c.