From patchwork Mon Jan 7 00:18:32 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Linus Walleij X-Patchwork-Id: 13849 Return-Path: X-Original-To: patchwork@peony.canonical.com Delivered-To: patchwork@peony.canonical.com Received: from fiordland.canonical.com (fiordland.canonical.com [91.189.94.145]) by peony.canonical.com (Postfix) with ESMTP id 90CEC23E33 for ; Mon, 7 Jan 2013 00:18:57 +0000 (UTC) Received: from mail-vb0-f53.google.com (mail-vb0-f53.google.com [209.85.212.53]) by fiordland.canonical.com (Postfix) with ESMTP id 3E575A1837B for ; Mon, 7 Jan 2013 00:18:57 +0000 (UTC) Received: by mail-vb0-f53.google.com with SMTP id b23so18248416vbz.26 for ; Sun, 06 Jan 2013 16:18:56 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=x-received:x-forwarded-to:x-forwarded-for:delivered-to:x-received :received-spf:from:to:cc:subject:date:message-id:x-mailer :mime-version:content-type:x-gm-message-state; bh=lkuiMJwMgOhw2h1lYF40FXzdE1WT78xhsASSKKrAXkM=; b=VrVsopKHmjmhVkqoSTm8AIf4dvyOYrfZNYl5IvgSOxKLrLKeYjVYJtRMIN+FGRkhzq BT7nnU9EQnvyWGob7ceqO6A8i8X4xs3IA7wrnunyU7XWLuQ+irxQN+1spfFhvJLwnz0T onDJkZ/7mc4wWFzh/zY6JdqQb6UZkvyOLr0ZVljpTVnvBt8IJA9clO2EoAR8Nw1UAbHG sPKQ/RDdRONn3ccJuA3E+2isv1XHAaYQU5Hiy4e0Lsu/lK/CJVYL9/Ewxp/Onu5Ish2F r3s5ksQVvRJtmYvKn5vzIguc8SpfJiXltmKgRouoM/PkMEWOlbsO4gaDBi7Yk3sszJ2F Rk6Q== X-Received: by 10.52.70.205 with SMTP id o13mr71001544vdu.75.1357517936680; Sun, 06 Jan 2013 16:18:56 -0800 (PST) X-Forwarded-To: linaro-patchwork@canonical.com X-Forwarded-For: patch@linaro.org linaro-patchwork@canonical.com Delivered-To: patches@linaro.org Received: by 10.58.145.101 with SMTP id st5csp39624veb; Sun, 6 Jan 2013 16:18:55 -0800 (PST) X-Received: by 10.14.178.196 with SMTP id f44mr162970973eem.14.1357517935260; Sun, 06 Jan 2013 16:18:55 -0800 (PST) Received: from eu1sys200aog108.obsmtp.com (eu1sys200aog108.obsmtp.com [207.126.144.125]) by mx.google.com with SMTP id n5si154652156eeo.11.2013.01.06.16.18.48 (version=TLSv1/SSLv3 cipher=OTHER); Sun, 06 Jan 2013 16:18:55 -0800 (PST) Received-SPF: neutral (google.com: 207.126.144.125 is neither permitted nor denied by best guess record for domain of linus.walleij@stericsson.com) client-ip=207.126.144.125; Authentication-Results: mx.google.com; spf=neutral (google.com: 207.126.144.125 is neither permitted nor denied by best guess record for domain of linus.walleij@stericsson.com) smtp.mail=linus.walleij@stericsson.com Received: from beta.dmz-ap.st.com ([138.198.100.35]) (using TLSv1) by eu1sys200aob108.postini.com ([207.126.147.11]) with SMTP ID DSNKUOoUZklUWwKkFarJUPPPwiLwqUXLovMm@postini.com; Mon, 07 Jan 2013 00:18:54 UTC Received: from zeta.dmz-ap.st.com (ns6.st.com [138.198.234.13]) by beta.dmz-ap.st.com (STMicroelectronics) with ESMTP id 5BD2AED; Mon, 7 Jan 2013 00:10:31 +0000 (GMT) Received: from relay1.stm.gmessaging.net (unknown [10.230.100.17]) by zeta.dmz-ap.st.com (STMicroelectronics) with ESMTP id 400E4BA4; Mon, 7 Jan 2013 00:18:41 +0000 (GMT) Received: from exdcvycastm004.EQ1STM.local (alteon-source-exch [10.230.100.61]) (using TLSv1 with cipher RC4-MD5 (128/128 bits)) (Client CN "exdcvycastm004", Issuer "exdcvycastm004" (not verified)) by relay1.stm.gmessaging.net (Postfix) with ESMTPS id EDC1E24C080; Mon, 7 Jan 2013 01:18:39 +0100 (CET) Received: from steludxu4075.lud.stericsson.com (10.230.100.153) by smtp.stericsson.com (10.230.100.2) with Microsoft SMTP Server (TLS) id 8.3.83.0; Mon, 7 Jan 2013 01:18:40 +0100 From: Linus Walleij To: , Grant Likely , Rob Herring , Thomas Gleixner Cc: Anmar Oueja , Linus Walleij Subject: [PATCH] irqdomain: document the simple domain first_irq Date: Mon, 7 Jan 2013 01:18:32 +0100 Message-ID: <1357517912-26053-1-git-send-email-linus.walleij@stericsson.com> X-Mailer: git-send-email 1.7.11.3 MIME-Version: 1.0 X-Gm-Message-State: ALoCoQlQN57wDiFttMcAi4zdSX78hssCyXbiLRvOdbDUZ7LhV6NVSIuA6Sezjc72jfbIFo/FqPrF From: Linus Walleij The first_irq needs to be zero to get a linear domain and that comes with special semantics. We want to simplify this going forward but some documentation never hurts. Signed-off-by: Linus Walleij --- kernel/irq/irqdomain.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/kernel/irq/irqdomain.c b/kernel/irq/irqdomain.c index 96f3a1d..059a280 100644 --- a/kernel/irq/irqdomain.c +++ b/kernel/irq/irqdomain.c @@ -143,7 +143,10 @@ static unsigned int irq_domain_legacy_revmap(struct irq_domain *domain, * irq_domain_add_simple() - Allocate and register a simple irq_domain. * @of_node: pointer to interrupt controller's device tree node. * @size: total number of irqs in mapping - * @first_irq: first number of irq block assigned to the domain + * @first_irq: first number of irq block assigned to the domain, + * pass zero to assign irqs on-the-fly. This will result in a + * linear IRQ domain so it is important to use irq_create_mapping() + * for each used IRQ, especially when SPARSE_IRQ is enabled. * @ops: map/unmap domain callbacks * @host_data: Controller private data pointer *