/*************************************************************************
*** Copyright (c) 2006, Video Surveillance,Inc.
***
*** File name  : mymount.h
***
*** Module	 : my mount API
***
*** Author	 : Cham Li
***
*** Version	: 1.0
***
*** Created On : 04/09/2008
***
*** Description:
***			my mount API prototype.
***
*** Modification histroy:
***
**************************************************************************/



#ifndef __MYMOUNT_H_
#define __MYMOUNT_H_

#ifdef __cplusplus
extern "C" {
#endif



#define MM_TIMEOUT_RECOMM  5  // recommended value for timeout parameter, in seconds
#define MM_FLAG_FILE	   "/mymount_flag"



/* return values */

#define MM_ERR_OK				   0
#define MM_ERR_UNKNOWN			  1
#define MM_ERR_INVALID_PARAS		2
#define MM_ERR_CREATE_FLAG_FILE	 3
#define MM_ERR_WRITE_FLAG_FILE	  4
#define MM_ERR_FORK				 5
#define MM_ERR_MOUNT				6
#define MM_ERR_TIMEOUT			  7


#define bindStr "--bind"
#define softStr "-o soft"
#define autoStr "-t auto"

/* my mount API.
   return MM_ERR_XXX */

int mymount(
	const char   *netPath,   /* source path (including mount parameters) */
	const char   *mntPath,   /* destination path */
	unsigned int  timeout);  /* timeout in seconds */



#ifdef __cplusplus
}
#endif

#endif /* __MYMOUNT_H_ */

