Received: by 2002:a05:6a10:22f:0:0:0:0 with SMTP id 15csp4692352pxk; Wed, 30 Sep 2020 09:15:05 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyNF0l/A9kuwV1wWU8OxSOVkfDvBX7j1OJu5bQaKcCClJ8WWnc8miEpiO04bcCG2DMKBL1e X-Received: by 2002:a17:906:16c8:: with SMTP id t8mr3702565ejd.272.1601482505733; Wed, 30 Sep 2020 09:15:05 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1601482505; cv=none; d=google.com; s=arc-20160816; b=k4IPHQ8qBJp6QFS5j5I8mOKcy4y1dJ2jazEe9LxuJjUTfPriqSKj98gz8+b3Q+4vuh uOZn/UWlqdWXzpFFwkmmMqPOpSqzfjsHsAVCbHR/26PnEDLbd4XwTjBl0BGz0T75q1AA 23uNu3/GW0ZKNbytQUqK+a/xgp0wBjoKFh93G93HnkRzaa74RxiLNaKeexhkmvoEqFmw 6j9z60qxomCs1gSbDTe4+zGndJgN18MFT/jEXqv5NecsleoBJTVmeq4qj3xm0Y9BIJye 4wLX5gxUI/kWvFbF/YX1jgbiD3WDhlVNQ6ZSiVG/95OcQlfGDv4a3aAiND5lKWcmvNbk RX2Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:cc:to:subject:message-id:date:from:in-reply-to :references:mime-version:dkim-signature; bh=bTDQ03JaaU0pCUT0VmAuAf0qZb00z72Lvx8xRhyXqcg=; b=PfLsZpVfuTBYFmvjkUIY0SiyyGWSFba0w77IO2atW+mHzEoj/8u6UbaXp2FS1lem59 t2hUtRpNr3MlWpz5RaNJd79R3g3f42EE5yo40xLoDaOoaFkcQL6FiVJSjBVZFP1/atut q3osWoIWJFDC5AZYEKNdyf/MDL8ueYO83yiTO5dSLMMgPHmC2MAelU5Me3L4c4+LOCwR trMmhDL9LYrRm6jC8+m5IHO5yzPYHXs1AHsn3V7GlXXjx21OPlXUIZLpoFPYwexOh/vy EL/hQwNCiZEFKFaLeFS3GiyUrm2Kp9mc4DoRtl8uESkMrEK6jaoqnnrN/vO0DgRS9vXl PR+w== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=NbbaS9N1; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 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. [23.128.96.18]) by mx.google.com with ESMTP id p34si1489381edb.470.2020.09.30.09.14.42; Wed, 30 Sep 2020 09:15:05 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=NbbaS9N1; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 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 S1731240AbgI3QLA (ORCPT + 99 others); Wed, 30 Sep 2020 12:11:00 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:48802 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1731045AbgI3QLA (ORCPT ); Wed, 30 Sep 2020 12:11:00 -0400 Received: from mail-pj1-x1029.google.com (mail-pj1-x1029.google.com [IPv6:2607:f8b0:4864:20::1029]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 1CA13C061755; Wed, 30 Sep 2020 09:11:00 -0700 (PDT) Received: by mail-pj1-x1029.google.com with SMTP id s14so189195pju.1; Wed, 30 Sep 2020 09:11:00 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=bTDQ03JaaU0pCUT0VmAuAf0qZb00z72Lvx8xRhyXqcg=; b=NbbaS9N1eZCO1LqaL2jIO4aaR1z3M6G6u/IEuZZrZ6IZUr79twMPEwng0YKO/4c7DC mwXQXnBCxanU29NRbMvzmlZkDlZBTsT/Dlt7D+ep1JxIpACIAb7cwx+2mQkXXXqeeMQ8 NGOj2Ux4HJv+LLyXJ5AhtVb8kWWDdli6m5ehBfADk7vxF9agIlSB2RGPrJeh9wkKab6I tE4HPtvSUzSI4dTcgJOTmJwNlZ9sYPEI49BwcaRNj7ovPd5qpLDh0Ov6BBtN/Tnb8S7q 1NpCwwyGR2zdbAQ8MbHb1XYOqemIJOn/MaEdAb/814o22nfLLcjhQF6muKsIDFdVnAhe 4yqA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=bTDQ03JaaU0pCUT0VmAuAf0qZb00z72Lvx8xRhyXqcg=; b=s0qyiGgoUs9sBh8yXcgdcjucjCmL8MZPuBUpFcWzU4mxD5HdyB1StNeyOUlJnH2A1d QhXQTWA2XRklBWpuGKWXQIAsOle37hXuL5jXL0qfHdJUIAH78DRnzwWC8uH82g5pIiFS oJ6m4kbo909afeLee7vH4PO7t4DjI7FlkYxq1aPLxL1Onj1C8SK0aXekiZu6+5urA2Of KckPT9F06HUrCowGX7B03ZDnDnn6BJuIVjQjqQRp9e0/e5oW9q1Xjcqu9pqRLYXsMlkj W7wCYqvFn6AgJEzsFO3rcYZRTK0uJul5Vrc9cx2q8nmSU/mEMbr7bVKxeS68ZaoohUIY wppw== X-Gm-Message-State: AOAM532rR8W2Fl9l+PxJ4HvKlzJ2FNFzt/ptERpPtQD4ewQpSrOAiAek Bx91oNiFEvvAGmB6WkKd5l/rnMFAYZLAiygJGEg= X-Received: by 2002:a17:902:ea8c:b029:d2:8abd:c8de with SMTP id x12-20020a170902ea8cb02900d28abdc8demr3252779plb.21.1601482258930; Wed, 30 Sep 2020 09:10:58 -0700 (PDT) MIME-Version: 1.0 References: <9152bb8be33e4192a7766eb53c6ca9af@asem.it> <22753b53cd7d4dfba4ef3610f71cc462@asem.it> <20200930130113.GQ3956970@smile.fi.intel.com> <2c26adae711145639d0b982a354aff3c@asem.it> In-Reply-To: From: Andy Shevchenko Date: Wed, 30 Sep 2020 19:10:39 +0300 Message-ID: Subject: Re: How to use an ACPI declared GPIO in a userspace ... To: Flavio Suligoi Cc: Bartosz Golaszewski , "linux-gpio@vger.kernel.org" , "linux-acpi@vger.kernel.org" , "linux-kernel@vger.kernel.org" Content-Type: text/plain; charset="UTF-8" Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, Sep 30, 2020 at 6:54 PM Andy Shevchenko wrote: > On Wed, Sep 30, 2020 at 6:39 PM Flavio Suligoi wrote: > > > I guess you simply didn't get. The "gpio-line-names" property of GPIO > > > *controller* (provider!) and you are trying to do something with the > > > *consumer* > > > if I got it right. > > > > > > And of course GPIO line, which has name, has no difference in use from > > > another > > > w/o name assigned. You will need to request it by *consumer* either in > > > kernel > > > or in user space. > > > > > > To be more precise we have to look at your DSDT. > > ^^^^^^^ **DSDT**. > > > My SSDT table is: > > ^^^^ See the difference? I can't help here. There are two ways to get DSDT: 1. % cp -a /sys/firmware/acpi/tables /tmp/mytables; tar -cf mytables.tar /tmp/mytables 2. % acpidump -o mytables.dat # preferable > > So I need a "consumer", but I don't want to export the GPIO using its number... > > If you have any suggestion ... > > Define "gpio-line-names" property in the *provider* (controller) > device node _DSD(). -- With Best Regards, Andy Shevchenko