forked from xmirror/moosefs
-
Notifications
You must be signed in to change notification settings - Fork 8
/
Copy pathopenfiles.h
43 lines (37 loc) · 1.46 KB
/
openfiles.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
/*
* Copyright (C) 2015 Jakub Kruszona-Zawadzki, Core Technology Sp. z o.o.
*
* This file is part of MooseFS.
*
* MooseFS is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, version 2 (only).
*
* MooseFS 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 General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with MooseFS; if not, write to the Free Software
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
* or visit http://www.gnu.org/licenses/gpl-2.0.html
*/
#ifndef _OPENEDFILES_H_
#define _OPENEDFILES_H_
#include <inttypes.h>
#include "bio.h"
uint8_t of_checknode(uint32_t sessionid,uint32_t inode);
void of_openfile(uint32_t sessionid,uint32_t inode);
void of_sync(uint32_t sessionid,uint32_t *inode,uint32_t inodecnt);
void of_session_removed(uint32_t sessionid);
uint8_t of_isfileopened(uint32_t inode);
uint32_t of_noofopenedfiles(uint32_t sessionid);
uint32_t of_lsof(uint32_t sessionid,uint8_t *buff);
int of_mr_acquire(uint32_t sessionid,uint32_t inode);
int of_mr_release(uint32_t sessionid,uint32_t inode);
uint8_t of_store(bio *fd);
int of_load(bio *fd,uint8_t mver);
void of_cleanup(void);
int of_init(void);
#endif