Received: by 2002:ac0:a5a6:0:0:0:0:0 with SMTP id m35-v6csp475406imm; Fri, 21 Sep 2018 03:28:14 -0700 (PDT) X-Google-Smtp-Source: ANB0VdYrFDdFDU4VFpJgV1Pl7SznUv5Fpe4f/AzR+4+Pfjm5EA38ZpknOJBd6zV0WSNZPHh+qJvQ X-Received: by 2002:a17:902:4403:: with SMTP id k3-v6mr43158313pld.243.1537525694621; Fri, 21 Sep 2018 03:28:14 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1537525694; cv=none; d=google.com; s=arc-20160816; b=gOCS7mGPgL2JmkNlMYJLANQ7P7lY4IsDbieJFcP5hCFwJ6GCaR7Vc7QuWfOA2Ysk/j 51UhYoYYxP5bH8li++CYUuDogK45l6iDBjqJYmF3hMzM5Yr25Ngda4eTjlcLl6QWvOVe 14MgdsckSEniRD4YP+YTeQ7rYUbojejsDMYPl3jx6DbF0VO+KcllZcpYdRfojVnD9kSG 2eWH6G4+FcSsehxcsRO1YsM3ZjYMQt5+sYDY6IGhKd/HdYCgMafTQ1peUr3w66Kt96WW e0+scNLR5Wc6nPqOyNyFeb1zlUNvwjmpCbv1Iz8VzXqF0tNrR2GA2cM7Rskop3VZMEgH db0A== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :message-id:date:subject:cc:to:from:dkim-signature; bh=8k9rGRkBKmUalmlPNgE7G1YhIeZTdJ1E2ctaQaUHbgc=; b=Bbr+oLSkO22v/UR0Xb2pw7H9+Zy3axok+bcuVtWvY4SBPNhJhQo3cwh72huWziJPoW KCRw4h+6T8PksGm/dPZ6+FIbWEy+W23+pThDmQmVrWT+lyoGyWlCLFsQWDKtqZ4OdB01 WX9F33AesZImeXcJ5BxCK3y/bMOrlMi0uLtuBzP+z50Ps7dIIDS509GnkgCaw65Xyr7B VuP/4lXmjAm00ey0N+78KDdD/AYNtQi2cbnCw8lpw5KOUvfRnOqk28dM0ENurxOzLoMg 7PuLvb41MaTZfmg0xQbaYvedSo9XTwjJ3Q1jnvxuxIdkd4eBIQVV9DyqzrtDE05Lyohe M23Q== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=nXhv4+xD; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id 139-v6si32651384pfb.45.2018.09.21.03.27.57; Fri, 21 Sep 2018 03:28:14 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=nXhv4+xD; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2389898AbeIUQOD (ORCPT + 99 others); Fri, 21 Sep 2018 12:14:03 -0400 Received: from mail-wr1-f67.google.com ([209.85.221.67]:32832 "EHLO mail-wr1-f67.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725898AbeIUQOD (ORCPT ); Fri, 21 Sep 2018 12:14:03 -0400 Received: by mail-wr1-f67.google.com with SMTP id n11-v6so1103526wro.0; Fri, 21 Sep 2018 03:25:49 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=8k9rGRkBKmUalmlPNgE7G1YhIeZTdJ1E2ctaQaUHbgc=; b=nXhv4+xD/X/n+fvJs0sWff46ScJgJ89XXcrbAovHCNb1Kzrruu2mkPNSlxVwZ1ileD a2QlbrW/apwu3ma4CxxxgREe4c6jpbEhNa+ABX+3/IUzwO/g1m3CEyTcsaMBtlCCog0S hhFyMm1sES0dVyhSnIUADk9IWIpnMKG7cHbhHRo6CoK+BsYNGRLVlMUG+cjmhyHTxoqI 2003niKvo741sm9OR/XzW1UuKJ6pzYOgx0KU7sDvJ+EBRvNFGWZ0FvWtYnsdBfNS572v GCslxLp/ThByyfo7pNMfhptfr/t7Tg16J6MuUVZ67kbIyFOpHZ/GcaNmSSHuNP0Ouf0S IMhg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=8k9rGRkBKmUalmlPNgE7G1YhIeZTdJ1E2ctaQaUHbgc=; b=MIGX/5WslqxRVK/LSqj07rYQg6SGuCVYcXZM533Pw0KtEQuZN9dw41FomfebxDEqmP 7xg8vlr/BN46Io3dI0uANLcqGHgNFC+5K0tE6RJFEsOKp4GsDitECq4EjbG2uB/+6+Mj dt2QdEOeBiShtnCpGdn16KwJEwG5InQxc9uAOtkaBO+2qdBWZ/oSsbwCFCpLWovGd/f/ 4JDcZAVk7Z2Hj1KXQYd2MM5Wq9WMsQ5iDhWDY3Yrz/Yw48U9HAjALsZyYx9lHAJ6BhJ0 bbVZIQdFFjtnxTS8yvUSWJgzR4ctEDdjXice2eTVFUwZWoST5p2tDqEgO7xxxBVFiGrP KumQ== X-Gm-Message-State: APzg51B/X9PlTRwVzHJZCzyzkNQUDP2GQ067VuClVNDz8hqxj2eXOcd7 rHu/YAgu2lUitXonBSNVqqQ= X-Received: by 2002:a5d:61c1:: with SMTP id q1-v6mr39099483wrv.33.1537525548490; Fri, 21 Sep 2018 03:25:48 -0700 (PDT) Received: from localhost (pD9E515A3.dip0.t-ipconnect.de. [217.229.21.163]) by smtp.gmail.com with ESMTPSA id 14-v6sm11455622wmp.32.2018.09.21.03.25.47 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Fri, 21 Sep 2018 03:25:48 -0700 (PDT) From: Thierry Reding To: Linus Walleij , Thierry Reding Cc: Thomas Gleixner , devicetree@vger.kernel.org, linux-tegra@vger.kernel.org, linux-gpio@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH 0/9] Implement wake event support on Tegra186 and later Date: Fri, 21 Sep 2018 12:25:37 +0200 Message-Id: <20180921102546.12745-1-thierry.reding@gmail.com> X-Mailer: git-send-email 2.19.0 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Thierry Reding Hi, The following is a set of patches that allow certain interrupts to be used as wakeup sources on Tegra186 and later. To implement this, each of the GPIO controllers' IRQ domain needs to become hierarchical, and parented to the PMC domain. The PMC domain in turn implements a new IRQ domain that is a child to the GIC IRQ domain. The above ensures that the interrupt chip implementation of the PMC is called at the correct time. The ->irq_set_type() and ->irq_set_wake() implementations program the PMC wake registers in a way to enable the given interrupts as wakeup sources. This is based on a suggestion from Thomas Gleixner that resulted from the following thread: https://lkml.org/lkml/2018/9/13/1042 Linus, I'm sending this as one series, but both the GPIO and PMC patches should be applicable separately. There are no build-time dependencies in the series. So once this has been duly reviewed, I think patches 1-5 can go through the Tegra tree, while patches 6-9 should go through the GPIO tree. Thierry Thierry Reding (9): dt-bindings: tegra186-pmc: Add interrupt controller properties soc/tegra: pmc: Add Tegra194 support soc/tegra: pmc: Add wake event support soc/tegra: pmc: Add initial Tegra186 wake events soc/tegra: pmc: Add initial Tegra194 wake events gpio: Add support for hierarchical IRQ domains dt-bindings: tegra186-gpio: Add wakeup parent support gpio: tegra186: Rename flow variable to type gpio: tegra186: Implement wake event support .../arm/tegra/nvidia,tegra186-pmc.txt | 3 + .../bindings/gpio/nvidia,tegra186-gpio.txt | 7 + drivers/gpio/gpio-tegra186.c | 109 +++++- drivers/gpio/gpiolib.c | 15 +- drivers/soc/tegra/pmc.c | 312 +++++++++++++++++- include/linux/gpio/driver.h | 6 + include/soc/tegra/pmc.h | 21 ++ 7 files changed, 451 insertions(+), 22 deletions(-) -- 2.19.0