From patchwork Fri Sep 18 18:51:22 2009 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jan Kiszka X-Patchwork-Id: 33864 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from lists.gnu.org (lists.gnu.org [199.232.76.165]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (Client did not present a certificate) by ozlabs.org (Postfix) with ESMTPS id D69C4B7B71 for ; Sat, 19 Sep 2009 04:54:13 +1000 (EST) Received: from localhost ([127.0.0.1]:45205 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Moiax-0007Qn-CF for incoming@patchwork.ozlabs.org; Fri, 18 Sep 2009 14:54:11 -0400 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1MoiZL-0006T9-GA for qemu-devel@nongnu.org; Fri, 18 Sep 2009 14:52:31 -0400 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1MoiZH-0006Oc-Tz for qemu-devel@nongnu.org; Fri, 18 Sep 2009 14:52:31 -0400 Received: from [199.232.76.173] (port=45888 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1MoiZH-0006OL-Os for qemu-devel@nongnu.org; Fri, 18 Sep 2009 14:52:27 -0400 Received: from fmmailgate02.web.de ([217.72.192.227]:47494) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1MoiZH-0000xJ-6j for qemu-devel@nongnu.org; Fri, 18 Sep 2009 14:52:27 -0400 Received: from smtp06.web.de (fmsmtp06.dlan.cinetic.de [172.20.5.172]) by fmmailgate02.web.de (Postfix) with ESMTP id 8C6201216E953 for ; Fri, 18 Sep 2009 20:52:26 +0200 (CEST) Received: from [92.74.58.109] (helo=[192.168.1.10]) by smtp06.web.de with asmtp (TLSv1:AES256-SHA:256) (WEB.DE 4.110 #314) id 1MoiZG-0001xt-00 for qemu-devel@nongnu.org; Fri, 18 Sep 2009 20:52:26 +0200 Resent-From: Jan Kiszka Resent-To: qemu-devel Resent-Date: Fri, 18 Sep 2009 20:52:17 +0200 Resent-Message-Id: <4AB3D6E1.5060109@web.de> Resent-User-Agent: Mozilla/5.0 (X11; U; Linux i686 (x86_64); de; rv:1.8.1.12) Gecko/20080226 SUSE/2.0.0.12-1.1 Thunderbird/2.0.0.12 Mnenhy/0.7.5.666 From: Jan Kiszka To: qemu-devel@nongnu.org Date: Fri, 18 Sep 2009 20:51:22 +0200 Message-ID: <20090918185122.2879.37050.stgit@mchn012c.ww002.siemens.net> In-Reply-To: <20090918185122.2879.74216.stgit@mchn012c.ww002.siemens.net> References: <20090918185122.2879.74216.stgit@mchn012c.ww002.siemens.net> User-Agent: StGIT/0.14.3 MIME-Version: 1.0 X-Sender: jan.kiszka@web.de X-Provags-ID: V01U2FsdGVkX1+p9H8/JNY6IGc7LV7S+7VPcLuFHhszcF5pLlXp 4PsI6fXa4mLAVraBdu9+8cxczNz2qgn7xj++vTqZ8nxW5kZ+Ci DGFAP6IXg= X-detected-operating-system: by monty-python.gnu.org: GNU/Linux 2.4-2.6 Resent-Date: Fri, 18 Sep 2009 14:52:31 -0400 Subject: [Qemu-devel] [PATCH 1/8] musicpal: Catch null TX qeueues X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org Errors-To: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org They likely represent invalid queues that should be skipped. We already do this for RX queues. Wish I had a spec... Credits go to malc for analyzing the issue and suggesting this fix. Signed-off-by: Jan Kiszka --- hw/musicpal.c | 4 +++- 1 files changed, 3 insertions(+), 1 deletions(-) diff --git a/hw/musicpal.c b/hw/musicpal.c index 1c4f17c..c8f0235 100644 --- a/hw/musicpal.c +++ b/hw/musicpal.c @@ -238,7 +238,9 @@ static void eth_send(mv88w8618_eth_state *s, int queue_index) uint8_t buf[2048]; int len; - + if (!desc_addr) { + return; + } do { eth_tx_desc_get(desc_addr, &desc); if (desc.cmdstat & MP_ETH_TX_OWN) {