From: Ian Campbell Subject: Re: [PATCH 0/2] QEMU/xen: simplify cpu_ioreq_pio and cpu_ioreq_move Date: Fri, 7 Dec 2012 16:30:43 +0000 Message-ID: <1354897843.31710.93.camel@zakaz.uk.xensource.com> References: <20674.5586.142286.869968@mariner.uk.xensource.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: In-Reply-To: <20674.5586.142286.869968@mariner.uk.xensource.com> List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xen.org Errors-To: xen-devel-bounces@lists.xen.org To: Ian Jackson Cc: "dongxiao.xu@intel.com" , "xen-devel@lists.xensource.com" , "qemu-devel@nongnu.org" , Stefano Stabellini List-Id: xen-devel@lists.xenproject.org On Fri, 2012-12-07 at 16:14 +0000, Ian Jackson wrote: > + target_phys_addr_t offset = (target_phys_addr_t)req->size * i; > + if (req->df) addr -= offset; > + else addr -= offset; One of these -= should be a += I presume? [...] > + write_phys_req_item((target_phys_addr_t) req->data, req, i, &tmp); This seems to be the only one with this cast, why? write_phys_req_item takes a target_phys_addr_t so this will happen regardless I think. Ian.