Lines Matching refs:buf

24 	u8 *buf;  in setexpr_test_int()  local
26 buf = map_sysmem(0, BUF_SIZE); in setexpr_test_int()
27 memset(buf, '\xff', BUF_SIZE); in setexpr_test_int()
30 buf[0x0] = 0x12; in setexpr_test_int()
37 *(short *)buf = 0x2345; in setexpr_test_int()
44 *(u32 *)buf = 0x3456789a; in setexpr_test_int()
51 *(u64 *)buf = 0x456789abcdef0123; in setexpr_test_int()
63 unmap_sysmem(buf); in setexpr_test_int()
72 char *buf; in setexpr_test_plus() local
74 buf = map_sysmem(0, BUF_SIZE); in setexpr_test_plus()
75 memset(buf, '\xff', BUF_SIZE); in setexpr_test_plus()
78 buf[0x0] = 0x12; in setexpr_test_plus()
79 buf[0x10] = 0x34; in setexpr_test_plus()
84 *(short *)buf = 0x2345; in setexpr_test_plus()
85 *(short *)(buf + 0x10) = 0xf012; in setexpr_test_plus()
90 *(u32 *)buf = 0x3456789a; in setexpr_test_plus()
91 *(u32 *)(buf + 0x10) = 0xc3384235; in setexpr_test_plus()
96 *(u64 *)buf = 0x456789abcdef0123; in setexpr_test_plus()
97 *(u64 *)(buf + 0x10) = 0x4987328372849283; in setexpr_test_plus()
105 unmap_sysmem(buf); in setexpr_test_plus()
114 char *buf; in setexpr_test_oper() local
116 buf = map_sysmem(0, BUF_SIZE); in setexpr_test_oper()
117 memset(buf, '\xff', BUF_SIZE); in setexpr_test_oper()
119 *(u32 *)buf = 0x1234; in setexpr_test_oper()
120 *(u32 *)(buf + 0x10) = 0x560000; in setexpr_test_oper()
126 *(u32 *)buf = 0x561200; in setexpr_test_oper()
127 *(u32 *)(buf + 0x10) = 0x1234; in setexpr_test_oper()
148 unmap_sysmem(buf); in setexpr_test_oper()
157 char *buf, *val; in setexpr_test_regex() local
159 buf = map_sysmem(0, BUF_SIZE); in setexpr_test_regex()
182 unmap_sysmem(buf); in setexpr_test_regex()
191 char *buf, *val; in setexpr_test_regex_inc() local
193 buf = map_sysmem(0, BUF_SIZE); in setexpr_test_regex_inc()
199 unmap_sysmem(buf); in setexpr_test_regex_inc()
208 char *buf, *nbuf; in setexpr_test_sub() local
211 buf = map_sysmem(0, BUF_SIZE); in setexpr_test_sub()
215 memset(buf, '\xff', BUF_SIZE); in setexpr_test_sub()
218 buf[i] = i & 0xff; in setexpr_test_sub()
221 strcpy(buf, "this is a test"); in setexpr_test_sub()
227 ut_assertok(setexpr_regex_sub(buf, BUF_SIZE, nbuf, BUF_SIZE, "is", in setexpr_test_sub()
229 ut_asserteq_str("thus it is longer us it is longer a test", buf); in setexpr_test_sub()
231 ut_assertf(buf[i] == (char)i, in setexpr_test_sub()
233 i, i & 0xff, (u8)buf[i]); in setexpr_test_sub()
239 unmap_sysmem(buf); in setexpr_test_sub()
248 char *buf, *nbuf; in setexpr_test_backref() local
251 buf = map_sysmem(0, BUF_SIZE); in setexpr_test_backref()
255 memset(buf, '\xff', BUF_SIZE); in setexpr_test_backref()
258 buf[i] = i & 0xff; in setexpr_test_backref()
261 strcpy(buf, "this is surely a test is it? yes this is indeed a test"); in setexpr_test_backref()
267 ut_assertok(setexpr_regex_sub(buf, BUF_SIZE, nbuf, BUF_SIZE, in setexpr_test_backref()
271 buf); in setexpr_test_backref()
274 ut_assertf(buf[i] == (char)i, in setexpr_test_backref()
276 i, i & 0xff, (u8)buf[i]); in setexpr_test_backref()
282 unmap_sysmem(buf); in setexpr_test_backref()
292 char *buf; in setexpr_test_str() local
294 buf = map_sysmem(0, BUF_SIZE); in setexpr_test_str()
295 memset(buf, '\xff', BUF_SIZE); in setexpr_test_str()
303 strcpy(buf, "hello"); in setexpr_test_str()
317 unmap_sysmem(buf); in setexpr_test_str()
328 char *buf; in setexpr_test_str_oper() local
330 buf = map_sysmem(0, BUF_SIZE); in setexpr_test_str_oper()
331 memset(buf, '\xff', BUF_SIZE); in setexpr_test_str_oper()
332 strcpy(buf, "hello"); in setexpr_test_str_oper()
333 strcpy(buf + 0x10, " there"); in setexpr_test_str_oper()
367 unmap_sysmem(buf); in setexpr_test_str_oper()
377 char *buf, *val; in setexpr_test_str_long() local
379 buf = map_sysmem(0, size); in setexpr_test_str_long()
380 memset(buf, 'a', size); in setexpr_test_str_long()
387 unmap_sysmem(buf); in setexpr_test_str_long()
397 u8 *buf; in setexpr_test_fmt() local
399 buf = map_sysmem(0, BUF_SIZE); in setexpr_test_fmt()
400 memset(buf, '\xff', BUF_SIZE); in setexpr_test_fmt()
469 unmap_sysmem(buf); in setexpr_test_fmt()