From patchwork Thu Dec 19 13:09:15 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Klaus Jensen X-Patchwork-Id: 11303713 Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 48C6A6C1 for ; Thu, 19 Dec 2019 14:17:59 +0000 (UTC) Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 1DC88206D8 for ; Thu, 19 Dec 2019 14:17:59 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=fail reason="signature verification failed" (1024-bit key) header.d=samsung.com header.i=@samsung.com header.b="MclTpL02" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 1DC88206D8 Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=samsung.com Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=qemu-devel-bounces+patchwork-qemu-devel=patchwork.kernel.org@nongnu.org Received: from localhost ([::1]:42346 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1ihwcn-0001fv-EH for patchwork-qemu-devel@patchwork.kernel.org; Thu, 19 Dec 2019 09:17:57 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]:35830) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1ihvZ8-0001qu-EF for qemu-devel@nongnu.org; Thu, 19 Dec 2019 08:10:08 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1ihvZ5-0007IS-9J for qemu-devel@nongnu.org; Thu, 19 Dec 2019 08:10:05 -0500 Received: from mailout1.w1.samsung.com ([210.118.77.11]:47937) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1ihvZ3-0006bY-26 for qemu-devel@nongnu.org; Thu, 19 Dec 2019 08:10:02 -0500 Received: from eucas1p2.samsung.com (unknown [182.198.249.207]) by mailout1.w1.samsung.com (KnoxPortal) with ESMTP id 20191219130947euoutp01904fb500e16c563e4a75c064add32e7b~hx8OLargS1365313653euoutp01x for ; Thu, 19 Dec 2019 13:09:47 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 mailout1.w1.samsung.com 20191219130947euoutp01904fb500e16c563e4a75c064add32e7b~hx8OLargS1365313653euoutp01x DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=samsung.com; s=mail20170921; t=1576760987; bh=jpBBUmXuEntRtAATca5MMmA233TrPWVY0pW4njezoZk=; h=From:To:CC:Subject:Date:In-Reply-To:References:From; b=MclTpL028qTk+BeTwDYRnvn7J9ACjoNBbJH2l18sUJE4goIPb8UaY5YkKyYinnufN Ol6LCC704wh0iZq34NMW6e/01tC4psT1+lyP5KXb5hP/sQXTEU8BBFgbVko6AJgOCJ 2ZRQolDn78R6pyBEolG/QVHOszalEsgxz40rF5Zc= Received: from eusmges3new.samsung.com (unknown [203.254.199.245]) by eucas1p1.samsung.com (KnoxPortal) with ESMTP id 20191219130946eucas1p1d909f0c5084481e3718d943989fc8908~hx8N9I4BY1798017980eucas1p17; Thu, 19 Dec 2019 13:09:46 +0000 (GMT) Received: from eucas1p1.samsung.com ( [182.198.249.206]) by eusmges3new.samsung.com (EUCPMTA) with SMTP id 79.5F.60698.A967BFD5; Thu, 19 Dec 2019 13:09:46 +0000 (GMT) Received: from eusmtrp2.samsung.com (unknown [182.198.249.139]) by eucas1p1.samsung.com (KnoxPortal) with ESMTPA id 20191219130946eucas1p1f58691ec4abdc3b1f42a082450758a72~hx8NjMZMj1459314593eucas1p1P; Thu, 19 Dec 2019 13:09:46 +0000 (GMT) Received: from eusmgms1.samsung.com (unknown [182.198.249.179]) by eusmtrp2.samsung.com (KnoxPortal) with ESMTP id 20191219130946eusmtrp231dac4571352dd77864faa6dbbde5597~hx8NiqWDP3120131201eusmtrp2H; Thu, 19 Dec 2019 13:09:46 +0000 (GMT) X-AuditID: cbfec7f5-a0fff7000001ed1a-6f-5dfb769a7eb8 Received: from eusmtip2.samsung.com ( [203.254.199.222]) by eusmgms1.samsung.com (EUCPMTA) with SMTP id DC.4D.08375.A967BFD5; Thu, 19 Dec 2019 13:09:46 +0000 (GMT) Received: from CAMSVWEXC01.scsc.local (unknown [106.1.227.71]) by eusmtip2.samsung.com (KnoxPortal) with ESMTPA id 20191219130946eusmtip249537aee15a02bb8693ab15d862616e2~hx8Na3Ej43240732407eusmtip24; Thu, 19 Dec 2019 13:09:46 +0000 (GMT) Received: from CAMSVWEXC01.scsc.local (2002:6a01:e347::6a01:e347) by CAMSVWEXC01.scsc.local (2002:6a01:e347::6a01:e347) with Microsoft SMTP Server (TLS) id 15.0.1320.4; Thu, 19 Dec 2019 13:09:45 +0000 Received: from apples.local (106.110.32.41) by CAMSVWEXC01.scsc.local (106.1.227.71) with Microsoft SMTP Server id 15.0.1320.4 via Frontend Transport; Thu, 19 Dec 2019 13:09:45 +0000 From: Klaus Jensen To: Subject: [PATCH v4 18/24] pci: pass along the return value of dma_memory_rw Date: Thu, 19 Dec 2019 14:09:15 +0100 Message-ID: <20191219130921.309264-19-k.jensen@samsung.com> X-Mailer: git-send-email 2.24.1 In-Reply-To: <20191219130921.309264-1-k.jensen@samsung.com> MIME-Version: 1.0 X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFprCKsWRmVeSWpSXmKPExsWy7djPc7qzyn7HGvSfsbDY3N/OaDHp0DVG iyUXUy3m3VK2mPWunc3ieO8OFgc2j02rOtk87lzbw+bx5NpmJo/3+66yBbBEcdmkpOZklqUW 6dslcGXMOzyNqeAqR8Xbme+YGhjb2bsYOTkkBEwk9t0+yAhiCwmsYJQ4sqqwi5ELyP7CKPF0 8xMmCOczo8TJk4uZYTr+nD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bBYBVYlnz7Yxgti8AtYSc19PY4XYLS+x9dsnMJsTKL6l9zZYjZCAlcTjnx9ZIOoF JU7OfAJmMwMtbt3+mx3Clpdo3jqbeQKj8CwkZbOQlM1CUraAkXkVo0hqaXFuem6xoV5xYm5x aV66XnJ+7iZGYJRtO/Zz8w7GSxuDDzEKcDAq8fC+TP4dK8SaWFZcmXuIUYKDWUmE93bHz1gh 3pTEyqrUovz4otKc1OJDjKZAz01klhJNzgcmgLySeENTQ3MLS0NzY3NjMwslcd4OgYMxQgLp iSWp2ampBalFMH1MHJxSDYzMu+TNPU//tcp6LnPts0Wq+66ThrwezmJvt5dMPX1R4Nsjpe18 zb3HhPn7XnYmzI4JSThzbId1vOoknzYmvfYVbX/dPXskt4tdiOxi+35SJihAaPUBvkVTV51j q2EPPvpnqk/nHCmN7BdO0vJTxPZZLCiPXrh4yvTlr48/zl23qFXmveliR3clluKMREMt5qLi RACWxKZkyAIAAA== X-CMS-MailID: 20191219130946eucas1p1f58691ec4abdc3b1f42a082450758a72 X-Msg-Generator: CA X-RootMTR: 20191219130946eucas1p1f58691ec4abdc3b1f42a082450758a72 X-EPHeader: CA CMS-TYPE: 201P X-CMS-RootMailID: 20191219130946eucas1p1f58691ec4abdc3b1f42a082450758a72 References: <20191219130921.309264-1-k.jensen@samsung.com> X-detected-operating-system: by eggs.gnu.org: GNU/Linux 3.x [fuzzy] X-Received-From: 210.118.77.11 X-Mailman-Approved-At: Thu, 19 Dec 2019 08:56:47 -0500 X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Kevin Wolf , Beata Michalska , qemu-devel@nongnu.org, Max Reitz , Keith Busch , Javier Gonzalez Errors-To: qemu-devel-bounces+patchwork-qemu-devel=patchwork.kernel.org@nongnu.org Sender: "Qemu-devel" The nvme device needs to know the return value of dma_memory_rw to pass block/011 from blktests. So pass it along instead of ignoring it. There are no existing users of the return value, so this patch should be safe. Signed-off-by: Klaus Jensen Reviewed-by: Philippe Mathieu-Daudé Reviewed-by: Michael S. Tsirkin --- include/hw/pci/pci.h | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/include/hw/pci/pci.h b/include/hw/pci/pci.h index db75c6dfd05e..4d6f2b48a7f7 100644 --- a/include/hw/pci/pci.h +++ b/include/hw/pci/pci.h @@ -783,8 +783,7 @@ static inline AddressSpace *pci_get_address_space(PCIDevice *dev) static inline int pci_dma_rw(PCIDevice *dev, dma_addr_t addr, void *buf, dma_addr_t len, DMADirection dir) { - dma_memory_rw(pci_get_address_space(dev), addr, buf, len, dir); - return 0; + return dma_memory_rw(pci_get_address_space(dev), addr, buf, len, dir); } static inline int pci_dma_read(PCIDevice *dev, dma_addr_t addr,