From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-3.8 required=3.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI, SPF_HELO_NONE,SPF_PASS autolearn=no autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 922CFC433E0 for ; Tue, 22 Dec 2020 14:59:38 +0000 (UTC) Received: from merlin.infradead.org (merlin.infradead.org [205.233.59.134]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 4CED5229CA for ; Tue, 22 Dec 2020 14:59:38 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 4CED5229CA Authentication-Results: mail.kernel.org; dmarc=fail (p=quarantine dis=none) header.from=microchip.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=merlin.20170209; h=Sender:Content-Transfer-Encoding: Content-Type:Cc:List-Subscribe:List-Help:List-Post:List-Archive: List-Unsubscribe:List-Id:MIME-Version:Message-ID:Date:In-Reply-To:Subject:To: From:References:Reply-To:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Owner; bh=+8IccYi8R3TxCJEOubtpBRzbe+ZktbaUirSG+Np+bqI=; b=UCkahU2yT3BlXR8dSF3dwCjv7 dUtB7NUKRDrvvYFBDjAU8AmRqDvxkIOrrGqdWDasiwrE254FJ/6BXuO6X18Gigfn3dXr0JlINAm1S K1J3UMXQztts0+lY9ahQ5W5NCUhuco2fKIvbd3v7kVz/sWT+3Bs9/LProFGpODHFWN4A3jXwcXcTN 9BtzM1ddnNrJb2cS7iXzBbqyVFkkj4Ubd81hhTBh/kdYrDwVvTAouoagDC15ojiCKbg1wIGkv+qSZ FuAY59IFJ2SFOTM9eP5eiQRCuXPUaDaOnCcI5yx+1dSYUnYb20sBLMtMiAlIzUFfdNgKoLjH24WRA 29A+cff2A==; Received: from localhost ([::1] helo=merlin.infradead.org) by merlin.infradead.org with esmtp (Exim 4.92.3 #3 (Red Hat Linux)) id 1krj7M-0001oF-RV; Tue, 22 Dec 2020 14:58:28 +0000 Received: from esa.microchip.iphmx.com ([68.232.154.123]) by merlin.infradead.org with esmtps (Exim 4.92.3 #3 (Red Hat Linux)) id 1krj7K-0001nZ-4T for linux-arm-kernel@lists.infradead.org; Tue, 22 Dec 2020 14:58:26 +0000 DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=microchip.com; i=@microchip.com; q=dns/txt; s=mchp; t=1608649106; x=1640185106; h=references:from:to:cc:subject:in-reply-to:date: message-id:mime-version; bh=sAZWJmx5c/d61ulHI2FfUnXQ6P0/KlO7HU/s+AMVJjI=; b=O+HeUZVvlzOkmcom0CUPO8RaWFz5IafhjvbgCa13ToM1lp2HVr4OUWHb v0CfyBdCPkrLXsJy6QhWh8xDU/+MAp1Jhm5xkgEBFjQk7HBmwrdUJXsbm 6ATEldpIV/Lp3AeqWLRvRfKymM/8i3O51HoUJwMG9M0yCv/E+ASplMp/l Pcki0s4NlJMelDQszFLvj4T9mkIWSlRm5Tk2qjr58UkPXeaDt6KPzz5Ez bxIlBXDjTvLHkR4CCPXxoWtwzhmn03/cJA6h1QtuYTYIhdZzcGQAePCLl oKgWg03SINkLwH+AhV/h1XCyFhqChA8WsxYaPS72orCKQNHPbZXwNiGsi A==; IronPort-SDR: M9+cWPLCegujkM6O1CpBrC8OOAo588IURXNakAPVSpM7UvId8OrFCJ4EkvFbalZ4/DJgFChbZl ICPbJaomCz3I/S36cBSIkNOSzuKJf2logYZVh1WdS18RfWRweJPGypPrVzAd/9/fzWzIza9cT6 +BKsASAbNErOnfT622+PcBAjcEJh+5cc6NyMovXkOeoe5k14xBpt1hgNtJncFAnDmYj/qTw/70 3VbaWYOuIR6Yb8bTPqqap+bj2bFHihmljmiASbYlvZqAxyjF5Z1slRP1MLpw3qYAQejyxlrDXy MAA= X-IronPort-AV: E=Sophos;i="5.78,439,1599548400"; d="scan'208";a="97957140" Received: from smtpout.microchip.com (HELO email.microchip.com) ([198.175.253.82]) by esa4.microchip.iphmx.com with ESMTP/TLS/AES256-SHA256; 22 Dec 2020 07:58:23 -0700 Received: from chn-vm-ex04.mchp-main.com (10.10.85.152) by chn-vm-ex01.mchp-main.com (10.10.85.143) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.1979.3; Tue, 22 Dec 2020 07:58:23 -0700 Received: from soft-dev10.microchip.com (10.10.115.15) by chn-vm-ex04.mchp-main.com (10.10.85.152) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.1979.3 via Frontend Transport; Tue, 22 Dec 2020 07:58:21 -0700 References: <20201113145151.68900-1-lars.povlsen@microchip.com> <20201113145151.68900-4-lars.povlsen@microchip.com> <20201220224804.GA3107610@lunn.ch> <87eejip2xm.fsf@microchip.com> <20201222135646.GF3107610@lunn.ch> User-agent: mu4e 1.2.0; emacs 26.3 From: Lars Povlsen To: Andrew Lunn Subject: Re: [PATCH v10 3/3] arm64: dts: sparx5: Add SGPIO devices In-Reply-To: <20201222135646.GF3107610@lunn.ch> Date: Tue, 22 Dec 2020 15:58:14 +0100 Message-ID: <875z4tq455.fsf@microchip.com> MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20201222_095826_305096_20EA4ADE X-CRM114-Status: GOOD ( 18.16 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: devicetree@vger.kernel.org, Alexandre Belloni , Linus Walleij , linux-kernel@vger.kernel.org, Microchip Linux Driver Support , linux-gpio@vger.kernel.org, Andy Shevchenko , linux-arm-kernel@lists.infradead.org, Lars Povlsen Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org Andrew Lunn writes: > On Tue, Dec 22, 2020 at 11:09:41AM +0100, Lars Povlsen wrote: >> >> Andrew Lunn writes: >> >> > On Fri, Nov 13, 2020 at 03:51:51PM +0100, Lars Povlsen wrote: >> >> + led@8 { >> >> + label = "eth12:green"; >> >> + gpios = <&sgpio_out0 12 0 GPIO_ACTIVE_HIGH>; >> >> + default-state = "off"; >> >> + }; >> >> + led@9 { >> >> + label = "eth12:yellow"; >> >> + gpios = <&sgpio_out0 12 1 GPIO_ACTIVE_HIGH>; >> >> + default-state = "off"; >> >> + }; >> > >> > Hi Lars >> > >> > I did not see these patches earlier, but i've been looking at the >> > switch driver patches recently, so went digging. >> > >> > Can the Ethernet switch itself control these LEDs for indicating >> > things like packet receive/transmit, link state, and link speed? Or >> > are they purely software controlled? >> > >> > Thanks >> > Andrew >> >> Hi Andrew! >> >> No, the SGPIO device is separate from the switch device as such. I was >> planning to couple the two by means of "led events" in a later patch. > > O.K, good. > > In the LED subsystem terminology, such an event would be a > trigger. Link state, and copper speed should already be mostly covered > by phylib triggers. What is missing is link activity. Does the switch > easily provide you with this information, or do you need to poll the > switch statistics counters every 10ms to blink the LEDs? > > Andrew Hi Andrew! I am so thrilled with your interest and level of scrutiny! Thank you! And yes, I meant "LED trigger". The SGPIO's actually have a "blink" mode on their own, which I was planning to enable at a later time. But yes, you would still need some polling, but a somewhat lower rate, f.ex. 1 second. At that time, you could change between steady and blink mode. Again, that your for the level of effort you contribute to the switch driver, it is highly appreciated. Cheers, ---Lars -- Lars Povlsen, Microchip _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel