From patchwork Tue Jan 13 14:25:28 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Julien Grall X-Patchwork-Id: 43005 Return-Path: X-Original-To: linaro@patches.linaro.org Delivered-To: linaro@patches.linaro.org Received: from mail-wg0-f70.google.com (mail-wg0-f70.google.com [74.125.82.70]) by ip-10-151-82-157.ec2.internal (Postfix) with ESMTPS id 4035720DE8 for ; Tue, 13 Jan 2015 14:28:17 +0000 (UTC) Received: by mail-wg0-f70.google.com with SMTP id y19sf1862873wgg.1 for ; Tue, 13 Jan 2015 06:28:16 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:delivered-to:from:to:date:message-id:in-reply-to :references:cc:subject:precedence:list-id:list-unsubscribe:list-post :list-help:list-subscribe:mime-version:content-type :content-transfer-encoding:sender:errors-to:x-original-sender :x-original-authentication-results:mailing-list:list-archive; bh=W5DAGqrSxKkxHZvmbA9YELzWMTPiX896jNsKRr/WfGk=; b=hEd75W/LAngieHxy3sAXhTlrhKO5uD4BP6HNuUTYeR0R0cV/mVo/+Imi8YTlR6a3X9 dSVUzbKa2egCY6KoddHC6hu1BKb4uZlysg6RuDu8za9js+mtqrc4/ySwx30AhT9jtueQ nYvtfWrJAfdCImZA/NXPDb4N1IwnIZfjEPB66AOw0zrocaI0QBECjRCIkAa0Z4d1H8iY 810YbqJPo2tMB7QKlqLZCftrNVNqh4BKmSnCgGBkIUMexVeMuTlVmUvCEgCrco+5uacD 7MbZo99JH//hJIuuH2X0DOSC/57QyVQdnmoA64lk/Xbei5908SWvyee2SQUUAS/ReqYg YaZA== X-Gm-Message-State: ALoCoQlybJipxWxNEANLiKUS2BDqt78fTJ7dhNWDt7RGiOYH820MGXMrxM9+mDyLfmCT/yCc86xo X-Received: by 10.112.13.161 with SMTP id i1mr321617lbc.20.1421159296475; Tue, 13 Jan 2015 06:28:16 -0800 (PST) X-BeenThere: patchwork-forward@linaro.org Received: by 10.152.228.135 with SMTP id si7ls802lac.51.gmail; Tue, 13 Jan 2015 06:28:16 -0800 (PST) X-Received: by 10.112.140.196 with SMTP id ri4mr42245308lbb.55.1421159296122; Tue, 13 Jan 2015 06:28:16 -0800 (PST) Received: from mail-lb0-f178.google.com (mail-lb0-f178.google.com. [209.85.217.178]) by mx.google.com with ESMTPS id oq1si24376750lbb.98.2015.01.13.06.28.16 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Tue, 13 Jan 2015 06:28:16 -0800 (PST) Received-SPF: pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.217.178 as permitted sender) client-ip=209.85.217.178; Received: by mail-lb0-f178.google.com with SMTP id u14so2802491lbd.9 for ; Tue, 13 Jan 2015 06:28:16 -0800 (PST) X-Received: by 10.152.43.103 with SMTP id v7mr42758803lal.29.1421159296041; Tue, 13 Jan 2015 06:28:16 -0800 (PST) X-Forwarded-To: patchwork-forward@linaro.org X-Forwarded-For: patch@linaro.org patchwork-forward@linaro.org Delivered-To: patch@linaro.org Received: by 10.112.9.200 with SMTP id c8csp1398862lbb; Tue, 13 Jan 2015 06:28:15 -0800 (PST) X-Received: by 10.220.184.4 with SMTP id ci4mr21543723vcb.52.1421159281595; Tue, 13 Jan 2015 06:28:01 -0800 (PST) Received: from lists.xen.org (lists.xen.org. [50.57.142.19]) by mx.google.com with ESMTPS id i3si8102684vcz.22.2015.01.13.06.28.00 (version=TLSv1 cipher=RC4-SHA bits=128/128); Tue, 13 Jan 2015 06:28:01 -0800 (PST) Received-SPF: none (google.com: xen-devel-bounces@lists.xen.org does not designate permitted sender hosts) client-ip=50.57.142.19; Received: from localhost ([127.0.0.1] helo=lists.xen.org) by lists.xen.org with esmtp (Exim 4.72) (envelope-from ) id 1YB2Qr-0001gt-Gq; Tue, 13 Jan 2015 14:26:57 +0000 Received: from mail6.bemta5.messagelabs.com ([195.245.231.135]) by lists.xen.org with esmtp (Exim 4.72) (envelope-from ) id 1YB2Qn-0001Yu-UE for xen-devel@lists.xenproject.org; Tue, 13 Jan 2015 14:26:54 +0000 Received: from [85.158.139.211] by server-7.bemta-5.messagelabs.com id DF/6E-31453-D2B25B45; Tue, 13 Jan 2015 14:26:53 +0000 X-Env-Sender: julien.grall@linaro.org X-Msg-Ref: server-15.tower-206.messagelabs.com!1421159212!14433986!1 X-Originating-IP: [74.125.82.54] X-SpamReason: No, hits=0.0 required=7.0 tests= X-StarScan-Received: X-StarScan-Version: 6.12.5; banners=-,-,- X-VirusChecked: Checked Received: (qmail 7205 invoked from network); 13 Jan 2015 14:26:52 -0000 Received: from mail-wg0-f54.google.com (HELO mail-wg0-f54.google.com) (74.125.82.54) by server-15.tower-206.messagelabs.com with RC4-SHA encrypted SMTP; 13 Jan 2015 14:26:52 -0000 Received: by mail-wg0-f54.google.com with SMTP id z12so3228509wgg.13 for ; Tue, 13 Jan 2015 06:26:52 -0800 (PST) X-Received: by 10.180.210.195 with SMTP id mw3mr7931311wic.79.1421159212516; Tue, 13 Jan 2015 06:26:52 -0800 (PST) Received: from chilopoda.uk.xensource.com. ([185.25.64.249]) by mx.google.com with ESMTPSA id ni15sm14513482wic.18.2015.01.13.06.26.51 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Tue, 13 Jan 2015 06:26:51 -0800 (PST) From: Julien Grall To: xen-devel@lists.xenproject.org Date: Tue, 13 Jan 2015 14:25:28 +0000 Message-Id: <1421159133-31526-20-git-send-email-julien.grall@linaro.org> X-Mailer: git-send-email 2.1.4 In-Reply-To: <1421159133-31526-1-git-send-email-julien.grall@linaro.org> References: <1421159133-31526-1-git-send-email-julien.grall@linaro.org> Cc: stefano.stabellini@citrix.com, Julien Grall , tim@xen.org, ian.campbell@citrix.com, Jan Beulich Subject: [Xen-devel] [PATCH v3 19/24] xen/iommu: arm: Wire iommu DOMCTL for ARM X-BeenThere: xen-devel@lists.xen.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: List-Unsubscribe: , List-Post: , List-Help: , List-Subscribe: , MIME-Version: 1.0 Sender: xen-devel-bounces@lists.xen.org Errors-To: xen-devel-bounces@lists.xen.org X-Removed-Original-Auth: Dkim didn't pass. X-Original-Sender: julien.grall@linaro.org X-Original-Authentication-Results: mx.google.com; spf=pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.217.178 as permitted sender) smtp.mail=patch+caf_=patchwork-forward=linaro.org@linaro.org Mailing-list: list patchwork-forward@linaro.org; contact patchwork-forward+owners@linaro.org X-Google-Group-Id: 836684582541 List-Archive: Signed-off-by: Julien Grall Acked-by: Stefano Stabellini Cc: Jan Beulich --- Changes in v3: - Add Stefano's ack Changes in v2: - Don't move the call in common code. --- xen/arch/arm/domctl.c | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/xen/arch/arm/domctl.c b/xen/arch/arm/domctl.c index 485d3aa..cc4894e 100644 --- a/xen/arch/arm/domctl.c +++ b/xen/arch/arm/domctl.c @@ -33,7 +33,16 @@ long arch_do_domctl(struct xen_domctl *domctl, struct domain *d, return p2m_cache_flush(d, s, e); } default: - return subarch_do_domctl(domctl, d, u_domctl); + { + int rc; + + rc = subarch_do_domctl(domctl, d, u_domctl); + + if ( rc == -ENOSYS ) + rc = iommu_do_domctl(domctl, d, u_domctl); + + return rc; + } } }