Home
last modified time | relevance | path

Searched refs:expected (Results 1 – 25 of 512) sorted by relevance

12345678910>>...21

/Linux-v5.4/tools/testing/selftests/
Dkselftest_harness.h362 #define ASSERT_EQ(expected, seen) \ argument
363 __EXPECT(expected, #expected, seen, #seen, ==, 1)
373 #define ASSERT_NE(expected, seen) \ argument
374 __EXPECT(expected, #expected, seen, #seen, !=, 1)
384 #define ASSERT_LT(expected, seen) \ argument
385 __EXPECT(expected, #expected, seen, #seen, <, 1)
395 #define ASSERT_LE(expected, seen) \ argument
396 __EXPECT(expected, #expected, seen, #seen, <=, 1)
406 #define ASSERT_GT(expected, seen) \ argument
407 __EXPECT(expected, #expected, seen, #seen, >, 1)
[all …]
/Linux-v5.4/tools/perf/tests/shell/
Drecord+probe_libc_inet_pton.sh33 expected=`mktemp -u /tmp/expected.XXX`
35 echo "ping[][0-9 \.:]+$event_name: \([[:xdigit:]]+\)" > $expected
36 echo ".*inet_pton\+0x[[:xdigit:]]+[[:space:]]\($libc|inlined\)$" >> $expected
40 echo "gaih_inet.*\+0x[[:xdigit:]]+[[:space:]]\($libc|inlined\)$" >> $expected
41 echo "(__GI_)?getaddrinfo\+0x[[:xdigit:]]+[[:space:]]\($libc|inlined\)$" >> $expected
42 echo "main\+0x[[:xdigit:]]+[[:space:]]\(.*/bin/ping.*\)$" >> $expected
46 echo "gaih_inet.*\+0x[[:xdigit:]]+[[:space:]]\($libc\)$" >> $expected
47 echo "getaddrinfo\+0x[[:xdigit:]]+[[:space:]]\($libc\)$" >> $expected
48 echo ".*(\+0x[[:xdigit:]]+|\[unknown\])[[:space:]]\(.*/bin/ping.*\)$" >> $expected
52 echo "getaddrinfo\+0x[[:xdigit:]]+[[:space:]]\($libc\)$" >> $expected
[all …]
/Linux-v5.4/scripts/kconfig/tests/
Dconftest.py220 def _read_and_compare(self, compare, expected): argument
226 with open(os.path.join(self._test_dir, expected)) as f:
230 def _contains(self, attr, expected): argument
233 expected)
235 def _matches(self, attr, expected): argument
237 expected)
239 def config_contains(self, expected): argument
245 return self._contains('config', expected)
247 def config_matches(self, expected): argument
253 return self._matches('config', expected)
[all …]
/Linux-v5.4/tools/testing/selftests/powerpc/pmu/ebb/
Dreg_access_test.c18 uint64_t val, expected; in reg_access() local
22 expected = 0x8000000100000000ull; in reg_access()
23 mtspr(SPRN_BESCR, expected); in reg_access()
26 FAIL_IF(val != expected); in reg_access()
28 expected = 0x0000000001000000ull; in reg_access()
29 mtspr(SPRN_EBBHR, expected); in reg_access()
32 FAIL_IF(val != expected); in reg_access()
Dcycles_with_mmcr2_test.c25 uint64_t val, expected[2], actual; in cycles_with_mmcr2() local
49 expected[0] = MMCR2_EXPECTED_1; in cycles_with_mmcr2()
50 expected[1] = MMCR2_EXPECTED_2; in cycles_with_mmcr2()
58 mtspr(SPRN_MMCR2, expected[i % 2]); in cycles_with_mmcr2()
63 if (val != expected[i % 2]) { in cycles_with_mmcr2()
/Linux-v5.4/tools/testing/selftests/bpf/
Dtest_select_reuseport.c232 struct data_check expected = {}, result; in check_data() local
248 expected.len = MIN_TCPHDR_LEN; in check_data()
249 expected.ip_protocol = IPPROTO_TCP; in check_data()
251 expected.len = UDPHDR_LEN; in check_data()
252 expected.ip_protocol = IPPROTO_UDP; in check_data()
256 expected.eth_protocol = htons(ETH_P_IPV6); in check_data()
257 expected.bind_inany = !srv_sa.v6.sin6_addr.s6_addr32[3] && in check_data()
262 memcpy(&expected.skb_addrs[0], cli_sa.v6.sin6_addr.s6_addr32, in check_data()
264 memcpy(&expected.skb_addrs[4], &in6addr_loopback, in check_data()
266 expected.skb_ports[0] = cli_sa.v6.sin6_port; in check_data()
[all …]
Dtest_offload.py172 def bpftool_prog_list(expected=None, ns=""): argument
178 if expected is not None:
179 if len(progs) != expected:
181 (len(progs), expected))
184 def bpftool_map_list(expected=None, ns=""): argument
190 if expected is not None:
191 if len(maps) != expected:
193 (len(maps), expected))
196 def bpftool_prog_list_wait(expected=0, n_retry=20): argument
199 if nprogs == expected:
[all …]
/Linux-v5.4/tools/testing/selftests/ftrace/test.d/ftrace/
Dfunc_set_ftrace_file.tc122 DIFF=`diff $TMPDIR/actual $TMPDIR/expected`
127 cat available_filter_functions | cut -d' ' -f1 | grep 'lock' | sort -u > $TMPDIR/expected
132 grep -v 'try.*lock$' $TMPDIR/expected > $TMPDIR/expected2
133 mv $TMPDIR/expected2 $TMPDIR/expected
138 grep -v '^m.*lock$' $TMPDIR/expected > $TMPDIR/expected2
139 mv $TMPDIR/expected2 $TMPDIR/expected
144 grep -v '^c.*unlock' $TMPDIR/expected > $TMPDIR/expected2
145 mv $TMPDIR/expected2 $TMPDIR/expected
150 > $TMPDIR/expected
154 rm $TMPDIR/expected
/Linux-v5.4/tools/perf/tests/
Dhists_cumulate.c177 static int do_test(struct hists *hists, struct result *expected, size_t nr_expected, in do_test() argument
210 TEST_ASSERT_VAL(buf, he->stat.period == expected[i].self && in do_test()
211 !strcmp(COMM(he), expected[i].comm) && in do_test()
212 !strcmp(DSO(he), expected[i].dso) && in do_test()
213 !strcmp(SYM(he), expected[i].sym)); in do_test()
216 TEST_ASSERT_VAL(buf, he->stat_acc->period == expected[i].children); in do_test()
269 struct result expected[] = { in test1() local
292 err = do_test(hists, expected, ARRAY_SIZE(expected), NULL, 0); in test1()
367 struct result expected[] = { in test2() local
439 err = do_test(hists, expected, ARRAY_SIZE(expected), in test2()
[all …]
Dopenat-syscall-all-cpus.c101 unsigned int expected; in test__openat_syscall_event_on_all_cpus() local
112 expected = nr_openat_calls + cpu; in test__openat_syscall_event_on_all_cpus()
113 if (perf_counts(evsel->counts, cpu, 0)->val != expected) { in test__openat_syscall_event_on_all_cpus()
115 expected, cpus->map[cpu], perf_counts(evsel->counts, cpu, 0)->val); in test__openat_syscall_event_on_all_cpus()
/Linux-v5.4/lib/
Dtest_user_copy.c94 int expected = is_zeroed(kmem + start, len); in test_check_nonzero_user() local
96 ret |= test(retval != expected, in test_check_nonzero_user()
98 retval, expected, start, end); in test_check_nonzero_user()
109 char *umem_src = NULL, *expected = NULL; in test_copy_struct_from_user() local
117 expected = kmalloc(size, GFP_KERNEL); in test_copy_struct_from_user()
118 ret = test(expected == NULL, "kmalloc failed"); in test_copy_struct_from_user()
131 memcpy(expected, umem_src, ksize); in test_copy_struct_from_user()
136 ret |= test(memcmp(kmem, expected, ksize), in test_copy_struct_from_user()
143 memcpy(expected, umem_src, usize); in test_copy_struct_from_user()
144 memset(expected + usize, 0x0, ksize - usize); in test_copy_struct_from_user()
[all …]
Dpercpu_test.c5 #define CHECK(native, pcp, expected) \ argument
7 WARN((native) != (expected), \
10 (long long)(expected), (long long)(expected)); \
11 WARN(__this_cpu_read(pcp) != (expected), \
14 (long long)(expected), (long long)(expected)); \
Dglobtest.c16 bool expected; member
19 static bool __pure __init test(char const *pat, char const *str, bool expected) in test() argument
22 bool success = match == expected; in test()
144 bool expected = *p++ & 1; in glob_init() local
148 successes += test(pat, p, expected); in glob_init()
Dtest_strscpy.c29 static int __init tc(char *src, int count, int expected, in tc() argument
55 if (expected > max_expected) { in tc()
57 expected, max_expected); in tc()
61 if ((written) != (expected)) { in tc()
62 pr_err("%d != %d (written, expected)\n", written, expected); in tc()
/Linux-v5.4/tools/testing/selftests/networking/timestamping/
Drxtimestamp.c45 struct tstamps expected; member
140 if (t->expected.tstamp) in print_test_case()
142 if (t->expected.tstampns) in print_test_case()
144 if (t->expected.swtstamp || t->expected.hwtstamp) { in print_test_case()
146 if (t->expected.swtstamp) in print_test_case()
148 if (t->expected.swtstamp && t->expected.hwtstamp) in print_test_case()
150 if (t->expected.hwtstamp) in print_test_case()
170 bool do_recv(int rcv, int read_size, struct tstamps expected) in do_recv() argument
228 if (expected.field != actual.field) { \ in do_recv()
229 if (expected.field) \ in do_recv()
[all …]
/Linux-v5.4/arch/arc/include/asm/
Dcmpxchg.h17 __cmpxchg(volatile void *ptr, unsigned long expected, unsigned long new) in __cmpxchg() argument
35 "ir"(expected), in __cmpxchg()
47 __cmpxchg(volatile void *ptr, unsigned long expected, unsigned long new) in __cmpxchg() argument
58 if (prev == expected) in __cmpxchg()
67 __cmpxchg(volatile void *ptr, unsigned long expected, unsigned long new) in __cmpxchg() argument
74 write_aux_reg(CTOP_AUX_GPA1, expected); in __cmpxchg()
/Linux-v5.4/tools/testing/selftests/powerpc/vphn/
Dtest-vphn.c24 u32 expected[VPHN_ASSOC_BUFSIZE]; member
374 if (len != test->expected[0]) { in test_one()
375 printf("expected %d elements, got %d\n", test->expected[0], in test_one()
382 if (val != test->expected[i]) { in test_one()
384 test->expected[i]); in test_one()
/Linux-v5.4/arch/riscv/kernel/
Dftrace.c14 unsigned int *expected) in ftrace_check_current_call() argument
20 if (!expected) in ftrace_check_current_call()
21 expected = nops; in ftrace_check_current_call()
34 if (memcmp(expected, replaced, sizeof(replaced))) { in ftrace_check_current_call()
36 (void *)hook_pos, expected[0], expected[1], replaced[0], in ftrace_check_current_call()
/Linux-v5.4/include/linux/
Dbcm963xx_nvram.h84 u32 expected, actual; in bcm963xx_nvram_checksum() local
88 expected = nvram->checksum_v4; in bcm963xx_nvram_checksum()
91 expected = nvram->checksum_v5; in bcm963xx_nvram_checksum()
105 *expected_out = expected; in bcm963xx_nvram_checksum()
110 return expected == actual ? 0 : -EINVAL; in bcm963xx_nvram_checksum()
/Linux-v5.4/drivers/gpu/drm/i915/
Di915_cmd_parser.c165 u32 expected; member
226 .expected = 0,
233 .expected = 0,
256 .expected = 0,
263 .expected = 0,
269 .expected = 0,
275 .expected = 0,
283 .expected = 0,
292 .expected = 0,
298 .expected = 0,
[all …]
/Linux-v5.4/tools/testing/selftests/bpf/prog_tests/
Dflow_dissector.c12 #define CHECK_FLOW_KEYS(desc, got, expected) \ argument
13 CHECK_ATTR(memcmp(&got, &expected, sizeof(got)) != 0, \
26 got.nhoff, expected.nhoff, \
27 got.thoff, expected.thoff, \
28 got.addr_proto, expected.addr_proto, \
29 got.is_frag, expected.is_frag, \
30 got.is_first_frag, expected.is_first_frag, \
31 got.is_encap, expected.is_encap, \
32 got.ip_proto, expected.ip_proto, \
33 got.n_proto, expected.n_proto, \
[all …]
/Linux-v5.4/tools/testing/selftests/net/
Dfib_nexthops.sh39 local expected=$2
42 if [ ${rc} -eq ${expected} ]; then
50 echo " rc=$rc, expected $expected"
193 local expected="$2"
196 [ "${out}" = "${expected}" ] && return 0
202 printf " ${expected}\n"
208 if [ "${out}" != "${expected}" ]; then
214 printf " ${expected}\n\n"
226 local expected="$2"
231 check_output "${out}" "${expected}"
[all …]
/Linux-v5.4/arch/um/drivers/
Dnet_user.c52 int remain, ret, expected; in read_output() local
67 expected = sizeof(remain); in read_output()
73 expected = (remain < len) ? remain : len; in read_output()
74 ret = read(fd, output, expected); in read_output()
75 if (ret != expected) { in read_output()
92 "%d of %d bytes\n", str, ret, expected); in read_output()
/Linux-v5.4/tools/testing/selftests/powerpc/pmu/
Dcount_instructions.c32 s64 difference, expected; in do_count_loop() local
45 expected = instructions + overhead; in do_count_loop()
46 difference = events[0].result.value - expected; in do_count_loop()
54 printf("Expected %llu\n", expected); in do_count_loop()
/Linux-v5.4/tools/testing/selftests/powerpc/copyloops/
Dexc_validate.c62 unsigned long got, expected; in do_one_test() local
65 expected = test_copy_tofrom_user_reference(dstp, srcp, len); in do_one_test()
67 if (got != expected) { in do_one_test()
70 srcp, dstp, len, got, expected); in do_one_test()

12345678910>>...21