From patchwork Tue Aug 5 10:47:38 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Marek Szyprowski X-Patchwork-Id: 34924 Return-Path: X-Original-To: linaro@patches.linaro.org Delivered-To: linaro@patches.linaro.org Received: from mail-ie0-f199.google.com (mail-ie0-f199.google.com [209.85.223.199]) by ip-10-151-82-157.ec2.internal (Postfix) with ESMTPS id 9311120523 for ; Tue, 5 Aug 2014 10:50:04 +0000 (UTC) Received: by mail-ie0-f199.google.com with SMTP id tr6sf3218906ieb.2 for ; Tue, 05 Aug 2014 03:50:04 -0700 (PDT) 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-archive:list-post:list-help:list-subscribe:mime-version :errors-to:sender:x-original-sender :x-original-authentication-results:mailing-list:content-type :content-transfer-encoding; bh=hf3zyIV1C/2+d3fqDZIdUbhH9cwKQc2/RAZnP6U9XB0=; b=WJkTG5R/1/1AJPViRAH4r9XUd3j+nK0hJt2geWqORRGbE/joAVe7U/eQRqhhrRyin6 ClhfMgIkdwCBUWuVQE9thB3WLmu0N4n9pq7mDXQaCItaETjTkDLS9zqEPzHAd7xsrrRU cqEjYh+Ln2ETdB2P8mddJ90ntsW2H2/6GuEbBVYXjNfIbKIyBfcEVZIfH0OaTH2ZUtnY YQoTcbmvgrh+rKV0WIWHgNaWB6IToOqalTuGqUQjL6FmtggjmsvkyhNTZ0Ati17YvWSE 420pZtWkuCdj7pIzd6sBRAVNOApkZB8eE+Sd1dGQPePT5MXFThmSwtDTUxqUSf4hpb+Y bhFw== X-Gm-Message-State: ALoCoQn+5wJTLc/hwGqE+h5JGCLcNwyan8mL2/uTCOJ9iQNb597WQBBAovvsJ0yz4pwbgTj00QO7 X-Received: by 10.182.123.163 with SMTP id mb3mr1502826obb.32.1407235804046; Tue, 05 Aug 2014 03:50:04 -0700 (PDT) X-BeenThere: patchwork-forward@linaro.org Received: by 10.140.86.80 with SMTP id o74ls246562qgd.48.gmail; Tue, 05 Aug 2014 03:50:03 -0700 (PDT) X-Received: by 10.53.7.204 with SMTP id de12mr1891749vdd.41.1407235803956; Tue, 05 Aug 2014 03:50:03 -0700 (PDT) Received: from mail-vc0-f169.google.com (mail-vc0-f169.google.com [209.85.220.169]) by mx.google.com with ESMTPS id da3si768721vcb.102.2014.08.05.03.50.03 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Tue, 05 Aug 2014 03:50:03 -0700 (PDT) Received-SPF: pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.220.169 as permitted sender) client-ip=209.85.220.169; Received: by mail-vc0-f169.google.com with SMTP id le20so1116654vcb.28 for ; Tue, 05 Aug 2014 03:50:03 -0700 (PDT) X-Received: by 10.220.7.131 with SMTP id d3mr993446vcd.49.1407235803888; Tue, 05 Aug 2014 03:50:03 -0700 (PDT) X-Forwarded-To: patchwork-forward@linaro.org X-Forwarded-For: patch@linaro.org patchwork-forward@linaro.org Delivered-To: patches@linaro.org Received: by 10.221.37.5 with SMTP id tc5csp374615vcb; Tue, 5 Aug 2014 03:50:03 -0700 (PDT) X-Received: by 10.140.19.230 with SMTP id 93mr4086297qgh.46.1407235803410; Tue, 05 Aug 2014 03:50:03 -0700 (PDT) Received: from ip-10-141-164-156.ec2.internal (lists.linaro.org. [54.225.227.206]) by mx.google.com with ESMTPS id c77si2179114qge.0.2014.08.05.03.50.02 for (version=TLSv1 cipher=RC4-SHA bits=128/128); Tue, 05 Aug 2014 03:50:03 -0700 (PDT) Received-SPF: none (google.com: linaro-mm-sig-bounces@lists.linaro.org does not designate permitted sender hosts) client-ip=54.225.227.206; Received: from localhost ([127.0.0.1] helo=ip-10-141-164-156.ec2.internal) by ip-10-141-164-156.ec2.internal with esmtp (Exim 4.76) (envelope-from ) id 1XEcJd-0005NH-QW; Tue, 05 Aug 2014 10:50:01 +0000 Received: from mailout3.w1.samsung.com ([210.118.77.13]) by ip-10-141-164-156.ec2.internal with esmtp (Exim 4.76) (envelope-from ) id 1XEcIh-0005F4-DB for linaro-mm-sig@lists.linaro.org; Tue, 05 Aug 2014 10:49:03 +0000 Received: from eucpsbgm2.samsung.com (unknown [203.254.199.245]) by mailout3.w1.samsung.com (Oracle Communications Messaging Server 7u4-24.01(7.0.4.24.0) 64bit (built Nov 17 2011)) with ESMTP id <0N9T008BXY1K9W00@mailout3.w1.samsung.com> for linaro-mm-sig@lists.linaro.org; Tue, 05 Aug 2014 11:48:56 +0100 (BST) X-AuditID: cbfec7f5-b7f776d000003e54-90-53e0b699a8da Received: from eusync3.samsung.com ( [203.254.199.213]) by eucpsbgm2.samsung.com (EUCPMTA) with SMTP id 94.DC.15956.996B0E35; Tue, 05 Aug 2014 11:48:57 +0100 (BST) Received: from amdc1339.digital.local ([106.116.147.30]) by eusync3.samsung.com (Oracle Communications Messaging Server 7u4-23.01 (7.0.4.23.0) 64bit (built Aug 10 2011)) with ESMTPA id <0N9T0057MY17SE80@eusync3.samsung.com>; Tue, 05 Aug 2014 11:48:57 +0100 (BST) From: Marek Szyprowski To: iommu@lists.linux-foundation.org, linux-samsung-soc@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org Date: Tue, 05 Aug 2014 12:47:38 +0200 Message-id: <1407235677-26324-11-git-send-email-m.szyprowski@samsung.com> X-Mailer: git-send-email 1.9.2 In-reply-to: <1407235677-26324-1-git-send-email-m.szyprowski@samsung.com> References: <1407235677-26324-1-git-send-email-m.szyprowski@samsung.com> X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFnrBLMWRmVeSWpSXmKPExsVy+t/xq7oztz0INliyTM3i76Rj7BbNi9ez WUy6P4HFYsF+a4vO2RvYLXoXXGWzONv0ht2ic+ISdosvVx4yWWx6fI3V4vKuOWwWM87vY7JY e+Quu8Wp65/ZLP71HmS0OHP6EqvF/z072C0Ov2lntTjycDe7xapdfxgtbv/mcxD1eHJwHpPH 71+TGD12zrrL7jG7Yyarx6ZVnWwe++euYffYvKTe4/a/x8wek28sZ/S4cqKJ1aO3+R2bx5ar 7SwefVtWMXp83iQXwBfFZZOSmpNZllqkb5fAlXH4VxtrQQ97xapVt1kaGH+wdjFyckgImEg8 ePaLDcIWk7hwbz2QzcUhJLCUUeLL815mCKePSWLvlN9MIFVsAoYSXW+7wKpEBHoZJfqbfjCB OMwC61gl9vdeZwGpEhZwldh3bQfYDhYBVYmZn3+CxXkFPCVW/5kJtVtO4v/LFWBTOYHih28e AIsLCXhI/Nywhn0CI+8CRoZVjKKppckFxUnpuUZ6xYm5xaV56XrJ+bmbGCGx83UH49JjVocY BTgYlXh4FfbeDRZiTSwrrsw9xCjBwawkwiux5kGwEG9KYmVValF+fFFpTmrxIUYmDk6pBkar +QKzmXvf2Syd5VK0zbBDaJFApsTrF5vWi0v1N3FVNBfolWtPY2J8ffNxH5voyatb922SniC2 8lzFm79ZwjWcP3z+arOlfhTmYeA8w7rHVejr7eRVE2pZM1dFdkXnFfx/8WjK1Zowm4nRz+rV rq84ZCydJfhh8Y5jbKG3uEL3ecw0vswv567EUpyRaKjFXFScCABCxS9NewIAAA== Cc: Rob Herring , Thierry Reding , Shaik Ameer Basha , Arnd Bergmann , Inki Dae , Greg Kroah-Hartman , Joerg Roedel , "Rafael J. Wysocki" , Tomasz Figa , linaro-mm-sig@lists.linaro.org, Kyungmin Park , Kukjin Kim , Laurent Pinchart , Sylwester Nawrocki , Olof Johansson , Cho KyongHo Subject: [Linaro-mm-sig] [PATCH 10/29] drivers: add DRIVER_HAS_OWN_IOMMU_MANAGER flag X-BeenThere: linaro-mm-sig@lists.linaro.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: , List-Help: , List-Subscribe: , MIME-Version: 1.0 Errors-To: linaro-mm-sig-bounces@lists.linaro.org Sender: linaro-mm-sig-bounces@lists.linaro.org X-Removed-Original-Auth: Dkim didn't pass. X-Original-Sender: m.szyprowski@samsung.com X-Original-Authentication-Results: mx.google.com; spf=pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.220.169 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 This patch adds a new flags for device drivers. This flag instructs kernel that the device driver does it own management of IOMMU assisted IO address space translations, so no default dma-mapping structures should be initialized. Signed-off-by: Marek Szyprowski --- include/linux/device.h | 2 ++ 1 file changed, 2 insertions(+) diff --git a/include/linux/device.h b/include/linux/device.h index 5f4ff02..2e62371 100644 --- a/include/linux/device.h +++ b/include/linux/device.h @@ -253,6 +253,8 @@ struct device_driver { /* disables bind/unbind via sysfs */ #define DRIVER_SUPPRESS_BIND_ATTRS (1 << 0) +/* driver uses own methods to manage IO address space */ +#define DRIVER_HAS_OWN_IOMMU_MANAGER (1 << 1) extern int __must_check driver_register(struct device_driver *drv); extern void driver_unregister(struct device_driver *drv);