From patchwork Thu Jun 28 03:46:41 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= X-Patchwork-Id: 935926 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=pass (mailfrom) smtp.mailfrom=nongnu.org (client-ip=2001:4830:134:3::11; helo=lists.gnu.org; envelope-from=qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org; receiver=) Authentication-Results: ozlabs.org; dmarc=none (p=none dis=none) header.from=amsat.org Authentication-Results: ozlabs.org; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=gmail.com header.i=@gmail.com header.b="nxZ8I3h1"; dkim-atps=neutral Received: from lists.gnu.org (lists.gnu.org [IPv6:2001:4830:134:3::11]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 41GQjG6xB8z9s31 for ; Thu, 28 Jun 2018 13:48:02 +1000 (AEST) Received: from localhost ([::1]:34392 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1fYNua-0007xF-KH for incoming@patchwork.ozlabs.org; Wed, 27 Jun 2018 23:48:00 -0400 Received: from eggs.gnu.org ([2001:4830:134:3::10]:46063) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1fYNto-0007uB-Qo for qemu-devel@nongnu.org; Wed, 27 Jun 2018 23:47:18 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1fYNth-0000Us-50 for qemu-devel@nongnu.org; Wed, 27 Jun 2018 23:47:12 -0400 Received: from mail-qk0-x236.google.com ([2607:f8b0:400d:c09::236]:45192) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1fYNth-0000UH-0E for qemu-devel@nongnu.org; Wed, 27 Jun 2018 23:47:05 -0400 Received: by mail-qk0-x236.google.com with SMTP id c198-v6so2255483qkg.12 for ; Wed, 27 Jun 2018 20:47:04 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=sender:from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=G2ahE2OAFPa8WL+ImNAi6EA+Wl0IRSrivFrhWJ7juV0=; b=nxZ8I3h1CoBVFe0q3kh7xlF00++SsJVxvhDpL7GDn0W2ZEumIKcG/75qG0KLiCcmXS gWvrWkNAjLpl1DH90vRmJsefjq+APPwwEMYfnEx5YF7JlGs0/9w3WPYDx16rRsfPnDcQ eHUuBaaaqNGJxC+rn6OokVHHfNblAi5nirNXWoL1bYsnQZwaEoiKiLB7IpoM14lY4bAt d4QHHpVQO+Pq+ScvuHwe/7n1RZj0xuUW/quuhAqnzIireY/JvCAdJ58fZVkWWRRh2l9D KPQLQbjhXO1GSCaaeOXv+FgNJ4yeRapq+vMS5ug8HNJBBMF2SoRSD0vmyAbA7xfUq5K2 AlcA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:from:to:cc:subject:date:message-id :in-reply-to:references:mime-version:content-transfer-encoding; bh=G2ahE2OAFPa8WL+ImNAi6EA+Wl0IRSrivFrhWJ7juV0=; b=Z0Qe9eAI+Dds2vuHmZK9EhKVx+DwGmP8lZkj2lCTcZ1anEDYFf0NhkeJ4xgz+ZPDwf Lre0t0CjsaNxu17+2/1AZiTSl00tzka7aODAxL0SaePHSnwpDfqg0qaWSsh4LKS7oGfL wOo+Lrw1GXqQB7c00HeXyKeSPx5lB9HPDVwWJNLB0HpwJ+u95a7hfmMbzACZdOCxBvwh uNt8bQEE36XM7zseB1c/2Yr4PAYh6ixnVFTZ/nDK/HgtWho/0lvi/WLKlgKvuA2x0EQv pBNRnyIctD2I3+yJQeIAH3xFB3kCiPhXjuHlDSpyH/WmqyuTXEMbBwhEWKcK71drmFOx +IOA== X-Gm-Message-State: APt69E1IfL5oPaCuOI0OLU30KHgCUDP/JrothhB7x3QWuc0tc4mloCud ePCn3gaSCfsuB9UzlLPnnCSMnI2F X-Google-Smtp-Source: AAOMgpfms8o+hX7CI36vsgQ8zOXXDRUsPRJnj7gjGEg2bNLZJVWgzp/gtdFhTgPE1e1wGuzYtArsNA== X-Received: by 2002:a37:8ac3:: with SMTP id m186-v6mr7709444qkd.6.1530157624443; Wed, 27 Jun 2018 20:47:04 -0700 (PDT) Received: from x1.local ([138.117.48.222]) by smtp.gmail.com with ESMTPSA id e11-v6sm4125854qkb.4.2018.06.27.20.47.01 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Wed, 27 Jun 2018 20:47:03 -0700 (PDT) From: =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= To: Laurent Vivier Date: Thu, 28 Jun 2018 00:46:41 -0300 Message-Id: <20180628034652.24152-2-f4bug@amsat.org> X-Mailer: git-send-email 2.18.0 In-Reply-To: <20180628034652.24152-1-f4bug@amsat.org> References: <20180628034652.24152-1-f4bug@amsat.org> MIME-Version: 1.0 X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 2607:f8b0:400d:c09::236 Subject: [Qemu-devel] [PATCH v2 01/12] linux-user/syscall: Verify recvfrom(addr) is user-writable X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: =?utf-8?q?Guido_G=C3=BCnther?= , Riku Voipio , =?utf-8?q?Philippe_Mathieu-Daud?= =?utf-8?b?w6k=?= , qemu-devel@nongnu.org Errors-To: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org Sender: "Qemu-devel" Signed-off-by: Philippe Mathieu-Daudé Tested-By: Guido Günther Reviewed-by: Laurent Vivier --- linux-user/syscall.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/linux-user/syscall.c b/linux-user/syscall.c index 2117fb13b4..ad40682cee 100644 --- a/linux-user/syscall.c +++ b/linux-user/syscall.c @@ -4154,6 +4154,11 @@ static abi_long do_recvfrom(int fd, abi_ulong msg, size_t len, int flags, ret = -TARGET_EINVAL; goto fail; } + if (!access_ok(VERIFY_WRITE, target_addr, addrlen)) { + ret = -TARGET_EFAULT; + goto fail; + } + addr = alloca(addrlen); ret = get_errno(safe_recvfrom(fd, host_msg, len, flags, addr, &addrlen)); From patchwork Thu Jun 28 03:46:44 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= X-Patchwork-Id: 935928 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=pass (mailfrom) smtp.mailfrom=nongnu.org (client-ip=2001:4830:134:3::11; helo=lists.gnu.org; envelope-from=qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org; receiver=) Authentication-Results: ozlabs.org; dmarc=none (p=none dis=none) header.from=amsat.org Authentication-Results: ozlabs.org; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=gmail.com header.i=@gmail.com header.b="uJi06C58"; dkim-atps=neutral Received: from lists.gnu.org (lists.gnu.org [IPv6:2001:4830:134:3::11]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 41GQm670nNz9ryk for ; Thu, 28 Jun 2018 13:50:30 +1000 (AEST) Received: from localhost ([::1]:34402 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1fYNwy-0001Zx-Io for incoming@patchwork.ozlabs.org; Wed, 27 Jun 2018 23:50:28 -0400 Received: from eggs.gnu.org ([2001:4830:134:3::10]:46105) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1fYNts-0007vW-Te for qemu-devel@nongnu.org; Wed, 27 Jun 2018 23:47:18 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1fYNtp-0000aO-Mt for qemu-devel@nongnu.org; Wed, 27 Jun 2018 23:47:16 -0400 Received: from mail-qk0-x22c.google.com ([2607:f8b0:400d:c09::22c]:34017) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1fYNtp-0000Zv-J4 for qemu-devel@nongnu.org; Wed, 27 Jun 2018 23:47:13 -0400 Received: by mail-qk0-x22c.google.com with SMTP id b66-v6so2266357qkj.1 for ; Wed, 27 Jun 2018 20:47:13 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=sender:from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=tyE75r3XrWyzP4Elfwo8jv2xfxtarRkeyMoGCJPuflc=; b=uJi06C58eOp9oETi7mftruoe7f0fAiHKWMcwpyqTpz6yTZEZLc4t8p1DZNwmCM8p3P Q50Nf+SNu+gCsoWza7I4Ajl1nFoj0EXtr4CKmM4dg7dq666cQoFwqwtE5I13i80vLhGl AZTOoZXbHYR5aH3I7AkXV0TXkG+XdURUh05dgfc+HUq+uiRgLs+TF/reYmRSxGRtEyrX wd3qnMdKrogQekZ6KcUXyywPDnoh+312PQE6jC+zOKAw83N+HUR1ond0DpnY4l3hZWB8 P8mWzbGO0YZkCwwBe2ZHdZKzXCrx++9Su9DNdPQlkK6/eK71nOL1rZmVX43qzExESPzK amLA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:from:to:cc:subject:date:message-id :in-reply-to:references:mime-version:content-transfer-encoding; bh=tyE75r3XrWyzP4Elfwo8jv2xfxtarRkeyMoGCJPuflc=; b=CtIKf+eGBWC+O4LA9Iqjs4rPK9dEEveVEY/r9eAL6CIaAP1F2xM6NCwt3jjHSqW/HE QbuqbqDRALfYprzIOLJkr+NXeYoIf5+AAv+FjPrao6URFzWkOWAUc7TBY6ffR3KjWIPw ekcuWfdrwD/ECRgn7j6Qm/EuJKA0QW2kINPdPlZT0k8lv5SD4swQearo+xUdaXR6lU6d TWrBYFdzZYeIWoTHShBw3P4D7hTXaMnc9ZlplVXj0kvmtC8c9Q3KNeHYxvy+Xq+3FwSO RldKjvYbQnJnYpWw1TXyIKa0DofuuTiWEO3XU5qJWpwscq8M9El5I4GAc7PViU7T3niI RWIA== X-Gm-Message-State: APt69E2hhn34Twc4QBN/BK5aBXw3fxQK2WQlVunbBsb12R7+y6puwUZ9 HKfw1h0Sb3uCA3etKhdj17Q= X-Google-Smtp-Source: AAOMgpevObAmJyoeV62ue3liGCR1f/00p71/qKtkUm710F6kq9O1/49bmMWqU+AaMXSmWtbDo0LT5w== X-Received: by 2002:a37:4d84:: with SMTP id a126-v6mr7646634qkb.181.1530157633024; Wed, 27 Jun 2018 20:47:13 -0700 (PDT) Received: from x1.local ([138.117.48.222]) by smtp.gmail.com with ESMTPSA id e11-v6sm4125854qkb.4.2018.06.27.20.47.10 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Wed, 27 Jun 2018 20:47:12 -0700 (PDT) From: =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= To: Laurent Vivier Date: Thu, 28 Jun 2018 00:46:44 -0300 Message-Id: <20180628034652.24152-5-f4bug@amsat.org> X-Mailer: git-send-email 2.18.0 In-Reply-To: <20180628034652.24152-1-f4bug@amsat.org> References: <20180628034652.24152-1-f4bug@amsat.org> MIME-Version: 1.0 X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 2607:f8b0:400d:c09::22c Subject: [Qemu-devel] [PATCH v2 04/12] linux-user/strace: Improve gettimeofday() and settimeofday() output X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: =?utf-8?q?Guido_G=C3=BCnther?= , Riku Voipio , =?utf-8?q?Philippe_Mathieu-Daud?= =?utf-8?b?w6k=?= , qemu-devel@nongnu.org Errors-To: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org Sender: "Qemu-devel" Signed-off-by: Philippe Mathieu-Daudé Tested-By: Guido Günther --- linux-user/strace.c | 13 +++++++++++++ linux-user/strace.list | 4 ++-- 2 files changed, 15 insertions(+), 2 deletions(-) diff --git a/linux-user/strace.c b/linux-user/strace.c index b43a21f48b..955fe80ef2 100644 --- a/linux-user/strace.c +++ b/linux-user/strace.c @@ -1499,6 +1499,19 @@ print_futimesat(const struct syscallname *name, } #endif +#if defined(TARGET_NR_gettimeofday) || defined(TARGET_NR_settimeofday) +static void +print_timeofday(const struct syscallname *name, + abi_long arg0, abi_long arg1, abi_long arg2, + abi_long arg3, abi_long arg4, abi_long arg5) +{ + print_syscall_prologue(name); + print_timeval(arg0, 0); + print_timezone(arg1, 1); + print_syscall_epilogue(name); +} +#endif + #ifdef TARGET_NR_link static void print_link(const struct syscallname *name, diff --git a/linux-user/strace.list b/linux-user/strace.list index afe4db07f3..9b477b7730 100644 --- a/linux-user/strace.list +++ b/linux-user/strace.list @@ -384,7 +384,7 @@ { TARGET_NR_gettid, "gettid" , "%s()", NULL, NULL }, #endif #ifdef TARGET_NR_gettimeofday -{ TARGET_NR_gettimeofday, "gettimeofday" , NULL, NULL, NULL }, +{ TARGET_NR_gettimeofday, "gettimeofday" , NULL, print_timeofday, NULL }, #endif #ifdef TARGET_NR_getuid { TARGET_NR_getuid, "getuid" , "%s()", NULL, NULL }, @@ -1345,7 +1345,7 @@ { TARGET_NR_set_tid_address, "set_tid_address" , NULL, NULL, NULL }, #endif #ifdef TARGET_NR_settimeofday -{ TARGET_NR_settimeofday, "settimeofday" , NULL, NULL, NULL }, +{ TARGET_NR_settimeofday, "settimeofday" , NULL, print_timeofday, NULL }, #endif #ifdef TARGET_NR_setuid { TARGET_NR_setuid, "setuid" , NULL, NULL, NULL }, From patchwork Thu Jun 28 03:46:45 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= X-Patchwork-Id: 935929 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=pass (mailfrom) smtp.mailfrom=nongnu.org (client-ip=2001:4830:134:3::11; helo=lists.gnu.org; envelope-from=qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org; receiver=) Authentication-Results: ozlabs.org; dmarc=none (p=none dis=none) header.from=amsat.org Authentication-Results: ozlabs.org; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=gmail.com header.i=@gmail.com header.b="nN/Ev3RJ"; dkim-atps=neutral Received: from lists.gnu.org (lists.gnu.org [IPv6:2001:4830:134:3::11]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 41GQm65VzZz9s29 for ; Thu, 28 Jun 2018 13:50:30 +1000 (AEST) Received: from localhost ([::1]:34403 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1fYNwy-0001bB-Cm for incoming@patchwork.ozlabs.org; Wed, 27 Jun 2018 23:50:28 -0400 Received: from eggs.gnu.org ([2001:4830:134:3::10]:46120) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1fYNtu-0007vX-0G for qemu-devel@nongnu.org; Wed, 27 Jun 2018 23:47:19 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1fYNts-0000c6-PR for qemu-devel@nongnu.org; Wed, 27 Jun 2018 23:47:18 -0400 Received: from mail-qk0-x233.google.com ([2607:f8b0:400d:c09::233]:38130) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1fYNts-0000bs-Kx for qemu-devel@nongnu.org; Wed, 27 Jun 2018 23:47:16 -0400 Received: by mail-qk0-x233.google.com with SMTP id y4-v6so2265320qka.5 for ; Wed, 27 Jun 2018 20:47:16 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=sender:from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=qGSs521iUDJabiWn1hSPPcjVfTLm30ue5JfpgxHLu14=; b=nN/Ev3RJ54JlVnAAQJrULxqRAKTMugdWt63thLVxxAdX4BdsObLABxrxGedpteP0Tn 5kSAMvRo4OIsChRwZKczi578CcyxG3UqUUxCk0zN1+Hv7up0Y2MvlpIRGXDwuWTOBGPO cKXMGXMPrBo7/1BYyuUxUTYZGdQcVDo8Ct9QcxtrYDc8/w0Z/NMyt/fR0LJ1ojcZLmQ/ 02NpL5inoI6NzKIYt/wQ2Lx/dTywx9rjj7QOcxi5SZHGlVp1aGiEPseN+ceBUJ2t5Pv7 ElqqAH6+JPtICMj04WhHrUVvp+RIjrizPJ8By2+Q3onmUf+YXi3Bmx2EIXNRsh0CZVZ6 Ai5Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:from:to:cc:subject:date:message-id :in-reply-to:references:mime-version:content-transfer-encoding; bh=qGSs521iUDJabiWn1hSPPcjVfTLm30ue5JfpgxHLu14=; b=t6XniO3UMdSggwQhDkGouJHaMqqC0zpXjuWkd7Up8kUd2AO4pDJKfUEvRaYo/KsDS5 xsq4H/GiED5RyXqy5OJW9Tgdy8A/gbfh1TgrJAPEMkr4vsidH7OwmnDNOx/CHkFobDg+ xxM1yFMpfFaq+a6mFEt+h3zs1PciK9QGrUGtlgbCR5VFVcxaySMSXzcGf/68cP1Aa5YD U3Lj7yvjt3JcAsiEm9VHjiPf3+IyaPSmAl2Tn+ni47aj5xvFGmTnTmGnx9gF/81Xxjxa ZY+bsliupnYAGaKvyrdUrGUMW6y6di8LXRxsQBkFtWpCSCpmU2rsKReqUp2s9mb+e3b1 HSiA== X-Gm-Message-State: APt69E2MjhYVfJXSkN42nruW20IFO0b1+BH3z4h8hPNeRxs3iv87aI2Y tQmlHxNZU5GhQ1i5ZS5MA+gnOYcR X-Google-Smtp-Source: AAOMgpdyNeGkHI+1CrTVgFt3qtx98yECX0L1AvBt4swTK49hjVBkCOMih67c95uveNYj5dHM4xO8Jw== X-Received: by 2002:a37:e112:: with SMTP id c18-v6mr6401243qkm.65.1530157636066; Wed, 27 Jun 2018 20:47:16 -0700 (PDT) Received: from x1.local ([138.117.48.222]) by smtp.gmail.com with ESMTPSA id e11-v6sm4125854qkb.4.2018.06.27.20.47.13 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Wed, 27 Jun 2018 20:47:15 -0700 (PDT) From: =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= To: Laurent Vivier Date: Thu, 28 Jun 2018 00:46:45 -0300 Message-Id: <20180628034652.24152-6-f4bug@amsat.org> X-Mailer: git-send-email 2.18.0 In-Reply-To: <20180628034652.24152-1-f4bug@amsat.org> References: <20180628034652.24152-1-f4bug@amsat.org> MIME-Version: 1.0 X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 2607:f8b0:400d:c09::233 Subject: [Qemu-devel] [PATCH v2 05/12] linux-user/strace: Dump AF_NETLINK sockaddr content X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: =?utf-8?q?Guido_G=C3=BCnther?= , Riku Voipio , =?utf-8?q?Philippe_Mathieu-Daud?= =?utf-8?b?w6k=?= , qemu-devel@nongnu.org Errors-To: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org Sender: "Qemu-devel" Signed-off-by: Philippe Mathieu-Daudé Tested-By: Guido Günther --- linux-user/syscall_defs.h | 7 +++++++ linux-user/strace.c | 34 ++++++++++++++++++++++++++++++++++ linux-user/syscall.c | 6 ++++-- 3 files changed, 45 insertions(+), 2 deletions(-) diff --git a/linux-user/syscall_defs.h b/linux-user/syscall_defs.h index 40bb60ef4c..5a0b76721f 100644 --- a/linux-user/syscall_defs.h +++ b/linux-user/syscall_defs.h @@ -152,6 +152,13 @@ struct target_sockaddr_un { uint8_t sun_path[108]; }; +struct target_sockaddr_nl { + uint16_t nl_family; /* AF_NETLINK */ + uint16_t __pad; + uint32_t nl_pid; + uint32_t nl_groups; +}; + struct target_in_addr { uint32_t s_addr; /* big endian */ }; diff --git a/linux-user/strace.c b/linux-user/strace.c index 955fe80ef2..9e432f4ecb 100644 --- a/linux-user/strace.c +++ b/linux-user/strace.c @@ -8,6 +8,7 @@ #include #include #include +#include #include #include "qemu.h" @@ -398,6 +399,12 @@ print_sockaddr(abi_ulong addr, abi_long addrlen) gemu_log("}"); break; } + case AF_NETLINK: { + struct target_sockaddr_nl *nl = (struct target_sockaddr_nl *)sa; + gemu_log("{nl_family=AF_NETLINK,nl_pid=%u,nl_groups=%u}", + nl->nl_pid, nl->nl_groups); + break; + } default: gemu_log("{sa_family=%d, sa_data={", sa->sa_family); for (i = 0; i < 13; i++) { @@ -424,6 +431,9 @@ print_socket_domain(int domain) case PF_INET: gemu_log("PF_INET"); break; + case PF_NETLINK: + gemu_log("PF_NETLINK"); + break; case PF_PACKET: gemu_log("PF_PACKET"); break; @@ -473,6 +483,30 @@ print_socket_protocol(int domain, int type, int protocol) return; } + if (domain == AF_NETLINK) { + switch (protocol) { + case NETLINK_ROUTE: + gemu_log("NETLINK_ROUTE"); + break; + case NETLINK_AUDIT: + gemu_log("NETLINK_AUDIT"); + break; + case NETLINK_NETFILTER: + gemu_log("NETLINK_NETFILTER"); + break; + case NETLINK_RDMA: + gemu_log("NETLINK_RDMA"); + break; + case NETLINK_CRYPTO: + gemu_log("NETLINK_CRYPTO"); + break; + default: + gemu_log("%d", protocol); + break; + } + return; + } + switch (protocol) { case IPPROTO_IP: gemu_log("IPPROTO_IP"); diff --git a/linux-user/syscall.c b/linux-user/syscall.c index ad40682cee..9a11f8c4a6 100644 --- a/linux-user/syscall.c +++ b/linux-user/syscall.c @@ -1696,8 +1696,10 @@ static inline abi_long host_to_target_sockaddr(abi_ulong target_addr, sizeof(target_saddr->sa_family)) { target_saddr->sa_family = tswap16(addr->sa_family); } - if (addr->sa_family == AF_NETLINK && len >= sizeof(struct sockaddr_nl)) { - struct sockaddr_nl *target_nl = (struct sockaddr_nl *)target_saddr; + if (addr->sa_family == AF_NETLINK && + len >= sizeof(struct target_sockaddr_nl)) { + struct target_sockaddr_nl *target_nl = + (struct target_sockaddr_nl *)target_saddr; target_nl->nl_pid = tswap32(target_nl->nl_pid); target_nl->nl_groups = tswap32(target_nl->nl_groups); } else if (addr->sa_family == AF_PACKET) { From patchwork Thu Jun 28 03:46:46 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= X-Patchwork-Id: 935930 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=pass (mailfrom) smtp.mailfrom=nongnu.org (client-ip=2001:4830:134:3::11; helo=lists.gnu.org; envelope-from=qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org; receiver=) Authentication-Results: ozlabs.org; dmarc=none (p=none dis=none) header.from=amsat.org Authentication-Results: ozlabs.org; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=gmail.com header.i=@gmail.com header.b="n4fv6NMZ"; dkim-atps=neutral Received: from lists.gnu.org (lists.gnu.org [IPv6:2001:4830:134:3::11]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 41GQpZ4dlnz9ryk for ; Thu, 28 Jun 2018 13:52:37 +1000 (AEST) Received: from localhost ([::1]:34416 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1fYNz1-0003Nu-Ch for incoming@patchwork.ozlabs.org; Wed, 27 Jun 2018 23:52:35 -0400 Received: from eggs.gnu.org ([2001:4830:134:3::10]:46138) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1fYNtw-0007xg-5b for qemu-devel@nongnu.org; Wed, 27 Jun 2018 23:47:21 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1fYNtv-0000dN-D5 for qemu-devel@nongnu.org; Wed, 27 Jun 2018 23:47:20 -0400 Received: from mail-qk0-x234.google.com ([2607:f8b0:400d:c09::234]:45191) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1fYNtv-0000d5-7s for qemu-devel@nongnu.org; Wed, 27 Jun 2018 23:47:19 -0400 Received: by mail-qk0-x234.google.com with SMTP id c198-v6so2255654qkg.12 for ; Wed, 27 Jun 2018 20:47:19 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=sender:from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=lSNPo96PPUHqZ9X94o3IqqvPZB4bP0wXqCGr6QM4u9o=; b=n4fv6NMZ1mzH2TTZHENTBWWYuFDsi+tsKJqLB4R/oR7taVuKWOUtzkK+g+ph3qcXkZ foKvEGBLJ7VJSc5HaLxXc43uJEoWgxF1vGBudISPvkG7uKtiONEy0H8ccVLxNg4KkNUv zylyVOLeL9fzGMDSqc3uh0mjNU/f5xVrRoBLzzttQgXZrpOA6vZsezbJnE/1Z+Myj7QU KHuIF2vvVvdsDMmluGdU5LUHWioFUXFDzCMbt0DYuQaHHR58fR7F2759mRjPm6FwI0RC 7pvRu8TcxophxI7xzBI30YDE02l3Q31wDXCxTjkB39xx8UyoQm1wiKaye1aSi2w8u4Z1 4EkQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:from:to:cc:subject:date:message-id :in-reply-to:references:mime-version:content-transfer-encoding; bh=lSNPo96PPUHqZ9X94o3IqqvPZB4bP0wXqCGr6QM4u9o=; b=gEjQmsnW4IsS5fBgtHkUAmyxGsQnfX3z7lb8AdCoMuh56yqeiL4yM7SDTMZZwtb3h0 w9X78BMcyG584A8Encp04/o8rP8yqebualIexH6MzIK3xQpacIkFyIRKgqmweD4HF4lu PvFIvosqgflIxhfY2L9hjmKcdTkr1mNQp6vdic3RUbjtTmC2OwDrSDxrmKbTfUGlvPzO S4oZBNz3vk7WIkHCzUILRVr9Nb0qaF92cSsr4wwVG73C+dQN/UVUl4ffBR97XfSGaSfZ 8GNL1KrBxWXb+2rKxUhlbeJz2s2VOYiZ1M+54BFgW3yuUv0shfaqRSovxP8qKzRG3xAn PcXQ== X-Gm-Message-State: APt69E0RRaTYlvKJoMk+738QVKgeb6n7OkY464PtQlWOGWZO6smst689 8bRHi8VUy/2ltr45vWumQEY= X-Google-Smtp-Source: AAOMgpdHD9t+lePTxQ3RBsRho3XjeNlvOf+HZkUmFq19XcjiZ+C0MpMFIDP+HD92MU2XuIrgGe5y1Q== X-Received: by 2002:a37:849:: with SMTP id 70-v6mr7502585qki.200.1530157638672; Wed, 27 Jun 2018 20:47:18 -0700 (PDT) Received: from x1.local ([138.117.48.222]) by smtp.gmail.com with ESMTPSA id e11-v6sm4125854qkb.4.2018.06.27.20.47.16 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Wed, 27 Jun 2018 20:47:18 -0700 (PDT) From: =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= To: Laurent Vivier Date: Thu, 28 Jun 2018 00:46:46 -0300 Message-Id: <20180628034652.24152-7-f4bug@amsat.org> X-Mailer: git-send-email 2.18.0 In-Reply-To: <20180628034652.24152-1-f4bug@amsat.org> References: <20180628034652.24152-1-f4bug@amsat.org> MIME-Version: 1.0 X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 2607:f8b0:400d:c09::234 Subject: [Qemu-devel] [PATCH v2 06/12] linux-user/strace: Improve recvmsg() output X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: =?utf-8?q?Guido_G=C3=BCnther?= , Riku Voipio , =?utf-8?q?Philippe_Mathieu-Daud?= =?utf-8?b?w6k=?= , qemu-devel@nongnu.org Errors-To: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org Sender: "Qemu-devel" Signed-off-by: Philippe Mathieu-Daudé Tested-By: Guido Günther Reviewed-by: Laurent Vivier --- linux-user/strace.list | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/linux-user/strace.list b/linux-user/strace.list index 9b477b7730..70e89d423c 100644 --- a/linux-user/strace.list +++ b/linux-user/strace.list @@ -1107,7 +1107,7 @@ { TARGET_NR_recvmmsg, "recvmmsg" , NULL, NULL, NULL }, #endif #ifdef TARGET_NR_recvmsg -{ TARGET_NR_recvmsg, "recvmsg" , NULL, NULL, NULL }, +{ TARGET_NR_recvmsg, "recvmsg" , "%s(%d,%p,%#x)", NULL, NULL }, #endif #ifdef TARGET_NR_remap_file_pages { TARGET_NR_remap_file_pages, "remap_file_pages" , NULL, NULL, NULL }, From patchwork Thu Jun 28 03:46:49 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= X-Patchwork-Id: 935932 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=pass (mailfrom) smtp.mailfrom=nongnu.org (client-ip=2001:4830:134:3::11; helo=lists.gnu.org; envelope-from=qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org; receiver=) Authentication-Results: ozlabs.org; dmarc=none (p=none dis=none) header.from=amsat.org Authentication-Results: ozlabs.org; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=gmail.com header.i=@gmail.com header.b="rciwEkC0"; dkim-atps=neutral Received: from lists.gnu.org (lists.gnu.org [IPv6:2001:4830:134:3::11]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 41GQrK1hVbz9ryk for ; Thu, 28 Jun 2018 13:54:09 +1000 (AEST) Received: from localhost ([::1]:34421 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1fYO0V-0004VX-0m for incoming@patchwork.ozlabs.org; Wed, 27 Jun 2018 23:54:07 -0400 Received: from eggs.gnu.org ([2001:4830:134:3::10]:46179) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1fYNu4-00085n-BM for qemu-devel@nongnu.org; Wed, 27 Jun 2018 23:47:29 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1fYNu3-0000kM-D5 for qemu-devel@nongnu.org; Wed, 27 Jun 2018 23:47:28 -0400 Received: from mail-qk0-x243.google.com ([2607:f8b0:400d:c09::243]:46856) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1fYNu3-0000k3-8V for qemu-devel@nongnu.org; Wed, 27 Jun 2018 23:47:27 -0400 Received: by mail-qk0-x243.google.com with SMTP id o2-v6so2253110qkc.13 for ; Wed, 27 Jun 2018 20:47:27 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=sender:from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=XIMd4vsh94uR8+dOkxf8GtkUop0AdNO4yhUuJ9PO/wc=; b=rciwEkC0Ox+WNPH2tBkS25FJTvy3kXF8wt4Ruq6/WZ1L97G0OuWiv8kXPP5YTr0kKA bh1CcuOx69DdPCSi0Xtw2+N7dav9lwS3bAJG0h5RK9YvEACMS4iMDf2IqhCTIH1I7CMR ciNQD85R6jHr2qLgQiMaoOwwGcDb8AeRAbBPmpGgrBHkSYUpHt8YxQErGU9JRXsdopiZ k9pbLa+K/VDO2K4Wg1Ywl/rXnOvEFsJJgtoat2SzDLAmXlCniOpE5l9a0cw7Sk2P7x3h nwtAmhwEJWaThI/psRtLDkza3HuRR8KaECmENhEQOy5PEvsUofd1muVAkQmZyjHsW4yx Yy9w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:from:to:cc:subject:date:message-id :in-reply-to:references:mime-version:content-transfer-encoding; bh=XIMd4vsh94uR8+dOkxf8GtkUop0AdNO4yhUuJ9PO/wc=; b=jhE7g32HKgkNiuItTJezpWAsQ3Zx7/qBsTwy90TWoQbBI667KzhV2ZRo4pJ9ZUx8Bt 7eykmhd0jEeh7X9f4eM46XH0cH8aaCqYKHA8mhJZalkpwl+f35CLMVuzXGQV+mSe2xPl 9DzxDjxswj+OeExcdfsSmWSaOkUye5BCSNKv1bFGoXomvR85xH0MIKYRDffkQFlphyjQ Y/cFfziMn7cSmorFyxc1ywMLGYuy4v6Umo9Zd6L1+0+I5wPx73YXPxZRjd/+L9l9bN8w UagYvWf0rRayxlFSNWxVa1ZAuOqhgRxUGHJa8tHn+Dp1/XTaSZbN/SEJXtv0dKZUxciR fDFg== X-Gm-Message-State: APt69E3fBIfw+zOOsDUKu8qpbdbNVsNk0sLEXqhuNcCXwIzapO9GgxSg Rcjnl6A3VVyfVaT5zRBxuN0= X-Google-Smtp-Source: AAOMgpebxu5mJy4hvFIAEi2w/p0S7I7sltVK3+3AZK+mNq2UA1XSu62JkdfrHLqOsPOu0/p9ShMsBw== X-Received: by 2002:a37:d401:: with SMTP id l1-v6mr7249758qki.221.1530157646677; Wed, 27 Jun 2018 20:47:26 -0700 (PDT) Received: from x1.local ([138.117.48.222]) by smtp.gmail.com with ESMTPSA id e11-v6sm4125854qkb.4.2018.06.27.20.47.24 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Wed, 27 Jun 2018 20:47:26 -0700 (PDT) From: =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= To: Laurent Vivier Date: Thu, 28 Jun 2018 00:46:49 -0300 Message-Id: <20180628034652.24152-10-f4bug@amsat.org> X-Mailer: git-send-email 2.18.0 In-Reply-To: <20180628034652.24152-1-f4bug@amsat.org> References: <20180628034652.24152-1-f4bug@amsat.org> MIME-Version: 1.0 X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 2607:f8b0:400d:c09::243 Subject: [Qemu-devel] [PATCH v2 09/12] linux-user/strace: Let print_sockaddr() have a 'last' argument X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: =?utf-8?q?Guido_G=C3=BCnther?= , Riku Voipio , =?utf-8?q?Philippe_Mathieu-Daud?= =?utf-8?b?w6k=?= , qemu-devel@nongnu.org Errors-To: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org Sender: "Qemu-devel" If the format is not the syscall last argument, a comma is append. Signed-off-by: Philippe Mathieu-Daudé --- linux-user/strace.c | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/linux-user/strace.c b/linux-user/strace.c index 3690754be6..1bacf75213 100644 --- a/linux-user/strace.c +++ b/linux-user/strace.c @@ -67,7 +67,7 @@ UNUSED static void print_timeval(abi_ulong, int); UNUSED static void print_timezone(abi_ulong, int); UNUSED static void print_number(abi_long, int); UNUSED static void print_signal(abi_ulong, int); -UNUSED static void print_sockaddr(abi_ulong addr, abi_long addrlen); +UNUSED static void print_sockaddr(abi_ulong addr, abi_long addrlen, int); UNUSED static void print_socket_domain(int domain); UNUSED static void print_socket_type(int type); UNUSED static void print_socket_protocol(int domain, int type, int protocol); @@ -336,7 +336,7 @@ static void print_siginfo(const target_siginfo_t *tinfo) } static void -print_sockaddr(abi_ulong addr, abi_long addrlen) +print_sockaddr(abi_ulong addr, abi_long addrlen, int last) { struct target_sockaddr *sa; int i; @@ -418,7 +418,7 @@ print_sockaddr(abi_ulong addr, abi_long addrlen) } else { print_raw_param("0x"TARGET_ABI_FMT_lx, addr, 0); } - gemu_log(", "TARGET_ABI_FMT_ld, addrlen); + gemu_log(", "TARGET_ABI_FMT_ld"%s", addrlen, get_comma(last)); } static void @@ -1655,7 +1655,7 @@ static void do_print_sockaddr(const char *name, abi_long arg1) gemu_log("%s(", name); print_raw_param(TARGET_ABI_FMT_ld, sockfd, 0); - print_sockaddr(addr, addrlen); + print_sockaddr(addr, addrlen, 0); gemu_log(")"); } @@ -1725,7 +1725,7 @@ static void do_print_msgaddr(const char *name, abi_long arg1) print_buf(msg, len, 0); print_raw_param(TARGET_ABI_FMT_ld, len, 0); print_flags(msg_flags, flags, 0); - print_sockaddr(addr, addrlen); + print_sockaddr(addr, addrlen, 0); gemu_log(")"); } @@ -1963,7 +1963,7 @@ print_bind(const struct syscallname *name, { print_syscall_prologue(name); print_raw_param("%d", arg0, 0); - print_sockaddr(arg1, arg2); + print_sockaddr(arg1, arg2, 1); print_syscall_epilogue(name); } #endif @@ -1979,7 +1979,7 @@ print_sendto(const struct syscallname *name, print_buf(arg1, arg2, 0); print_raw_param(TARGET_ABI_FMT_ld, arg2, 0); print_flags(msg_flags, arg3, 0); - print_sockaddr(arg4, arg5); + print_sockaddr(arg4, arg5, 1); print_syscall_epilogue(name); } #endif From patchwork Thu Jun 28 03:46:50 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= X-Patchwork-Id: 935933 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=pass (mailfrom) smtp.mailfrom=nongnu.org (client-ip=2001:4830:134:3::11; helo=lists.gnu.org; envelope-from=qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org; receiver=) Authentication-Results: ozlabs.org; dmarc=none (p=none dis=none) header.from=amsat.org Authentication-Results: ozlabs.org; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=gmail.com header.i=@gmail.com header.b="UgXTicAz"; dkim-atps=neutral Received: from lists.gnu.org (lists.gnu.org [IPv6:2001:4830:134:3::11]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 41GQtT42zGz9ryk for ; Thu, 28 Jun 2018 13:56:01 +1000 (AEST) Received: from localhost ([::1]:34434 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1fYO2J-0005qJ-7K for incoming@patchwork.ozlabs.org; Wed, 27 Jun 2018 23:55:59 -0400 Received: from eggs.gnu.org ([2001:4830:134:3::10]:46196) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1fYNu6-00088F-Tn for qemu-devel@nongnu.org; Wed, 27 Jun 2018 23:47:31 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1fYNu6-0000ms-0e for qemu-devel@nongnu.org; Wed, 27 Jun 2018 23:47:30 -0400 Received: from mail-qk0-x243.google.com ([2607:f8b0:400d:c09::243]:41212) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1fYNu5-0000mf-S8 for qemu-devel@nongnu.org; Wed, 27 Jun 2018 23:47:29 -0400 Received: by mail-qk0-x243.google.com with SMTP id d22-v6so2263687qkc.8 for ; Wed, 27 Jun 2018 20:47:29 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=sender:from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=TNZO2Ef3/+Llso7HTqAtprY083qxZdyeGQ5oQCsuw6U=; b=UgXTicAzZECdYVZtTwSlgXsIcpoh40Eu8L/7HHKYx3GMbm7hSLUFn5LH4P1wY7Tseg WNXHVxcIEiOTMMgoZccUf+fBhD1gcqkWTGxCOgE+zc/Cc4MGFa1cTUDXbL0EzF4O0MOh Ap58D4VJ6goPwsdXFWEXI+2Lbv8j1ckIzMiTN8vMvy5HXzzUX7bg896/b48ZkR+AGbzg +xoiTtjEvTwOa3cDLHKWO+ppKcCcaEFNX0miiQgcmFTUB3p4Vc5f0fpH9CMVrDyPS23M TPTEXWt39Ed4SuEVEtW3erYHHHcAsDOLVR2Wh6Vo+63BxQpjEGpgzsW+M3hozh0YhQHR i7RQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:from:to:cc:subject:date:message-id :in-reply-to:references:mime-version:content-transfer-encoding; bh=TNZO2Ef3/+Llso7HTqAtprY083qxZdyeGQ5oQCsuw6U=; b=JyHXUt7f9Gmr+F+cmpdsTerKVL1o2UeNpOoxUd/aePoEBrgrViRZ9KdbhVZ4hK01TX X92AiXPNMQdyk3Idl5MME3oQj1C7BZJzCuGsVQWGBqmhdCbdWjGQwV722L/uTnP2Uam+ O7eQX87f7D/Jjb/voMzLUY8GqM+QbjcOVb9UEXYXP1Ef+4XoIo9MyEww+UuPiP7fbMyu 34gqXWUsIWTDIcM3zuoJJLlTIbWc4LBsiceCWOHf0hhGrqqjRBecwF88NIJ0htLZauWA M35GmWMIS9NsTqSUwPNQIaOKl/bFxbnR3WUEYw+ogvNRFo53GQjT5inuWZ9ea5HNgHJC d2PQ== X-Gm-Message-State: APt69E05gK5rCyq369DtxXdwI1XHqSJgweSi5K3wCRuIPpQHO2N5Zo2C S3JVcbXNoP2VtsNyMdfhFdI= X-Google-Smtp-Source: AAOMgpf2Z/iyBl1xQYXql+pIDhqEg+qttG4Q/Z/clcMt0BLIGuBq0tUn/hsHnrunEn+ga203jIXd/w== X-Received: by 2002:a37:40d3:: with SMTP id n202-v6mr7783399qka.365.1530157649381; Wed, 27 Jun 2018 20:47:29 -0700 (PDT) Received: from x1.local ([138.117.48.222]) by smtp.gmail.com with ESMTPSA id e11-v6sm4125854qkb.4.2018.06.27.20.47.26 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Wed, 27 Jun 2018 20:47:28 -0700 (PDT) From: =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= To: Laurent Vivier Date: Thu, 28 Jun 2018 00:46:50 -0300 Message-Id: <20180628034652.24152-11-f4bug@amsat.org> X-Mailer: git-send-email 2.18.0 In-Reply-To: <20180628034652.24152-1-f4bug@amsat.org> References: <20180628034652.24152-1-f4bug@amsat.org> MIME-Version: 1.0 X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 2607:f8b0:400d:c09::243 Subject: [Qemu-devel] [RFC PATCH v2 10/12] linux-user/strace: Add print_sockaddr_ptr() to handle plain/pointer addrlen X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: =?utf-8?q?Guido_G=C3=BCnther?= , Riku Voipio , =?utf-8?q?Philippe_Mathieu-Daud?= =?utf-8?b?w6k=?= , qemu-devel@nongnu.org Errors-To: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org Sender: "Qemu-devel" While very similar to send()/recv(), the format used by sendto()/recvfrom() is slightly different: the 'addrlen' is not a plain sockaddr_t but a pointer to it. Split the current function to handle both formats. Signed-off-by: Philippe Mathieu-Daudé Tested-By: Guido Günther --- linux-user/strace.c | 28 ++++++++++++++++++++++++++-- 1 file changed, 26 insertions(+), 2 deletions(-) diff --git a/linux-user/strace.c b/linux-user/strace.c index 1bacf75213..5a52d98f3b 100644 --- a/linux-user/strace.c +++ b/linux-user/strace.c @@ -68,6 +68,7 @@ UNUSED static void print_timezone(abi_ulong, int); UNUSED static void print_number(abi_long, int); UNUSED static void print_signal(abi_ulong, int); UNUSED static void print_sockaddr(abi_ulong addr, abi_long addrlen, int); +UNUSED static void print_sockaddr_ptr(abi_ulong addr, abi_long addrlen_ptr, int); UNUSED static void print_socket_domain(int domain); UNUSED static void print_socket_type(int type); UNUSED static void print_socket_protocol(int domain, int type, int protocol); @@ -336,7 +337,8 @@ static void print_siginfo(const target_siginfo_t *tinfo) } static void -print_sockaddr(abi_ulong addr, abi_long addrlen, int last) +print_sockaddr_ex(abi_ulong addr, abi_long addrlen, + bool addrlen_is_ptr, int last) { struct target_sockaddr *sa; int i; @@ -418,7 +420,29 @@ print_sockaddr(abi_ulong addr, abi_long addrlen, int last) } else { print_raw_param("0x"TARGET_ABI_FMT_lx, addr, 0); } - gemu_log(", "TARGET_ABI_FMT_ld"%s", addrlen, get_comma(last)); + gemu_log(", %s"TARGET_ABI_FMT_ld"%s%s", + (addrlen_is_ptr ? "[" : ""), addrlen, + (addrlen_is_ptr ? "]" : ""), get_comma(last)); +} + +static void +print_sockaddr(abi_ulong addr, abi_long addrlen, int last) +{ + print_sockaddr_ex(addr, addrlen, false, last); +} + +static void +print_sockaddr_ptr(abi_ulong addr, abi_long addrlen_ptr, int last) +{ + abi_ulong addrlen; + + if (!addr) { + print_sockaddr_ex(0, 0, false, last); + return; + } + + get_user_ual(addrlen, addrlen_ptr); + print_sockaddr_ex(addr, addrlen, true, last); } static void From patchwork Thu Jun 28 03:46:51 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= X-Patchwork-Id: 935931 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=pass (mailfrom) smtp.mailfrom=nongnu.org (client-ip=2001:4830:134:3::11; helo=lists.gnu.org; envelope-from=qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org; receiver=) Authentication-Results: ozlabs.org; dmarc=none (p=none dis=none) header.from=amsat.org Authentication-Results: ozlabs.org; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=gmail.com header.i=@gmail.com header.b="TumHQkxZ"; dkim-atps=neutral Received: from lists.gnu.org (lists.gnu.org [IPv6:2001:4830:134:3::11]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 41GQpZ4dnYz9s29 for ; Thu, 28 Jun 2018 13:52:37 +1000 (AEST) Received: from localhost ([::1]:34415 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1fYNz0-0003Nc-Fy for incoming@patchwork.ozlabs.org; Wed, 27 Jun 2018 23:52:34 -0400 Received: from eggs.gnu.org ([2001:4830:134:3::10]:46229) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1fYNuD-0008E5-1u for qemu-devel@nongnu.org; Wed, 27 Jun 2018 23:47:38 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1fYNu9-0000q4-51 for qemu-devel@nongnu.org; Wed, 27 Jun 2018 23:47:37 -0400 Received: from mail-qt0-x230.google.com ([2607:f8b0:400d:c0d::230]:34509) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1fYNu8-0000pn-WB for qemu-devel@nongnu.org; Wed, 27 Jun 2018 23:47:33 -0400 Received: by mail-qt0-x230.google.com with SMTP id d23-v6so3604001qtp.1 for ; Wed, 27 Jun 2018 20:47:32 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=sender:from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=QjD7d1VDRG8nVNujLV3+aWu6rrF1GwFRcl4tmNjcWr0=; b=TumHQkxZvlh1RL6NZHt7t3eaGDAfnLMu9rXd6HOWE4K8+6E8/8TQ4TyXWCYBKyMjEn JonTVQVgVvTCfiahZegLpqHqnlJ2oomjQnHVPK8T8SpqVMM3E3IJKSlkydC2Rc+J9Bvu M7S4/OIuMGKI/eNHnS/PugiOiSnY1vfZ2fCsyPG0RBPYvZZ2MUOk6ukRVmjRJ6fUSb36 pu1iXY3PkoFCERytXSh2EZgto/JKOkfAyb4602dKhewLl+bzaAOJMHMYUnbvo/0M/2sf o0aWj7/mYjgGCsD1VdGLebsU/KtoUdjnJYwYZ3sUrMybJRdcD/H5ohq7rmLvA48xNkMx uY0w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:from:to:cc:subject:date:message-id :in-reply-to:references:mime-version:content-transfer-encoding; bh=QjD7d1VDRG8nVNujLV3+aWu6rrF1GwFRcl4tmNjcWr0=; b=sHOov+5c/1P6YTRr/jkoawSQ469Mad7d4ApWvlNKCf/RquS04/0MNrrNtQfgJz6AgZ XN1UE3L0gcOXJC3deXejcYptk9+06l0iGthK2JBnR9oSWMiNlOvQHU/vpCvtiuYhUq7S OuNUnH3aAoP3h2w7ETn9jsR5BooP5jSLIlUw0amPqv9y9cP17eEmjyCiHiaK7PN0g5Fu 1kueg5pHaa24oj8q3ibPofyXJRxJR9ZXNLkOKFVI4Gj7q1ZvA8z3buMJnYJo378BrVsG 6gr+FVSFA+g9gt38qGkd+qOVIkSqMlXRQ9pWofzKST/lxypWaj6RXmFI8oiIu/IVqErY qiqQ== X-Gm-Message-State: APt69E1D3Nfv8XJnaZy9CzOT9aDUxySW55fqvMD54MzEb7WdCwEVnbAk 8P3PN85j0uTAZN0+3BCItSA= X-Google-Smtp-Source: AAOMgpcodC5sMOMuU+T0H0+d4Oi44x5rkDH5+GBDNUv+HQhzPeVlv3TVWfzApZjI4Gcx/Hnr1ruWbg== X-Received: by 2002:ac8:29e:: with SMTP id p30-v6mr8031574qtg.131.1530157652437; Wed, 27 Jun 2018 20:47:32 -0700 (PDT) Received: from x1.local ([138.117.48.222]) by smtp.gmail.com with ESMTPSA id e11-v6sm4125854qkb.4.2018.06.27.20.47.29 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Wed, 27 Jun 2018 20:47:31 -0700 (PDT) From: =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= To: Laurent Vivier Date: Thu, 28 Jun 2018 00:46:51 -0300 Message-Id: <20180628034652.24152-12-f4bug@amsat.org> X-Mailer: git-send-email 2.18.0 In-Reply-To: <20180628034652.24152-1-f4bug@amsat.org> References: <20180628034652.24152-1-f4bug@amsat.org> MIME-Version: 1.0 X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 2607:f8b0:400d:c0d::230 Subject: [Qemu-devel] [PATCH v2 11/12] linux-user/strace: Improve getsockname() output X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: =?utf-8?q?Guido_G=C3=BCnther?= , Riku Voipio , =?utf-8?q?Philippe_Mathieu-Daud?= =?utf-8?b?w6k=?= , qemu-devel@nongnu.org Errors-To: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org Sender: "Qemu-devel" Signed-off-by: Philippe Mathieu-Daudé Tested-By: Guido Günther --- linux-user/strace.c | 13 +++++++++++++ linux-user/strace.list | 2 +- 2 files changed, 14 insertions(+), 1 deletion(-) diff --git a/linux-user/strace.c b/linux-user/strace.c index 5a52d98f3b..3c3f684b3e 100644 --- a/linux-user/strace.c +++ b/linux-user/strace.c @@ -1992,6 +1992,19 @@ print_bind(const struct syscallname *name, } #endif +#if defined(TARGET_NR_getsockname) +static void +print_getsockname(const struct syscallname *name, + abi_long arg0, abi_long arg1, abi_long arg2, + abi_long arg3, abi_long arg4, abi_long arg5) +{ + print_syscall_prologue(name); + print_raw_param("%d", arg0, 0); + print_sockaddr_ptr(arg1, arg2, 1); + print_syscall_epilogue(name); +} +#endif + #if defined(TARGET_NR_sendto) static void print_sendto(const struct syscallname *name, diff --git a/linux-user/strace.list b/linux-user/strace.list index 9977ce062b..44d436cd06 100644 --- a/linux-user/strace.list +++ b/linux-user/strace.list @@ -371,7 +371,7 @@ { TARGET_NR_getsid, "getsid" , NULL, NULL, NULL }, #endif #ifdef TARGET_NR_getsockname -{ TARGET_NR_getsockname, "getsockname" , NULL, NULL, NULL }, +{ TARGET_NR_getsockname, "getsockname" , NULL, print_getsockname, NULL }, #endif #ifdef TARGET_NR_getsockopt { TARGET_NR_getsockopt, "getsockopt" , NULL, NULL, NULL }, From patchwork Thu Jun 28 03:46:52 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= X-Patchwork-Id: 935927 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=pass (mailfrom) smtp.mailfrom=nongnu.org (client-ip=2001:4830:134:3::11; helo=lists.gnu.org; envelope-from=qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org; receiver=) Authentication-Results: ozlabs.org; dmarc=none (p=none dis=none) header.from=amsat.org Authentication-Results: ozlabs.org; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=gmail.com header.i=@gmail.com header.b="gjPzIBaz"; dkim-atps=neutral Received: from lists.gnu.org (lists.gnu.org [IPv6:2001:4830:134:3::11]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 41GQm56Y4Sz9ryk for ; Thu, 28 Jun 2018 13:50:29 +1000 (AEST) Received: from localhost ([::1]:34401 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1fYNwx-0001Zb-Hb for incoming@patchwork.ozlabs.org; Wed, 27 Jun 2018 23:50:27 -0400 Received: from eggs.gnu.org ([2001:4830:134:3::10]:46230) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1fYNuD-0008E6-27 for qemu-devel@nongnu.org; Wed, 27 Jun 2018 23:47:37 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1fYNuB-0000tF-Lj for qemu-devel@nongnu.org; Wed, 27 Jun 2018 23:47:37 -0400 Received: from mail-qt0-x232.google.com ([2607:f8b0:400d:c0d::232]:34511) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1fYNuB-0000ss-GH for qemu-devel@nongnu.org; Wed, 27 Jun 2018 23:47:35 -0400 Received: by mail-qt0-x232.google.com with SMTP id d23-v6so3604051qtp.1 for ; Wed, 27 Jun 2018 20:47:35 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=sender:from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=TeXRHiSvM06gSbHemT/dVEjvh6xQyFszQq/Zp47IGR0=; b=gjPzIBazIEchQ7wgp3DJfQvppbOvSfFXtkve1FSSoUn19ULrPnChCPBV744MEjw58k oaPAFGBBRYQFe5Lywdwztrm6pZvB6eDgHEhE3n3Sab+IQTI0uy3hEwv2ldFKNMGgoR1r w46Rga7/t0N6ny15DYbM1n9maE9ZGHR4FV80lhTYf5FD+St9vekAob0Reex92zIZIm+P UbqrnysYM7N1Df5oclZUBkAmkbsQcmGmASnCbGs19/vMjul+TZlW+PvT2ZSMWAnMUvaz H2cbTKj4mIsFyCYMAfidKTaOGV0pdMGCSiyfybtGn63OoT0gRy7+UNL99c5aj5V1mwKH E+dQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:from:to:cc:subject:date:message-id :in-reply-to:references:mime-version:content-transfer-encoding; bh=TeXRHiSvM06gSbHemT/dVEjvh6xQyFszQq/Zp47IGR0=; b=aIu/lMRRG/fPKJWU3KVtSop5fMB3TahK2sS4BLLjwPGfeKqxwXQKw2mFf0YcaPeFqK 50TPRvqVyw9IUcsUd1LlcL91bi3Q44NFvUbE3WpFtZv9bn4ebWLZnetgzOur+5QxuStW 3CzFr6jJgoA8JfU9VtiCtdDf0RdcaqGs1BREfIxkQNqooIVGAjBSMhOtQfXJQkCXMn2d hiYIEvL4oWZihhMieNnHxLIvSur4B19S6UjpGJ5YsGsEExTtCdcU5bGJZuzgUVwrCQ6Z ABW7c86UQSVYni34/mlLJECJp4oHTVKApjqfQNNvtwdcZvLzt+Lpc47PPYzT7a1Bku+T Mzwg== X-Gm-Message-State: APt69E2k/lZB+yosFVMM+Qf8BpumvqFRd2YMhrFjW2yXwJkcOp1OJWPJ NLPTFrtPLhI6pES+MrGSknU= X-Google-Smtp-Source: AAOMgpfG6h/iNoKVt0m9NycAZ6CWewII1NX9epdk40iQPDLWuPpMgsvvDy/6PGfKmsY+CyfcKZ/5rA== X-Received: by 2002:ac8:1738:: with SMTP id w53-v6mr8002984qtj.421.1530157654967; Wed, 27 Jun 2018 20:47:34 -0700 (PDT) Received: from x1.local ([138.117.48.222]) by smtp.gmail.com with ESMTPSA id e11-v6sm4125854qkb.4.2018.06.27.20.47.32 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Wed, 27 Jun 2018 20:47:34 -0700 (PDT) From: =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= To: Laurent Vivier Date: Thu, 28 Jun 2018 00:46:52 -0300 Message-Id: <20180628034652.24152-13-f4bug@amsat.org> X-Mailer: git-send-email 2.18.0 In-Reply-To: <20180628034652.24152-1-f4bug@amsat.org> References: <20180628034652.24152-1-f4bug@amsat.org> MIME-Version: 1.0 X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 2607:f8b0:400d:c0d::232 Subject: [Qemu-devel] [PATCH v2 12/12] linux-user/strace: Improve recvfrom() output X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: =?utf-8?q?Guido_G=C3=BCnther?= , Riku Voipio , =?utf-8?q?Philippe_Mathieu-Daud?= =?utf-8?b?w6k=?= , qemu-devel@nongnu.org Errors-To: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org Sender: "Qemu-devel" Signed-off-by: Philippe Mathieu-Daudé Tested-By: Guido Günther --- linux-user/strace.c | 16 ++++++++++++++++ linux-user/strace.list | 2 +- 2 files changed, 17 insertions(+), 1 deletion(-) diff --git a/linux-user/strace.c b/linux-user/strace.c index 3c3f684b3e..b31e9077c8 100644 --- a/linux-user/strace.c +++ b/linux-user/strace.c @@ -2005,6 +2005,22 @@ print_getsockname(const struct syscallname *name, } #endif +#if defined(TARGET_NR_recvfrom) +static void +print_recvfrom(const struct syscallname *name, + abi_long arg0, abi_long arg1, abi_long arg2, + abi_long arg3, abi_long arg4, abi_long arg5) +{ + print_syscall_prologue(name); + print_raw_param("%d", arg0, 0); + print_buf(arg1, arg2, 0); + print_raw_param(TARGET_ABI_FMT_ld, arg2, 0); + print_flags(msg_flags, arg3, 0); + print_sockaddr_ptr(arg4, arg5, 1); + print_syscall_epilogue(name); +} +#endif + #if defined(TARGET_NR_sendto) static void print_sendto(const struct syscallname *name, diff --git a/linux-user/strace.list b/linux-user/strace.list index 44d436cd06..6569451d07 100644 --- a/linux-user/strace.list +++ b/linux-user/strace.list @@ -1101,7 +1101,7 @@ { TARGET_NR_recv, "recv" , NULL, NULL, NULL }, #endif #ifdef TARGET_NR_recvfrom -{ TARGET_NR_recvfrom, "recvfrom" , NULL, NULL, NULL }, +{ TARGET_NR_recvfrom, "recvfrom" , NULL, print_recvfrom, NULL }, #endif #ifdef TARGET_NR_recvmmsg { TARGET_NR_recvmmsg, "recvmmsg" , NULL, NULL, NULL },