Commit 8fb1e2ee authored by Linus Torvalds's avatar Linus Torvalds
Browse files

Merge tag 'linux_kselftest-next-6.14-rc1' of...

Merge tag 'linux_kselftest-next-6.14-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/shuah/linux-kselftest

Pull kselftest updates from Shuah Khan:

 - fixes, reporting improvements, and cleanup changes to several tests

 - add support for DT_GNU_HASH to selftests/vDSO

* tag 'linux_kselftest-next-6.14-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/shuah/linux-kselftest:
  selftests/rseq: Fix handling of glibc without rseq support
  selftests/resctrl: Discover SNC kernel support and adjust messages
  selftests/resctrl: Adjust effective L3 cache size with SNC enabled
  selftests/ftrace: Make uprobe test more robust against binary name
  selftests/ftrace: Fix to use remount when testing mount GID option
  selftests: tmpfs: Add kselftest support to tmpfs
  selftests: tmpfs: Add Test-skip if not run as root
  selftests: harness: fix printing of mismatch values in __EXPECT()
  selftests/ring-buffer: Add test for out-of-bound pgoff mapping
  selftests/run_kselftest.sh: Fix help string for --per-test-log
  selftests: acct: Add ksft_exit_skip if not running as root
  selftests: kselftest: Fix the wrong format specifier
  selftests: timers: clocksource-switch: Adapt progress to kselftest framework
  selftests/zram: gitignore output file
  selftests/filesystems: Add missing gitignore file
  selftests: Warn about skipped tests in result summary
  selftests: kselftest: Add ksft_test_result_xpass
  selftests/vDSO: support DT_GNU_HASH
  selftests/ipc: Remove unused variables
  selftest: media_tests: fix trivial UAF typo
parents 88e969fc 336d02bc
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -24,7 +24,7 @@ int main(void)

	// Check if test is run a root
	if (geteuid()) {
		ksft_test_result_skip("This test needs root to run!\n");
		ksft_exit_skip("This test needs root to run!\n");
		return 1;
	}

+1 −0
Original line number Diff line number Diff line
# SPDX-License-Identifier: GPL-2.0-only
statmount_test_ns
/*_test
+4 −4
Original line number Diff line number Diff line
@@ -15,11 +15,11 @@ find_alternate_gid() {
	tac /etc/group | grep -v ":$original_gid:" | head -1 | cut -d: -f3
}

mount_tracefs_with_options() {
remount_tracefs_with_options() {
	local mount_point="$1"
	local options="$2"

	mount -t tracefs -o "$options" nodev "$mount_point"
	mount -t tracefs -o "remount,$options" nodev "$mount_point"

	setup
}
@@ -81,7 +81,7 @@ test_gid_mount_option() {

	# Unmount existing tracefs instance and mount with new GID
	unmount_tracefs "$mount_point"
	mount_tracefs_with_options "$mount_point" "$new_options"
	remount_tracefs_with_options "$mount_point" "$new_options"

	check_gid "$mount_point" "$other_group"

@@ -92,7 +92,7 @@ test_gid_mount_option() {

	# Unmount and remount with the original GID
	unmount_tracefs "$mount_point"
	mount_tracefs_with_options "$mount_point" "$mount_options"
	remount_tracefs_with_options "$mount_point" "$mount_options"
	check_gid "$mount_point" "$original_group"
}

+3 −1
Original line number Diff line number Diff line
@@ -6,8 +6,10 @@
echo 0 > events/enable
echo > dynamic_events

REALBIN=`readlink -f /bin/sh`

echo 'cat /proc/$$/maps' | /bin/sh | \
	grep "r-xp .*/bin/.*sh$" | \
	grep "r-xp .*${REALBIN}$" | \
	awk '{printf "p:myevent %s:0x%s\n", $6,$3 }' >> uprobe_events

grep -q myevent uprobe_events
+1 −1
Original line number Diff line number Diff line
@@ -194,7 +194,7 @@ int fill_msgque(struct msgque_data *msgque)

int main(int argc, char **argv)
{
	int msg, pid, err;
	int err;
	struct msgque_data msgque;

	if (getuid() != 0)
Loading