mm/ksm: enable merge_across_nodes knob before testing

This kernel commit 90bd6fd31c809(ksm: allow trees per NUMA node)
introduced a new KSM sysfs knob /sys/kernel/mm/ksm/merge_across_nodes,
when it is set to zero, only pages from the same node are merged,
which is different with the previous behavior, and ksm test cases
sometimes will fail in NUMA system.

Signed-off-by: Zhouping Liu <zliu@redhat.com>
Signed-off-by: Wanlong Gao <gaowanlong@cn.fujitsu.com>
mem: introduce clean_node() func

There's set_node func introduced in commit cb2967b27a65, but we
don't have a func to clean the node mask yet.

Signed-off-by: Zhouping Liu <zliu@redhat.com>
Signed-off-by: Wanlong Gao <gaowanlong@cn.fujitsu.com>
mem/ksm06: add a new case to test merge_across_nodes sysfs knob

Kernel commit 90bd6fd31c8097(ksm: allow trees per NUMA node)
introduced a new ksm sysfs knob /sys/kernel/mm/ksm/merge_across_nodes,
which makes NUMA awareness KSM.

The case is designed to check whether KSM can merge the same shared
pages distributed on different numa nodes when enabling or disabling
merge_across_nodes.

Signed-off-by: Zhouping Liu <zliu@redhat.com>
Signed-off-by: Wanlong Gao <gaowanlong@cn.fujitsu.com>
mount/mount03.c: cleanup

1. Remove useless comments

2. Revise code to follow ltp-code-style

Signed-off-by: DAN LI <li.dan@cn.fujitsu.com>
Reviewed-by: Eryu Guan <eguan@redhat.com>
Signed-off-by: Wanlong Gao <gaowanlong@cn.fujitsu.com>
mount/mount03.c: fix several issues

Make following fixes:
* Create the file before calling stat(file).
  Call get_current_dir_name() after tst_tmpdir().
  Fix incorrect using of snprintf().

* For MS_NOEXEC test, change judgement method to
  If errno is set to EACCES after execlp(exec-file), this case passes.

Signed-off-by: DAN LI <li.dan@cn.fujitsu.com>
Reviewed-by: Eryu Guan <eguan@redhat.com>
Signed-off-by: Wanlong Gao <gaowanlong@cn.fujitsu.com>
semctl/semctl01.c: cleanup

1. Remove useless comments

2. Revise code to follow ltp-code-style

Signed-off-by: DAN LI <li.dan@cn.fujitsu.com>
Signed-off-by: Wanlong Gao <gaowanlong@cn.fujitsu.com>
semctl/semctl01.c: Test features IPC_INFO, SEM_INFO and SEM_STAT

Additional tests for features IPC_INFO, SEM_INFO and SEM_STAT.

Signed-off-by: DAN LI <li.dan@cn.fujitsu.com>
Signed-off-by: Wanlong Gao <gaowanlong@cn.fujitsu.com>