From nobody Mon Feb 9 18:46:29 2026 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of redhat.com designates 205.139.110.61 as permitted sender) client-ip=205.139.110.61; envelope-from=libvir-list-bounces@redhat.com; helo=us-smtp-delivery-1.mimecast.com; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 205.139.110.61 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com ARC-Seal: i=1; a=rsa-sha256; t=1590490090; cv=none; d=zohomail.com; s=zohoarc; b=bp1Ecs4BKdOxAM3Pl2zQ3HzgWynifDGH1GEYWF+tMyn9c5D5q04gg6cvfvhsaxh+1742k6OKUte9Hzf/LaS9BrNfVVVxz8HS16a+bfe0syajVvYvxt//D4gpqE4ruG4Nq9VoqvDg6tbV4gJD9t6fQENcDZ5jy0Yn35FsAyW5EyU= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1590490090; h=Content-Type:Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:To; bh=45UgqB7xiuv75to9D1xtOkBXTGrFM8LHRPwW44N+AXY=; b=e6lg7fXZmtZ0TbnDL8Oboe7KTMcOZ4qLad4IWUWXif+TP50CaoQTT4u9U8og8VydEGViKbWcmTzKCoBsUBFJZNWAVunquHcbo+yA62jQbGpkO09nUGeLzfUXTbaALwBoqyNK+QRSSrkA5RzCmGEEfURxuNyXvc5hz7psaSOGck4= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 205.139.110.61 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com Return-Path: Received: from us-smtp-delivery-1.mimecast.com (us-smtp-2.mimecast.com [205.139.110.61]) by mx.zohomail.com with SMTPS id 1590490090074755.968176306106; Tue, 26 May 2020 03:48:10 -0700 (PDT) Received: from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com [209.132.183.4]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-228-dHojzychMp2VYaa0jowmbQ-1; Tue, 26 May 2020 06:48:06 -0400 Received: from smtp.corp.redhat.com (int-mx07.intmail.prod.int.phx2.redhat.com [10.5.11.22]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id 204E4100CC8A; Tue, 26 May 2020 10:48:01 +0000 (UTC) Received: from colo-mx.corp.redhat.com (colo-mx02.intmail.prod.int.phx2.redhat.com [10.5.11.21]) by smtp.corp.redhat.com (Postfix) with ESMTPS id F122110013D2; Tue, 26 May 2020 10:48:00 +0000 (UTC) Received: from lists01.pubmisc.prod.ext.phx2.redhat.com (lists01.pubmisc.prod.ext.phx2.redhat.com [10.5.19.33]) by colo-mx.corp.redhat.com (Postfix) with ESMTP id C1A2E6B4D5; Tue, 26 May 2020 10:48:00 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx05.intmail.prod.int.rdu2.redhat.com [10.11.54.5]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id 04QAlvQu030016 for ; Tue, 26 May 2020 06:47:57 -0400 Received: by smtp.corp.redhat.com (Postfix) id 971C15EDC1; Tue, 26 May 2020 10:47:56 +0000 (UTC) Received: from mimecast-mx02.redhat.com (mimecast01.extmail.prod.ext.rdu2.redhat.com [10.11.55.17]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 9E5D45AB92 for ; Tue, 26 May 2020 10:47:54 +0000 (UTC) Received: from us-smtp-1.mimecast.com (us-smtp-2.mimecast.com [207.211.31.81]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-SHA384 (256/256 bits)) (No client certificate requested) by mimecast-mx02.redhat.com (Postfix) with ESMTPS id DB8608F7A3E for ; Tue, 26 May 2020 10:47:52 +0000 (UTC) Received: from mail-ed1-f67.google.com (mail-ed1-f67.google.com [209.85.208.67]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-13-8cLnzijjPoiRl1cTKpn2Lw-1; Tue, 26 May 2020 06:47:47 -0400 Received: by mail-ed1-f67.google.com with SMTP id e10so17247978edq.0; Tue, 26 May 2020 03:47:46 -0700 (PDT) Received: from x1w.redhat.com (71.red-88-21-204.staticip.rima-tde.net. [88.21.204.71]) by smtp.gmail.com with ESMTPSA id c27sm3342597ejd.19.2020.05.26.03.47.44 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 26 May 2020 03:47:45 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1590490088; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references:list-id:list-help: list-unsubscribe:list-subscribe:list-post; bh=45UgqB7xiuv75to9D1xtOkBXTGrFM8LHRPwW44N+AXY=; b=dFG/QV4TnHxa5eJjKrtsfVPasbCMOke3nyADwO/o8sRnloas+ZHQwVT++434dMSP+ZIjfD dvdFlwrMuTyY4RiaZWIZPg+7jMUq21L55XVMnph6bA43kt51MFJo0JtqStEYZwcASK6Uoa t7O3Aa0SsZMUh+fxk13LbKhW44S0/gQ= X-MC-Unique: dHojzychMp2VYaa0jowmbQ-1 X-MC-Unique: 8cLnzijjPoiRl1cTKpn2Lw-1 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=45UgqB7xiuv75to9D1xtOkBXTGrFM8LHRPwW44N+AXY=; b=QhG4LKuW7QqaVqzO1OnV9BbLe5CKf/NpOc7WO/b2P9Xipk1zizfSxKgQTor84oUCHg BlvKgb2z26PDBwGcioKRgHLu6phj4KghI9wJzTWls4fTdxwUu8II6RmPMZ7TQqp1fL4i mIVdJH+k3HAOX0Kgb2sxcLa9ujUR46D3kUSRNOs8pCv1ooPmSYwNWAffxt70gEPh1jD6 dY3IWdeoehtCFqb69lMSacdFaCS7jyEjOujxgpcY5YWM7tiH+G8ntIHv4iW9o5WE8Fs+ PVB/FtMcENaf1VqRFTzuUOroNrU+ON+s2iHcwLCjPVWdZ4FFn0rHTw1I32YJ6/Onm9Jc 04ZA== X-Gm-Message-State: AOAM5314zW9fKFmFO4cj8t+fNhbh6ECSNThX4txp3iTwra7QeR/CJJ4p EYqtTkyTJpD974Gxv9PNhno= X-Google-Smtp-Source: ABdhPJz2BuRcHYEb0vJvbDghC8GF7FUB+ZLTYw4hWm0S4PsoeKn/UWCsOYNfxvHRzf7lUPCp+rcP7g== X-Received: by 2002:a50:8e56:: with SMTP id 22mr18385165edx.268.1590490066045; Tue, 26 May 2020 03:47:46 -0700 (PDT) From: =?UTF-8?q?Philippe=20Mathieu-Daud=C3=A9?= To: qemu-devel@nongnu.org Subject: [PATCH 12/14] hw/mips/malta: Add some logging for bad register offset cases Date: Tue, 26 May 2020 12:47:24 +0200 Message-Id: <20200526104726.11273-13-f4bug@amsat.org> In-Reply-To: <20200526104726.11273-1-f4bug@amsat.org> References: <20200526104726.11273-1-f4bug@amsat.org> MIME-Version: 1.0 X-Mimecast-Spam-Signature: yes X-Scanned-By: MIMEDefang 2.79 on 10.11.54.5 X-loop: libvir-list@redhat.com Cc: Laurent Vivier , Aleksandar Rikalo , libvir-list@redhat.com, Thomas Huth , Jiaxun Yang , =?UTF-8?q?Philippe=20Mathieu-Daud=C3=A9?= , Aleksandar Markovic , Huacai Chen , Paolo Bonzini , =?UTF-8?q?Philippe=20Mathieu-Daud=C3=A9?= , Aurelien Jarno X-BeenThere: libvir-list@redhat.com X-Mailman-Version: 2.1.12 Precedence: junk List-Id: Development discussions about the libvirt library & tools List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: libvir-list-bounces@redhat.com Errors-To: libvir-list-bounces@redhat.com X-Scanned-By: MIMEDefang 2.84 on 10.5.11.22 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Type: text/plain; charset="utf-8"; text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable X-ZohoMail-DKIM: pass (identity @redhat.com) From: Aleksandar Markovic Log the cases where a guest attempts read or write using bad register offset. Reviewed-by: Philippe Mathieu-Daud=C3=A9 Tested-by: Philippe Mathieu-Daud=C3=A9 Signed-off-by: Aleksandar Markovic Message-id: <20200518200920.17344-21-aleksandar.qemu.devel@gmail.com> [PMD: Replaced TARGET_FMT_lx by HWADDR_PRIX] Signed-off-by: Philippe Mathieu-Daud=C3=A9 --- hw/mips/malta.c | 14 ++++++-------- 1 file changed, 6 insertions(+), 8 deletions(-) diff --git a/hw/mips/malta.c b/hw/mips/malta.c index e4c4de1b4e..b673a3a248 100644 --- a/hw/mips/malta.c +++ b/hw/mips/malta.c @@ -427,10 +427,9 @@ static uint64_t malta_fpga_read(void *opaque, hwaddr a= ddr, break; =20 default: -#if 0 - printf("malta_fpga_read: Bad register offset 0x" TARGET_FMT_lx "\n= ", - addr); -#endif + qemu_log_mask(LOG_GUEST_ERROR, + "malta_fpga_read: Bad register addr 0x%"HWADDR_PRIX"= \n", + addr); break; } return val; @@ -515,10 +514,9 @@ static void malta_fpga_write(void *opaque, hwaddr addr, break; =20 default: -#if 0 - printf("malta_fpga_write: Bad register offset 0x" TARGET_FMT_lx "\= n", - addr); -#endif + qemu_log_mask(LOG_GUEST_ERROR, + "malta_fpga_write: Bad register addr 0x%"HWADDR_PRIX= "\n", + addr); break; } } --=20 2.21.3