Received: by 10.223.185.111 with SMTP id b44csp1634696wrg; Sat, 10 Mar 2018 10:13:14 -0800 (PST) X-Google-Smtp-Source: AG47ELtNyPOEh7wr5nuR0B+TF6Y282bnF2Dr4Wb3QWZlR2rb9+BKdPczd229pUHp7bLnM0z2IyPO X-Received: by 2002:a17:902:2803:: with SMTP id e3-v6mr2778213plb.238.1520705594344; Sat, 10 Mar 2018 10:13:14 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1520705594; cv=none; d=google.com; s=arc-20160816; b=GoGaIh+euPJiMxBS44HFeuJ5HMoTpqCts41S4amFyh3lggURmNPLOqvdkoJ00Auerb aR2WgOz66YYY8OndrmJcJF8eCmrPzFt3aooYBfpM5LogZCxsURbQw57XO5hkF8mCiOUu phpnpYnBmb4YmZGeTPljP+9ufm2EelUxxc8pmffMq0pZgV5J6LBq1bPVTxTLz3Ag/hwR 9xtbo/9CkFgf3hutPb5da9O3b6hNUfFUEzvE7v0fVaNXl5Fv06AmbKHAcqtlwOmmSUvx zj+gR55wRNUfk2CWClXm5pMPR/HAzzFkyt3pLLevQ8Hchr8yxYcqd89WyzyEbLXw+hUE kD5w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:from:date:dkim-signature:arc-authentication-results; bh=tsEEyTDmjRTN2SolVFKWc9du0GoeXSFJYs2aCGlW/+s=; b=QZAP9aTfylNLjz46YIhJhxE2Rf1oYt0J8XPrXg1KAD+bjrkRfYuVzRz8iWbvEph0wd eZbx/YXTBffdWiFzZbBC+Am/NzW6ow3j7xx6Kk3k5eiUh5Sia4upiqf6MZ+zbyb/HJVS 2fRWd2v8o3Zs7lverw90DF4BVBDJPtiC4ZCk1hZyPBCmDEse0r45SBWd5Jtt9rWU3XjA 6mTUwLaQPeHvxK1Qt/jZ5qO5tCx8NTuV82kqM0PzGitfIQywucLen6i3560CAGBNdZEn +dhCThYlEVyfXxcYmAj5y2Em+iojF2SizCE+mbVCHhea/nwD0/UTxG0PnDKxUecselmA gQVA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=QKkgf7x7; 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 s16si2979851pfe.375.2018.03.10.10.12.59; Sat, 10 Mar 2018 10:13:14 -0800 (PST) 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=QKkgf7x7; 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 S1751324AbeCJSMF (ORCPT + 99 others); Sat, 10 Mar 2018 13:12:05 -0500 Received: from mail-it0-f67.google.com ([209.85.214.67]:39548 "EHLO mail-it0-f67.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751206AbeCJSMD (ORCPT ); Sat, 10 Mar 2018 13:12:03 -0500 Received: by mail-it0-f67.google.com with SMTP id l187-v6so6617566ith.4; Sat, 10 Mar 2018 10:12:03 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to:user-agent; bh=tsEEyTDmjRTN2SolVFKWc9du0GoeXSFJYs2aCGlW/+s=; b=QKkgf7x7ZTVeIqveLZ+efjBjlmRFdtzUJxafixK7Ly6f8ktj71Dnbl02uPrJasXSvV s7pZ+FrIX9Uul47FyuqHCBc8j03KAyOLDunCRA8Q6L646o+G/v2ivzeS5uaxkPRkpKvn wbj09k8/Ib2+KwjXcRFKNkb2WWkPkgdEcu23tKyfLNsEp9mPQwTlCmdmizePLbMM2uil U+opLz3gnMrLv99N80gHgkOU/h9ECWudqv7gJVwE0HJnV8KqmtBnOS3raqWhoMBrwQ+1 8PLewXK8/K5Pv5DjEaQOBqA0wFy7soGsTIW5aQYvvn4wgDdf6BwP0/o+JN13VU15lNP7 nGTw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to:user-agent; bh=tsEEyTDmjRTN2SolVFKWc9du0GoeXSFJYs2aCGlW/+s=; b=X25Ep3Xup0pCailcNYIydpN8zneiizx2uYESJlveRRq6ktCpjscNXnG5YIEjnuWLip pO+zHtxvoJt8TZGQVLUY+VLqH5hl2d7N/4ioyvDAlh3SZE7P51KjgWSl5zKd3V4asTmj OD9yotM90nul34FVCQVvHnZg2I43cpIx85ByDlteMfZDG6wZs1nAkpfTJ9NY/NaaJmOp dz0X03n1YfoPlkSUAbBDruAdBUwgoRT7USctrP4ztLE1yJAZljcJziSUmddKTO/GX6ug Vb7HLrxZrBhrGxuRUsBPElYzXGZMFSpsGrPh9AHq/rG3LO1n+/Lmr3U3ZYLpLlDrdji9 AIyw== X-Gm-Message-State: AElRT7F/xC53ZgJiei7gFG7TlF+b6A+wgH9bfr/bX/ri555UpMcxagNC +PQbce+S2g7y566tep/adsUaSKpK X-Received: by 10.36.13.8 with SMTP id 8mr2790657itx.42.1520705522523; Sat, 10 Mar 2018 10:12:02 -0800 (PST) Received: from dtor-ws ([2620:0:1000:1511:8de6:27a8:ed13:2ef5]) by smtp.gmail.com with ESMTPSA id g9sm163042ioi.87.2018.03.10.10.12.00 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Sat, 10 Mar 2018 10:12:01 -0800 (PST) Date: Sat, 10 Mar 2018 10:11:59 -0800 From: Dmitry Torokhov To: Rob Herring Cc: Jeffy Chen , linux-kernel@vger.kernel.org, briannorris@google.com, heiko@sntech.de, dtor@google.com, dianders@google.com, devicetree@vger.kernel.org, Guenter Roeck , Thomas Gleixner , Joseph Lo , stephen lu , Kate Stewart , linux-input@vger.kernel.org, Greg Kroah-Hartman , Mark Rutland , Philippe Ombredanne , Arvind Yadav Subject: Re: [PATCH v5 1/3] Input: gpio-keys - add support for wakeup event action Message-ID: <20180310181159.GA260013@dtor-ws> References: <20180308073213.8419-1-jeffy.chen@rock-chips.com> <20180308073213.8419-2-jeffy.chen@rock-chips.com> <20180309232720.pmqaulifiqa5czul@rob-hp-laptop> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20180309232720.pmqaulifiqa5czul@rob-hp-laptop> User-Agent: Mutt/1.9.2 (2017-12-15) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Fri, Mar 09, 2018 at 05:27:21PM -0600, Rob Herring wrote: > On Thu, Mar 08, 2018 at 03:32:11PM +0800, Jeffy Chen wrote: > > Add support for specifying event actions to trigger wakeup when using > > the gpio-keys input device as a wakeup source. > > > > This would allow the device to configure when to wakeup the system. For > > example a gpio-keys input device for pen insert, may only want to wakeup > > the system when ejecting the pen. > > > > Suggested-by: Brian Norris > > Signed-off-by: Jeffy Chen > > --- > > > > Changes in v5: > > Remove unneeded irq_wake flag as Andy suggested. > > > > Changes in v4: > > Add dt-binding gpio-keys.h, stop saving irq trigger type, add enable/disable wakeup helpers as Dmitry suggested. > > > > Changes in v3: > > Adding more comments as Brian suggested. > > > > Changes in v2: > > Specify wakeup event action instead of irq trigger type as Brian > > suggested. > > > > drivers/input/keyboard/gpio_keys.c | 63 +++++++++++++++++++++++++++++++++-- > > include/dt-bindings/input/gpio-keys.h | 13 ++++++++ > > This file should be in the binding patch. No, this is a folly. Both the header, along with the documentation (i.e. binding doc) should be together with the patch that introduces the changes. The patches are supposed to be self contained and sufficient to stand on their own. Neither this header, not the binding doc make sense without the change to the driver itself. Next we'll start adding #defines in a separate patch before using them... Thanks. -- Dmitry