1/*
2 * This program is free software; you can redistribute it and/or
3 * modify it under the terms of the GNU General Public License as
4 * published by the Free Software Foundation; either version 2 of
5 * the License, or (at your option) any later version.
6 *
7 * This program is distributed in the hope that it will be useful,
8 * but WITHOUT ANY WARRANTY; without even the implied warranty of
9 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
10 * GNU General Public License for more details.
11 *
12 * You should have received a copy of the GNU General Public License
13 * along with this program; if not, write to the Free Software
14 * Foundation, Inc., 59 Temple Place, Suite 330, Boston,
15 * MA 02111-1307 USA
16 */
17#ifndef _DISK_IO_TOOLS_
18#define _DISK_IO_TOOLS_
19
20#include <stdio.h>
21
22typedef unsigned char u8;
23typedef unsigned short u16;
24typedef unsigned int u32;
25typedef unsigned long long u64;
26
27#if defined(WL500)
28#define POOL_MOUNT_ROOT "/tmp/harddisk"
29#define BASE_LAYER 2
30//#elif defined(RTN56U)
31//#define POOL_MOUNT_ROOT "/media"	// for n13u
32//#define BASE_LAYER 1
33#else
34#define POOL_MOUNT_ROOT "/tmp/mnt"
35#define BASE_LAYER 2
36#endif
37
38#define MOUNT_LAYER BASE_LAYER+1
39
40#define WWW_MOUNT_ROOT "/www"
41
42extern int mkdir_if_none(const char *dir);
43extern int delete_file_or_dir(char *target);
44
45extern int test_if_mount_point_of_pool(const char *dirname);
46extern int test_if_System_folder(const char *const dirname);
47extern int test_mounted_disk_size_status(char *diskpath);
48
49extern void strntrim(char *str);
50/*extern void write_escaped_value(FILE *fp, const char *value);//*/
51
52#endif // _DISK_IO_TOOLS_
53