/linux/tools/perf/util/ |
H A D | string.c | 406 * Replace all occurrences of character 'needle' in string 'haystack' with 412 char *strreplace_chars(char needle, const char *haystack, const char *replace) 416 const char *loc = strchr(haystack, needle); 422 loc = strchr(loc + 1, needle); 430 loc = strchr(haystack, needle); 443 /* needle next occurrence or end of string */ 444 loc = strchr(from, needle); 312 strreplace_chars(char needle,const char * haystack,const char * replace) strreplace_chars() argument
|
H A D | string2.h | 44 char *strreplace_chars(char needle, const char *haystack, const char *replace);
|
H A D | parse-events.h | 274 const char *needle);
|
H A D | parse-events.c | 308 * @str: The needle to look for. in add_event_tool() 2318 * given needle string? in __parse_events_error__print() 2321 const char *needle) in __parse_events_error__print() 2326 if (strstr(pos->str, needle) != NULL) in __parse_events_error__print() 2347 parse_events_error__contains(const struct parse_events_error * err,const char * needle) parse_events_error__contains() argument
|
/linux/tools/testing/selftests/powerpc/papr_vpd/ |
H A D | papr_vpd.c | 62 static const char needle[] = "System VPD"; in dev_papr_vpd_get_handle_all() local 63 FAIL_IF(!memmem(buf, size, needle, strlen(needle))); in dev_papr_vpd_get_handle_all() 294 static const char needle[] = "System VPD"; in papr_vpd_system_loc_code() local 295 FAIL_IF(!memmem(buf, size, needle, strlen(needle))); in papr_vpd_system_loc_code()
|
/linux/tools/perf/tests/ |
H A D | util.c | 9 static int test_strreplace(char needle, const char *haystack, in test_strreplace() argument 12 char *new = strreplace_chars(needle, haystack, replace); in test_strreplace()
|
/linux/tools/testing/selftests/cgroup/ |
H A D | cgroup_util.h | 35 const char *needle); 61 extern int proc_read_strstr(int pid, bool thread, const char *item, const char *needle);
|
H A D | cgroup_util.c | 124 int cg_read_strstr(const char *cgroup, const char *control, const char *needle) in cg_read_strstr() argument 131 return strstr(buf, needle) ? 0 : -1; in cg_read_strstr() 596 int proc_read_strstr(int pid, bool thread, const char *item, const char *needle) in proc_read_strstr() argument 603 return strstr(buf, needle) ? 0 : -1; in proc_read_strstr()
|
/linux/tools/testing/selftests/powerpc/signal/ |
H A D | sigreturn_vdso.c | 26 static int search_proc_maps(char *needle, unsigned long *low, unsigned long *high) in search_proc_maps() argument 52 if (strstr(name, needle)) { in search_proc_maps()
|
/linux/tools/testing/selftests/powerpc/mm/ |
H A D | stack_expansion_ldst.c | 75 static int search_proc_maps(char *needle, unsigned long *low, unsigned long *high) in search_proc_maps() argument 101 if (strstr(name, needle)) { in search_proc_maps()
|
/linux/lib/ |
H A D | fortify_kunit.c | 921 char needle = 'm'; in __fortify_test() local 924 KUNIT_ASSERT_PTR_EQ(test, memscan(haystack, needle, len), in __fortify_test() 928 KUNIT_ASSERT_PTR_EQ(test, memscan(haystack, needle, len + 1), in __fortify_test() 931 KUNIT_ASSERT_PTR_EQ(test, memscan(haystack, needle, len * 2), in __fortify_test() 940 char needle = 'm'; in fortify_test_memchr() local 943 KUNIT_ASSERT_PTR_EQ(test, memchr(haystack, needle, len), in fortify_test_memchr() 947 KUNIT_ASSERT_PTR_EQ(test, memchr(haystack, needle, len + 1), in fortify_test_memchr() 950 KUNIT_ASSERT_PTR_EQ(test, memchr(haystack, needle, len * 2), in fortify_test_memchr() 959 char needle = 'W'; in fortify_test_memchr_inv() local 963 KUNIT_ASSERT_PTR_EQ(test, memchr_inv(haystack, needle, len), in fortify_test_memchr_inv() [all …]
|
/linux/tools/testing/selftests/net/ |
H A D | bpf_offload.py | 596 def check_no_extack(res, needle): argument 598 fail(haystack.count(needle) or haystack.count("Warning:"), 599 "Unexpected command output, leaky extack? ('%s', '%s')" % (needle, haystack)) 617 def test_spurios_extack(sim, obj, skip_hw, needle): 620 check_no_extack(res, needle) 623 check_no_extack(res, needle) 626 check_no_extack(res, needle) 616 test_spurios_extack(sim, obj, skip_hw, needle) global() argument
|
/linux/tools/testing/selftests/bpf/ |
H A D | test_verifier.c | 1307 char needle[200]; 1319 if (len >= sizeof(needle) || !len) { in cmp_str_seq() 1323 strncpy(needle, exp, len); in cmp_str_seq() 1324 needle[len] = 0; in cmp_str_seq() 1325 q = strstr(log, needle); in cmp_str_seq() 1328 "EXP: %s\nRES:\n", needle); in cmp_str_seq() 1311 char needle[200]; cmp_str_seq() local
|
/linux/drivers/scsi/ |
H A D | NCR5380.c | 2186 struct scsi_cmnd *needle) in list_find_cmd() argument 2191 if (NCR5380_to_scmd(ncmd) == needle) in list_find_cmd() 2203 struct scsi_cmnd *needle) in list_del_cmd() argument 2205 if (list_find_cmd(haystack, needle)) { in list_del_cmd() 2206 struct NCR5380_cmd *ncmd = NCR5380_to_ncmd(needle); in list_del_cmd()
|
H A D | hpsa.c | 1555 static int hpsa_scsi_find_entry(struct hpsa_scsi_dev_t *needle, in hpsa_scsi_find_entry() argument 1564 if (needle == NULL) in hpsa_scsi_find_entry() 1570 if (SCSI3ADDR_EQ(needle->scsi3addr, haystack[i]->scsi3addr)) { in hpsa_scsi_find_entry() 1572 if (device_is_the_same(needle, haystack[i])) { in hpsa_scsi_find_entry() 1573 if (device_updated(needle, haystack[i])) in hpsa_scsi_find_entry() 1578 if (needle->volume_offline) in hpsa_scsi_find_entry()
|
/linux/tools/testing/selftests/alsa/ |
H A D | mixer-test.c | 440 static bool strend(const char *haystack, const char *needle) in strend() argument 443 size_t needle_len = strlen(needle); in strend() 447 return strcmp(haystack + haystack_len - needle_len, needle) == 0; in strend()
|
/linux/sound/soc/codecs/ |
H A D | tas5086.c | 339 static int index_in_array(const int *array, int len, int needle) in index_in_array() argument 344 if (array[i] == needle) in index_in_array()
|
/linux/net/netfilter/ |
H A D | nf_conntrack_sip.c | 351 const char *needle, unsigned int len) in ct_sip_header_search() argument 361 if (strncasecmp(dptr, needle, len) == 0) in ct_sip_header_search() 712 const char *needle, unsigned int len) in ct_sdp_header_search() argument 717 if (strncmp(dptr, needle, len) == 0) in ct_sdp_header_search()
|
/linux/sound/soc/intel/avs/ |
H A D | topology.c | 377 char *needle = strstr(fmt, "%d"); in avs_ssp_sprint() local 385 if (needle) { in avs_ssp_sprint() 386 retsize = scnprintf(buf, min_t(size_t, size, needle - fmt + 1), "%s", fmt); in avs_ssp_sprint() 390 retsize += scnprintf(buf + retsize, size - retsize, "%s", needle + 2); in avs_ssp_sprint()
|
/linux/tools/testing/kunit/ |
H A D | kunit_tool_test.py | 92 def assertContains(self, needle: str, haystack: kunit_parser.LineStream): 96 if needle in line:
|
/linux/drivers/media/dvb-core/ |
H A D | dvb_ca_en50221.c | 207 static char *findstr(char *haystack, int hlen, char *needle, int nlen) in findstr() argument 215 if (!strncmp(haystack + i, needle, nlen)) in findstr()
|
/linux/tools/testing/selftests/net/forwarding/ |
H A D | bridge_mdb_max.sh | 328 local needle=$1; shift
|