|
nfs-ganesha 1.4
|
#include <stdio.h>#include <sys/types.h>#include <ctype.h>#include <stdlib.h>#include <dirent.h>#include <netdb.h>#include <netinet/in.h>#include <arpa/inet.h>#include <string.h>#include <pthread.h>#include <fcntl.h>#include <sys/file.h>#include <pwd.h>#include <grp.h>#include "log.h"#include "ganesha_rpc.h"#include "HashData.h"#include "HashTable.h"#include "nfs_core.h"#include "nfs4.h"#include "fsal.h"#include "nfs_tools.h"#include "nfs_exports.h"#include "nfs_file_handle.h"#include "sal_functions.h"Go to the source code of this file.
| #define seqid_all_one 0xFFFFFFFF |
Definition at line 73 of file nfs4_state_id.c.
| int compare_state_id | ( | hash_buffer_t * | buff1, |
| hash_buffer_t * | buff2 | ||
| ) |
Definition at line 103 of file nfs4_state_id.c.
Definition at line 121 of file nfs4_state_id.c.
| int display_state_id_key | ( | hash_buffer_t * | pbuff, |
| char * | str | ||
| ) |
Definition at line 86 of file nfs4_state_id.c.
| int display_state_id_val | ( | hash_buffer_t * | pbuff, |
| char * | str | ||
| ) |
Definition at line 91 of file nfs4_state_id.c.
| int display_stateid_other | ( | char * | other, |
| char * | str | ||
| ) |
Definition at line 78 of file nfs4_state_id.c.
| void nfs4_BuildStateId_Other | ( | char * | other | ) |
nfs4_BuildStateId_Other
This routine builds the 12 byte "other" portion of a stateid from the ServerEpoch and a 64 bit global counter.
| other | [OUT] the stateid.other object (a char[OTHERSIZE] string) |
Definition at line 184 of file nfs4_state_id.c.
| int nfs4_check_special_stateid | ( | cache_entry_t * | pentry, |
| const char * | tag, | ||
| int | access | ||
| ) |
nfs4_check_special_stateid
Special stateid, no open state, check to see if any share conflicts The stateid is all-0 or all-1
Definition at line 559 of file nfs4_state_id.c.
| int nfs4_Check_Stateid | ( | stateid4 * | pstate, |
| cache_entry_t * | pentry, | ||
| state_t ** | ppstate, | ||
| compound_data_t * | data, | ||
| char | flags, | ||
| const char * | tag | ||
| ) |
nfs4_Check_Stateid
This routine checks the availability of the stateid and returns a pointer to it
| pstate | [IN] pointer to the stateid to be checked. |
Definition at line 317 of file nfs4_state_id.c.
| int nfs4_Init_state_id | ( | nfs_state_id_parameter_t | param | ) |
nfs4_Init_state_id: Init the hashtable for Client Id cache.
Perform all the required initialization for hashtable State Id cache
| param | [IN] parameter used to init the duplicate request cache |
Definition at line 160 of file nfs4_state_id.c.
| int nfs4_State_Del | ( | char | other[OTHERSIZE] | ) |
nfs4_State_Del
This routine removes a state from the states's hashtable.
| other | [IN] stateid'other field, used as a hash key |
Definition at line 284 of file nfs4_state_id.c.
| int nfs4_State_Get_Pointer | ( | char | other[OTHERSIZE], |
| state_t ** | pstate_data | ||
| ) |
nfs4_State_Get_Pointer
This routine gets a pointer to a state from the states's hashtable.
| pstate | [IN] pointer to the stateid to be checked. |
| ppstate_data | [OUT] pointer's state found |
Definition at line 251 of file nfs4_state_id.c.
| int nfs4_State_Set | ( | char | other[OTHERSIZE], |
| state_t * | pstate_data | ||
| ) |
nfs4_State_Set
This routine sets a state into the states's hashtable.
| pstate | [IN] pointer to the stateid to be checked. |
Definition at line 207 of file nfs4_state_id.c.
| void nfs_State_PrintAll | ( | void | ) |
nfs4_State_PrintAll
This routine displays the content of the hashtable used to store the states.
Definition at line 513 of file nfs4_state_id.c.
| uint64_t state_id_rbt_hash_func | ( | hash_parameter_t * | p_hparam, |
| hash_buffer_t * | buffclef | ||
| ) |
Definition at line 138 of file nfs4_state_id.c.
| uint32_t state_id_value_hash_func | ( | hash_parameter_t * | p_hparam, |
| hash_buffer_t * | buffclef | ||
| ) |
Definition at line 126 of file nfs4_state_id.c.
| size_t strnlen | ( | const char * | s, |
| size_t | maxlen | ||
| ) |
vim:expandtab:shiftwidth=8:tabstop=8:
Copyright CEA/DAM/DIF (2008) contributeur : Philippe DENIEL philippe.deniel@cea.fr Thomas LEIBOVICI thomas.leibovici@cea.fr
This program is free software; you can redistribute it and/or modify it under the terms of the GNU Lesser General Public License as published by the Free Software Foundation; either version 3 of the License, or (at your option) any later version.
This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more details.
You should have received a copy of the GNU Lesser General Public License along with this library; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
---------------------------------------
nfs_state_id.c : The management of the state id cache.
$Header$
$Log$
| void update_stateid | ( | state_t * | pstate, |
| stateid4 * | presp, | ||
| compound_data_t * | data, | ||
| const char * | tag | ||
| ) |
Definition at line 519 of file nfs4_state_id.c.
| char all_one[OTHERSIZE] |
Definition at line 72 of file nfs4_state_id.c.
| char all_zero[OTHERSIZE] |
Definition at line 71 of file nfs4_state_id.c.
Definition at line 69 of file nfs4_state_id.c.
Definition at line 76 of file nfs4_state_id.c.
| pthread_mutex_t StateIdMutex = PTHREAD_MUTEX_INITIALIZER |
Definition at line 75 of file nfs4_state_id.c.
1.7.3