forked from ~ljy/RK356X_SDK_RELEASE

hc
2024-10-22 8ac6c7a54ed1b98d142dce24b11c6de6a1e239a5
kernel/tools/testing/selftests/powerpc/dscr/dscr_sysfs_thread_test.c
....@@ -1,3 +1,4 @@
1
+// SPDX-License-Identifier: GPL-2.0-only
12 /*
23 * POWER Data Stream Control Register (DSCR) sysfs thread test
34 *
....@@ -7,10 +8,6 @@
78 * executing on individual CPUs on the system.
89 *
910 * Copyright 2015, Anshuman Khandual, IBM Corporation.
10
- *
11
- * This program is free software; you can redistribute it and/or modify it
12
- * under the terms of the GNU General Public License version 2 as published
13
- * by the Free Software Foundation.
1411 */
1512 #define _GNU_SOURCE
1613 #include "dscr.h"
....@@ -59,6 +56,8 @@
5956 unsigned long orig_dscr_default;
6057 int i, j;
6158
59
+ SKIP_IF(!have_hwcap2(PPC_FEATURE2_DSCR));
60
+
6261 orig_dscr_default = get_default_dscr();
6362 for (i = 0; i < COUNT; i++) {
6463 for (j = 0; j < DSCR_MAX; j++) {