Received: by 2002:a25:ad19:0:0:0:0:0 with SMTP id y25csp1927823ybi; Thu, 4 Jul 2019 02:11:29 -0700 (PDT) X-Google-Smtp-Source: APXvYqxIQTMBZb4K8Bny1k0T33W9aaeHCNRvdhOgkoP5QZYxK5EhuGvcdjRO51wHN+GUTutUi5Fv X-Received: by 2002:a17:90a:2641:: with SMTP id l59mr17443901pje.55.1562231489580; Thu, 04 Jul 2019 02:11:29 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1562231489; cv=none; d=google.com; s=arc-20160816; b=yGn52y5KoBhT7qSTwcMOAmK2uk6+CmoJI8kxopLhvW5OsrGIkrZQgP5G6/jhrZ2wui L9PbcGBA2mORHS0xucH8fStwG5YkETh6EvGzZOscyp5fNF/AkzXCy7EVLvnECWHT7Ocg YCOtPHQXljDO5YBUQDH8jJiSNhoIj/fRkuJxLV6l6qAayUppqt3JXpZf/JOXR+METL4m A4xFGts6YIqLQZUjvVks6J4YkANyibvV+VonXGgCe9sHTiPutosbtnJaugM8B3ULEBFB 6He2gMJpv2og3LaVNgxpYPqRrm9KEFdQQJu2mkywo4Ja75UvRm6mzp8fGa7VhW5d24lg vfNg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:in-reply-to:message-id:date :subject:cc:to:from; bh=lZiYZc8rpmPRSidYgwNNF3xoTjqoppEQzNAcjdnlkNQ=; b=P1F2Vk0q8IWV+Y2wexh9uGYWxAcQqWTFYulL1zUKEgxBO9D3I9bOAVgE3sAOg2MnAi Wc8XTaUeppKtn0OgUO6VvBMzmEEBiwRRN6YrjTwAHoCFRUmggUeQ2lIOMU/zNJQf6kgl qfuZkxF03aVtfEm/iyosb/Vw+neHMVIQRsflEzRcUs7Ke3yrpMAIyavzukArEmEKCe7A bbnFoogkD6KICVUTmxDQAgZBAeeMJ8FaHc21RBRmwDtb4vtOSVIdoTqZpHPCceuHgroZ dXSWwSDD7JlJN3h2SqtL7ztgSu/sxtvVIlppX5sZR+ZKKxZCtVBwF0PTdJk1GKMFelD5 XDqQ== ARC-Authentication-Results: i=1; mx.google.com; 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id 33si3812867plq.299.2019.07.04.02.11.14; Thu, 04 Jul 2019 02:11:29 -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; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727335AbfGDJKR (ORCPT + 99 others); Thu, 4 Jul 2019 05:10:17 -0400 Received: from host-88-217-225-28.customer.m-online.net ([88.217.225.28]:7798 "EHLO mail.dev.tdt.de" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1727158AbfGDJKP (ORCPT ); Thu, 4 Jul 2019 05:10:15 -0400 Received: from feckert01.dev.tdt.de (unknown [10.2.3.40]) by mail.dev.tdt.de (Postfix) with ESMTPSA id 6C97121590; Thu, 4 Jul 2019 09:02:29 +0000 (UTC) From: Florian Eckert To: Eckert.Florian@googlemail.com, info@metux.net, dvhart@infradead.org, andy@infradead.org Cc: platform-driver-x86@vger.kernel.org, linux-kernel@vger.kernel.org, Florian Eckert Subject: [PATCH 2/3] platform/x86/pcengines-apuv2: add legacy leds gpio definitions Date: Thu, 4 Jul 2019 11:02:04 +0200 Message-Id: <20190704090205.19400-3-fe@dev.tdt.de> X-Mailer: git-send-email 2.11.0 In-Reply-To: <20190704090205.19400-1-fe@dev.tdt.de> References: <20190704090205.19400-1-fe@dev.tdt.de> X-Spam-Status: No, score=-1.0 required=5.0 tests=ALL_TRUSTED autolearn=ham autolearn_force=no version=3.4.2 X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on mail.dev.tdt.de Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Extend the apu2_leds definition to make the leds exportable via the legacy gpio subsystem. Without this change the leds are not visible under "/sys/class/leds" and could not be configured. Signed-off-by: Florian Eckert --- drivers/platform/x86/pcengines-apuv2.c | 21 ++++++++++++++++++--- 1 file changed, 18 insertions(+), 3 deletions(-) diff --git a/drivers/platform/x86/pcengines-apuv2.c b/drivers/platform/x86/pcengines-apuv2.c index f6d8ed100cab..d50a50e9d34c 100644 --- a/drivers/platform/x86/pcengines-apuv2.c +++ b/drivers/platform/x86/pcengines-apuv2.c @@ -75,9 +75,24 @@ static const struct amd_fch_gpio_pdata board_apu2 = { /* gpio leds device */ static const struct gpio_led apu2_leds[] = { - { .name = "apu:green:1" }, - { .name = "apu:green:2" }, - { .name = "apu:green:3" } + { + .name = "apu:green:1", + .gpio = 505, + .default_trigger = "default-off", + .active_low = 1, + }, + { + .name = "apu:green:2", + .gpio = 506, + .default_trigger = "default-off", + .active_low = 1, + }, + { + .name = "apu:green:3", + .gpio = 507, + .default_trigger = "default-off", + .active_low = 1, + } }; static const struct gpio_led_platform_data apu2_leds_pdata = { -- 2.11.0