From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 81576 invoked by alias); 18 Apr 2018 07:26:54 -0000 Mailing-List: contact systemtap-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Post: List-Help: , Sender: systemtap-owner@sourceware.org Received: (qmail 81509 invoked by uid 48); 18 Apr 2018 07:26:50 -0000 From: "gmoreira at gmail dot com" To: systemtap@sourceware.org Subject: [Bug runtime/22847] ARM OABI syscall tracing issues Date: Wed, 18 Apr 2018 07:26:00 -0000 X-Bugzilla-Reason: AssignedTo X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: systemtap X-Bugzilla-Component: runtime X-Bugzilla-Version: unspecified X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: gmoreira at gmail dot com X-Bugzilla-Status: UNCONFIRMED X-Bugzilla-Resolution: X-Bugzilla-Priority: P2 X-Bugzilla-Assigned-To: systemtap at sourceware dot org X-Bugzilla-Target-Milestone: --- X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: Message-ID: In-Reply-To: References: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Bugzilla-URL: http://sourceware.org/bugzilla/ Auto-Submitted: auto-generated MIME-Version: 1.0 X-SW-Source: 2018-q2/txt/msg00018.txt.bz2 https://sourceware.org/bugzilla/show_bug.cgi?id=3D22847 --- Comment #18 from Gustavo Moreira --- I ended up modifying the kernel to update thread_info struct with the sysca= ll number. Then I just call the original kernel syscall_get_nr() function from SystemTap, which is working like a charm. # stap -v -g -p4 -m stap_abi_test -e probe kernel.function("sys_connect").c= all { printf("%s - 0x%x\n", ppfunc(), _stp_syscall_nr()) } # staprun -c ../ex_socket_OABI ./stap_abi_test.ko SyS_connect - 0x90011b Connected # staprun -c ../ex_socket_EABI ./stap_abi_test.ko SyS_connect - 0x11b Connected However, for instance, when it's used with your strace.stp which uses probe alias, it doesn't work ... it doesn't report the syscalls. Even using an EA= BI binary it doesn't report the syscalls. (See staprun_output_eabi.log and staprun_output_oabi.log) I also noticed that, for instance from tapset/linux/sysc_connect.stp, __syscall_gate() is called to filter the syscalls, so I've crafted some code (see syscalls_stpm.patch) to avoid to be filtered in case the syscall number doesn't match with the constants. I'm not getting what is happening from the SystemTap side, it seems the syscalls are being filtered somewhere ... could you please help me out? --=20 You are receiving this mail because: You are the assignee for the bug.