drm/panel-edp: Add STA 116QHD024002
[drm/drm-misc.git] / tools / testing / selftests / ftrace / test.d / kprobe / uprobe_syntax_errors.tc
blobc817158b99db6c1046f9ab9232645e5335a19641
1 #!/bin/sh
2 # SPDX-License-Identifier: GPL-2.0
3 # description: Uprobe event parser error log check
4 # requires: uprobe_events error_log
6 check_error() { # command-with-error-pos-by-^
7 ftrace_errlog_check 'trace_uprobe' "$1" 'uprobe_events'
10 check_error 'p ^/non_exist_file:100' # FILE_NOT_FOUND
11 check_error 'p ^/sys:100' # NO_REGULAR_FILE
12 check_error 'p /bin/sh:^10a' # BAD_UPROBE_OFFS
13 check_error 'p /bin/sh:10(^1a)' # BAD_REFCNT
14 check_error 'p /bin/sh:10(10^' # REFCNT_OPEN_BRACE
15 check_error 'p /bin/sh:10(10)^a' # BAD_REFCNT_SUFFIX
17 check_error 'p /bin/sh:10 ^@+ab' # BAD_FILE_OFFS
18 check_error 'p /bin/sh:10 ^@symbol' # SYM_ON_UPROBE
20 # %return suffix error
21 if grep -q "place (uprobe): .*%return.*" README; then
22 check_error 'p /bin/sh:10^%hoge' # BAD_ADDR_SUFFIX
23 check_error 'p /bin/sh:10(10)^%return' # BAD_REFCNT_SUFFIX
26 # symstr is not supported by uprobe
27 if grep -q ".*symstr.*" README; then
28 check_error 'p /bin/sh:10 $stack0:^symstr' # BAD_TYPE
31 exit 0