Add cli 2.7 to source code
Initial implementation of zlomekFS cli interface

modified:   CMakeLists.txt
modified:   config.h.cmake
modified:   zfsd/control/CMakeLists.txt
new file:   zfsd/control/cli/CMakeLists.txt
new file:   zfsd/control/cli/inc/control_zfsd_cli.h
new file:   zfsd/control/cli/lib/CMakeLists.txt
new file:   zfsd/control/cli/lib/cli-2.7/CMakeLists.txt
new file:   zfsd/control/cli/lib/cli-2.7/cpp/CMakeLists.txt
new file:   zfsd/control/cli/lib/cli-2.7/cpp/src/CMakeLists.txt
modified:   zfsd/control/cli/lib/cli-2.7/cpp/src/ncurses_console.cpp
new file:   zfsd/control/cli/src/CMakeLists.txt
renamed:    zfsd/control/cli/src/gozfsd.cpp -> zfsd/control/cli/src/control_zfsd_cli.cpp
renamed:    zfsd/control/cli/src/gozfsd.h -> zfsd/control/cli/src/control_zfsd_cli.h
renamed:    zfsd/control/cli/src/zfsd.xml -> zfsd/control/cli/src/zfsd_cli.xml
modified:   zfsd/control/cli/src/zfsd_cli_impl.h
modified:   zfsd/control/control.c
modified:   zfsd/include/system.h
modified:   zfsd/lib/log/log.h
modified:   zfsd/lib/threading/pthread-wrapper.h
Improve library detection

modified:   CMakeLists.txt
modified:   zfsd/control/cli/lib/cli-2.7/cpp/src/CMakeLists.txt
modified:   zfsd/control/cli/src/CMakeLists.txt
Fix Mac OS X build issues

modified:   ../zfsd/control/cli/lib/cli-2.7/cpp/src/CMakeLists.txt
modified:   ../zfsd/control/cli/lib/cli-2.7/cpp/src/io_device.cpp
Improve build of CLI interface

modified:   ../../../../CMakeLists.txt
modified:   ../lib/cli-2.7/cpp/src/CMakeLists.txt
modified:   CMakeLists.txt
Improve cli integration to zlomekFS

modified:   CMakeLists.txt
modified:   config.h.cmake
new file:   scripts/gen_single_ncfg.sh
modified:   zfsd/configuration/CMakeLists.txt
new file:   zfsd/configuration/gen_sample_cfg/CMakeLists.txt
new file:   zfsd/configuration/gen_sample_cfg/gen_sample_cfg.c
modified:   zfsd/control/cli/lib/cli-2.7/cpp/src/CMakeLists.txt
modified:   zfsd/control/cli/src/control_zfsd_cli.cpp
modified:   zfsd/zfsd/zfsd.c
modified:   zfsd/zfsd/zfsd_args_fuse.c
modified:   zfsd/zfsd/zfsd_args_nofuse.c
Fix Linux CMake issues

modified:   ../CMakeLists.txt
Add new target to cmake run_single terminate_single

modified:   ../CMakeLists.txt
modified:   ../scripts/gen_single_ncfg.sh
modified:   ../zfsd/configuration/gen_sample_cfg/gen_sample_cfg.c
Import of posix test suite from http://www.tuxera.com/community/posix-test-suite/
Fix unmount on Windows

modified:   ../CMakeLists.txt
Merge remote-tracking branch 'origin/cli' into cli
Add metadata deep to local config

modified:   configuration/zfs_config/CMakeLists.txt
modified:   configuration/zfs_config/zfs_config.c
modified:   configuration/zfs_config/zfs_config.h
modified:   fs-entities/metadata/metadata.c
Improve posix fstest intergration

modified:   .gitignore
modified:   CMakeLists.txt
new file:   tests/posix-test-suite/pjd-fstest-20080816/CMakeLists.txt
modified:   tests/posix-test-suite/pjd-fstest-20080816/tests/misc.sh
modified:   zfsd/control/cli/src/CMakeLists.txt
modified:   zfsd/fs-entities/cap/CMakeLists.txt
modified:   zfsd/fs-entities/volume/CMakeLists.txt
Improve cli implementation, partial fix of race condifion which leads to deadlock.

Fix dentry and capability lock implementation:
* use only exclusive lock, shared seems to be in zlomekFS broken.
* same pthread condition should be used with the same mutex

Partial fix race condition between fh_mutex and internal_fd_data[fh->fd].mutex which leads to deadlock.
T1: lock(fh_mutex);
T1: lock(internal_fd_data[fd1].mutex);
T1: unlock(fh);
T2: lock(fh_mutex);
T2: lockinternal_fd_data[fd1].mutex); // wait for T1

T1 lock(fh_mutex); // wait for T2 (Coffman -> deadlock)

Fix: don't unlock fh_mutex when is internal_fd_data[fd1].mutex held
(modified funccion local_read()).

modified:   zfsd/configuration/zfs_config/zfs_config.c
modified:   zfsd/configuration/zfs_config/zfs_config.h
modified:   zfsd/control/cli/src/control_zfsd_cli.cpp
modified:   zfsd/control/cli/src/zfsd_cli.xml
modified:   zfsd/control/cli/src/zfsd_cli_impl.h
modified:   zfsd/control/control.c
modified:   zfsd/control/control.h
modified:   zfsd/fs-entities/cap/cap.c
modified:   zfsd/fs-entities/dir/dir.c
modified:   zfsd/fs-entities/file/file.c
modified:   zfsd/fs-entities/file/file.h
modified:   zfsd/fs-entities/handle/fh.c
modified:   zfsd/fs-entities/handle/fh.h
modified:   zfsd/fs-entities/node/node.c
modified:   zfsd/fs-entities/node/node.h
modified:   zfsd/fs-entities/volume/volume.c
modified:   zfsd/fs-entities/volume/volume.h
modified:   zfsd/network/network.c
modified:   zfsd/zfsd/zfsd_args_nofuse.c
Merge branch 'cli' of github.com:snua12/zlomekfs into cli
Modify posix test suite tests for zlomekFS testing

modified:   CMakeLists.txt
new file:   tests/posix-test-suite/pjd-fstest-20080816/.gitignore
modified:   tests/posix-test-suite/pjd-fstest-20080816/tests/chmod/00.t
modified:   tests/posix-test-suite/pjd-fstest-20080816/tests/chmod/01.t
modified:   tests/posix-test-suite/pjd-fstest-20080816/tests/chmod/02.t
modified:   tests/posix-test-suite/pjd-fstest-20080816/tests/chmod/03.t
modified:   tests/posix-test-suite/pjd-fstest-20080816/tests/chmod/04.t
modified:   tests/posix-test-suite/pjd-fstest-20080816/tests/chmod/05.t
modified:   tests/posix-test-suite/pjd-fstest-20080816/tests/chmod/06.t
modified:   tests/posix-test-suite/pjd-fstest-20080816/tests/chmod/07.t
modified:   tests/posix-test-suite/pjd-fstest-20080816/tests/chmod/08.t
modified:   tests/posix-test-suite/pjd-fstest-20080816/tests/chmod/09.t
modified:   tests/posix-test-suite/pjd-fstest-20080816/tests/chmod/10.t
modified:   tests/posix-test-suite/pjd-fstest-20080816/tests/chmod/11.t
modified:   tests/posix-test-suite/pjd-fstest-20080816/tests/chown/00.t
modified:   tests/posix-test-suite/pjd-fstest-20080816/tests/chown/01.t
modified:   tests/posix-test-suite/pjd-fstest-20080816/tests/chown/02.t
modified:   tests/posix-test-suite/pjd-fstest-20080816/tests/chown/03.t
modified:   tests/posix-test-suite/pjd-fstest-20080816/tests/chown/04.t
modified:   tests/posix-test-suite/pjd-fstest-20080816/tests/chown/05.t
modified:   tests/posix-test-suite/pjd-fstest-20080816/tests/chown/06.t
modified:   tests/posix-test-suite/pjd-fstest-20080816/tests/chown/07.t
modified:   tests/posix-test-suite/pjd-fstest-20080816/tests/chown/08.t
modified:   tests/posix-test-suite/pjd-fstest-20080816/tests/chown/09.t
modified:   tests/posix-test-suite/pjd-fstest-20080816/tests/chown/10.t
modified:   tests/posix-test-suite/pjd-fstest-20080816/tests/conf
modified:   tests/posix-test-suite/pjd-fstest-20080816/tests/link/00.t
modified:   tests/posix-test-suite/pjd-fstest-20080816/tests/link/02.t
modified:   tests/posix-test-suite/pjd-fstest-20080816/tests/link/03.t
modified:   tests/posix-test-suite/pjd-fstest-20080816/tests/link/06.t
modified:   tests/posix-test-suite/pjd-fstest-20080816/tests/link/07.t
modified:   tests/posix-test-suite/pjd-fstest-20080816/tests/link/11.t
modified:   tests/posix-test-suite/pjd-fstest-20080816/tests/misc.sh
modified:   tests/posix-test-suite/pjd-fstest-20080816/tests/mkdir/00.t
modified:   tests/posix-test-suite/pjd-fstest-20080816/tests/mkdir/02.t
modified:   tests/posix-test-suite/pjd-fstest-20080816/tests/mkdir/03.t
modified:   tests/posix-test-suite/pjd-fstest-20080816/tests/mkdir/05.t
modified:   tests/posix-test-suite/pjd-fstest-20080816/tests/mkdir/06.t
modified:   tests/posix-test-suite/pjd-fstest-20080816/tests/mkfifo/00.t
modified:   tests/posix-test-suite/pjd-fstest-20080816/tests/mkfifo/02.t
modified:   tests/posix-test-suite/pjd-fstest-20080816/tests/mkfifo/03.t
modified:   tests/posix-test-suite/pjd-fstest-20080816/tests/mkfifo/05.t
modified:   tests/posix-test-suite/pjd-fstest-20080816/tests/mkfifo/06.t
modified:   tests/posix-test-suite/pjd-fstest-20080816/tests/open/00.t
modified:   tests/posix-test-suite/pjd-fstest-20080816/tests/open/02.t
modified:   tests/posix-test-suite/pjd-fstest-20080816/tests/open/03.t
modified:   tests/posix-test-suite/pjd-fstest-20080816/tests/open/05.t
modified:   tests/posix-test-suite/pjd-fstest-20080816/tests/open/06.t
modified:   tests/posix-test-suite/pjd-fstest-20080816/tests/open/07.t
modified:   tests/posix-test-suite/pjd-fstest-20080816/tests/open/08.t
modified:   tests/posix-test-suite/pjd-fstest-20080816/tests/rename/00.t
modified:   tests/posix-test-suite/pjd-fstest-20080816/tests/rename/01.t
modified:   tests/posix-test-suite/pjd-fstest-20080816/tests/rename/02.t
modified:   tests/posix-test-suite/pjd-fstest-20080816/tests/rename/04.t
modified:   tests/posix-test-suite/pjd-fstest-20080816/tests/rename/05.t
modified:   tests/posix-test-suite/pjd-fstest-20080816/tests/rename/09.t
modified:   tests/posix-test-suite/pjd-fstest-20080816/tests/rename/10.t
modified:   tests/posix-test-suite/pjd-fstest-20080816/tests/rmdir/02.t
modified:   tests/posix-test-suite/pjd-fstest-20080816/tests/rmdir/03.t
modified:   tests/posix-test-suite/pjd-fstest-20080816/tests/rmdir/07.t
modified:   tests/posix-test-suite/pjd-fstest-20080816/tests/rmdir/08.t
modified:   tests/posix-test-suite/pjd-fstest-20080816/tests/rmdir/11.t
modified:   tests/posix-test-suite/pjd-fstest-20080816/tests/symlink/02.t
modified:   tests/posix-test-suite/pjd-fstest-20080816/tests/symlink/03.t
modified:   tests/posix-test-suite/pjd-fstest-20080816/tests/symlink/05.t
modified:   tests/posix-test-suite/pjd-fstest-20080816/tests/symlink/06.t
modified:   tests/posix-test-suite/pjd-fstest-20080816/tests/truncate/00.t
modified:   tests/posix-test-suite/pjd-fstest-20080816/tests/truncate/02.t
modified:   tests/posix-test-suite/pjd-fstest-20080816/tests/truncate/03.t
modified:   tests/posix-test-suite/pjd-fstest-20080816/tests/truncate/05.t
modified:   tests/posix-test-suite/pjd-fstest-20080816/tests/truncate/06.t
modified:   tests/posix-test-suite/pjd-fstest-20080816/tests/unlink/00.t
modified:   tests/posix-test-suite/pjd-fstest-20080816/tests/unlink/02.t
modified:   tests/posix-test-suite/pjd-fstest-20080816/tests/unlink/03.t
modified:   tests/posix-test-suite/pjd-fstest-20080816/tests/unlink/05.t
modified:   tests/posix-test-suite/pjd-fstest-20080816/tests/unlink/06.t
modified:   tests/posix-test-suite/pjd-fstest-20080816/tests/unlink/11.t
Extend CLI interface

modified:   zfsd/control/cli/src/zfsd_cli.xml
modified:   zfsd/control/cli/src/zfsd_cli_impl.h
modified:   zfsd/fs-entities/cap/cap.c
modified:   zfsd/fs-entities/dir/dir.c
modified:   zfsd/fs-entities/file/file.c
modified:   zfsd/fs-entities/handle/fh.c
modified:   zfsd/fs-entities/handle/fh.h
modified:   zfsd/fs-entities/metadata/metadata.c
modified:   zfsd/fs-entities/metadata/metadata.h
modified:   zfsd/fs-iface/fuse_iface/fuse_iface.c
modified:   zfsd/lib/zfs_dirent/zfs_dirent.c
modified:   zfsd/lib/zfs_dirent/zfs_dirent.h
modified:   zfsd/zfs-protocol/zfs-prot.c
modified:   zfsd/zfs-protocol/zfs-prot.h
Modify fstest-20080816 for zlomekFS testing under Cygwin

modified:   ../CMakeLists.txt
modified:   ../tests/posix-test-suite/pjd-fstest-20080816/tests/conf
modified:   ../tests/posix-test-suite/pjd-fstest-20080816/tests/link/00.t
modified:   ../tests/posix-test-suite/pjd-fstest-20080816/tests/link/02.t
modified:   ../tests/posix-test-suite/pjd-fstest-20080816/tests/link/03.t
modified:   ../tests/posix-test-suite/pjd-fstest-20080816/tests/link/08.t
modified:   ../tests/posix-test-suite/pjd-fstest-20080816/tests/link/09.t
modified:   ../tests/posix-test-suite/pjd-fstest-20080816/tests/link/10.t
modified:   ../tests/posix-test-suite/pjd-fstest-20080816/tests/link/17.t
modified:   ../tests/posix-test-suite/pjd-fstest-20080816/tests/misc.sh
modified:   ../tests/posix-test-suite/pjd-fstest-20080816/tests/mkdir/00.t
modified:   ../tests/posix-test-suite/pjd-fstest-20080816/tests/mkdir/02.t
modified:   ../tests/posix-test-suite/pjd-fstest-20080816/tests/mkdir/03.t
modified:   ../tests/posix-test-suite/pjd-fstest-20080816/tests/mkdir/07.t
modified:   ../tests/posix-test-suite/pjd-fstest-20080816/tests/mkdir/10.t
modified:   ../tests/posix-test-suite/pjd-fstest-20080816/tests/mkfifo/00.t
modified:   ../tests/posix-test-suite/pjd-fstest-20080816/tests/mkfifo/02.t
modified:   ../tests/posix-test-suite/pjd-fstest-20080816/tests/mkfifo/03.t
modified:   ../tests/posix-test-suite/pjd-fstest-20080816/tests/mkfifo/07.t
modified:   ../tests/posix-test-suite/pjd-fstest-20080816/tests/mkfifo/09.t
modified:   ../tests/posix-test-suite/pjd-fstest-20080816/tests/open/00.t
modified:   ../tests/posix-test-suite/pjd-fstest-20080816/tests/open/02.t
modified:   ../tests/posix-test-suite/pjd-fstest-20080816/tests/open/03.t
modified:   ../tests/posix-test-suite/pjd-fstest-20080816/tests/open/12.t
modified:   ../tests/posix-test-suite/pjd-fstest-20080816/tests/open/16.t
modified:   ../tests/posix-test-suite/pjd-fstest-20080816/tests/open/17.t
modified:   ../tests/posix-test-suite/pjd-fstest-20080816/tests/open/22.t
modified:   ../tests/posix-test-suite/pjd-fstest-20080816/tests/open/23.t
modified:   ../tests/posix-test-suite/pjd-fstest-20080816/tests/rename/00.t
modified:   ../tests/posix-test-suite/pjd-fstest-20080816/tests/rename/01.t
modified:   ../tests/posix-test-suite/pjd-fstest-20080816/tests/rename/02.t
modified:   ../tests/posix-test-suite/pjd-fstest-20080816/tests/rename/11.t
modified:   ../tests/posix-test-suite/pjd-fstest-20080816/tests/rename/13.t
modified:   ../tests/posix-test-suite/pjd-fstest-20080816/tests/rename/14.t
modified:   ../tests/posix-test-suite/pjd-fstest-20080816/tests/rename/20.t
modified:   ../tests/posix-test-suite/pjd-fstest-20080816/tests/rmdir/01.t
modified:   ../tests/posix-test-suite/pjd-fstest-20080816/tests/rmdir/02.t
modified:   ../tests/posix-test-suite/pjd-fstest-20080816/tests/rmdir/03.t
modified:   ../tests/posix-test-suite/pjd-fstest-20080816/tests/rmdir/05.t
modified:   ../tests/posix-test-suite/pjd-fstest-20080816/tests/rmdir/06.t
modified:   ../tests/posix-test-suite/pjd-fstest-20080816/tests/rmdir/12.t
modified:   ../tests/posix-test-suite/pjd-fstest-20080816/tests/symlink/00.t
modified:   ../tests/posix-test-suite/pjd-fstest-20080816/tests/symlink/02.t
modified:   ../tests/posix-test-suite/pjd-fstest-20080816/tests/symlink/03.t
modified:   ../tests/posix-test-suite/pjd-fstest-20080816/tests/symlink/07.t
modified:   ../tests/posix-test-suite/pjd-fstest-20080816/tests/truncate/02.t
modified:   ../tests/posix-test-suite/pjd-fstest-20080816/tests/truncate/03.t
modified:   ../tests/posix-test-suite/pjd-fstest-20080816/tests/truncate/07.t
modified:   ../tests/posix-test-suite/pjd-fstest-20080816/tests/truncate/12.t
modified:   ../tests/posix-test-suite/pjd-fstest-20080816/tests/unlink/00.t
modified:   ../tests/posix-test-suite/pjd-fstest-20080816/tests/unlink/02.t
modified:   ../tests/posix-test-suite/pjd-fstest-20080816/tests/unlink/03.t
modified:   ../tests/posix-test-suite/pjd-fstest-20080816/tests/unlink/07.t
modified:   ../zfsd/fs-iface/dokan_iface/dokan_iface.c
modified:   ../zfsd/fs-iface/dokan_iface/dokan_tools.c
modified:   ../zfsd/zfsd/zfsd_args_nofuse.c
Fix fstest for LINUX

modified:   ../../../tests/posix-test-suite/pjd-fstest-20080816/tests/link/02.t
modified:   ../../../tests/posix-test-suite/pjd-fstest-20080816/tests/misc.sh
modified:   ../../../tests/posix-test-suite/pjd-fstest-20080816/tests/mkfifo/02.t
Code cleanup

modified:   ../zfsd/fs-iface/dokan_iface/dokan_iface.c