From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([140.186.70.92]:48305) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1RqPnj-0005LC-I0 for qemu-devel@nongnu.org; Thu, 26 Jan 2012 08:55:49 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1RqPnd-0003oS-Kq for qemu-devel@nongnu.org; Thu, 26 Jan 2012 08:55:43 -0500 Received: from mx1.redhat.com ([209.132.183.28]:29729) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1RqPnd-0003oF-AI for qemu-devel@nongnu.org; Thu, 26 Jan 2012 08:55:37 -0500 Message-ID: <4F215B3C.7080003@redhat.com> Date: Thu, 26 Jan 2012 15:55:08 +0200 From: Avi Kivity MIME-Version: 1.0 References: <1327585538-26367-1-git-send-email-chouteau@adacore.com> In-Reply-To: <1327585538-26367-1-git-send-email-chouteau@adacore.com> Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Subject: Re: [Qemu-devel] [PATCH] GRLIB UART: Add RX channel List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Fabien Chouteau Cc: blauwirbel@gmail.com, qemu-devel@nongnu.org, atar4qemu@gmail.com On 01/26/2012 03:45 PM, Fabien Chouteau wrote: > @@ -141,18 +219,19 @@ grlib_apbuart_write(void *opaque, target_phys_addr_t addr, > static bool grlib_apbuart_accepts(void *opaque, target_phys_addr_t addr, > unsigned size, bool is_write) > { > - return is_write && size == 4; > + return size <= 4; > } Please drop this function. > > static const MemoryRegionOps grlib_apbuart_ops = { > .write = grlib_apbuart_write, > + .read = grlib_apbuart_read, > .valid.accepts = grlib_apbuart_accepts, The default is to accept sizes 1-4, so you can just drop .valid.accepts and need not replace it with anything. > . -- error compiling committee.c: too many arguments to function