From patchwork Fri Mar 12 02:45:51 2010 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Marcelo Tosatti X-Patchwork-Id: 47660 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 57A11B7D1C for ; Fri, 12 Mar 2010 13:52:35 +1100 (EST) Received: from localhost ([127.0.0.1]:45992 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1NpuyY-0001de-Qh for incoming@patchwork.ozlabs.org; Thu, 11 Mar 2010 21:51:46 -0500 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1Npuxp-0001ZP-4m for qemu-devel@nongnu.org; Thu, 11 Mar 2010 21:51:01 -0500 Received: from [199.232.76.173] (port=54421 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Npuxo-0001XZ-HF for qemu-devel@nongnu.org; Thu, 11 Mar 2010 21:51:00 -0500 Received: from Debian-exim by monty-python.gnu.org with spam-scanned (Exim 4.60) (envelope-from ) id 1Npuxm-0005ct-EI for qemu-devel@nongnu.org; Thu, 11 Mar 2010 21:51:00 -0500 Received: from mx1.redhat.com ([209.132.183.28]:30152) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1Npuxk-0005ch-Ig for qemu-devel@nongnu.org; Thu, 11 Mar 2010 21:50:58 -0500 Received: from int-mx04.intmail.prod.int.phx2.redhat.com (int-mx04.intmail.prod.int.phx2.redhat.com [10.5.11.17]) by mx1.redhat.com (8.13.8/8.13.8) with ESMTP id o2C2oqSX031172 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK); Thu, 11 Mar 2010 21:50:53 -0500 Received: from ns3.rdu.redhat.com (ns3.rdu.redhat.com [10.11.255.199]) by int-mx04.intmail.prod.int.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id o2C2oqsi019604; Thu, 11 Mar 2010 21:50:52 -0500 Received: from amt.cnet (vpn-10-50.rdu.redhat.com [10.11.10.50]) by ns3.rdu.redhat.com (8.13.8/8.13.8) with ESMTP id o2C2ooK9017595; Thu, 11 Mar 2010 21:50:51 -0500 Received: from amt.cnet (amt.cnet [127.0.0.1]) by amt.cnet (Postfix) with ESMTP id 4313B68AC5B; Thu, 11 Mar 2010 23:49:53 -0300 (BRT) Received: (from marcelo@localhost) by amt.cnet (8.14.3/8.14.3/Submit) id o2C2nqwG032751; Thu, 11 Mar 2010 23:49:52 -0300 Message-Id: <20100312024808.300129379@redhat.com> User-Agent: quilt/0.47-1 Date: Thu, 11 Mar 2010 23:45:51 -0300 From: Marcelo Tosatti To: kvm@vger.kernel.org, qemu-devel@nongnu.org References: <20100312024549.787893344@redhat.com> Content-Disposition: inline; filename=virtio-serial-wake X-Scanned-By: MIMEDefang 2.67 on 10.5.11.17 X-detected-operating-system: by monty-python.gnu.org: Genre and OS details not recognized. Cc: amit.shah@redhat.com, Marcelo Tosatti , avi@redhat.com Subject: [Qemu-devel] [patch 2/2] virtio-serial-bus: wake up iothread upon guest read notification 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 Wake up iothread when buffers are consumed. Signed-off-by: Marcelo Tosatti Index: qemu-ioworker/hw/virtio-serial-bus.c =================================================================== --- qemu-ioworker.orig/hw/virtio-serial-bus.c +++ qemu-ioworker/hw/virtio-serial-bus.c @@ -331,6 +331,7 @@ static void handle_output(VirtIODevice * static void handle_input(VirtIODevice *vdev, VirtQueue *vq) { + qemu_notify_event(main_io_worker); } static uint32_t get_features(VirtIODevice *vdev, uint32_t features)