From patchwork Fri Nov 3 01:30:58 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Shiji Yang X-Patchwork-Id: 740874 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 991EFC4332F for ; Fri, 3 Nov 2023 01:31:26 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1377738AbjKCBb1 (ORCPT ); Thu, 2 Nov 2023 21:31:27 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:52012 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1377663AbjKCBb0 (ORCPT ); Thu, 2 Nov 2023 21:31:26 -0400 Received: from JPN01-OS0-obe.outbound.protection.outlook.com (mail-os0jpn01olkn2011.outbound.protection.outlook.com [40.92.98.11]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 9899B1A4; Thu, 2 Nov 2023 18:31:23 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=Y1739Jj2e3owu15uoK/5Of9tVCgUkGCIbxUe6LU/gc56RvKfdYtzyAhGAl2JHuuaEk1/N48kuzJjQ8hhi450ffLgcMen9LyX/g0zQzPRMbSwUNw5Cfyl5NDE6IShsqtId4zltr2l0Jh78xUr/oxFASeniqRfcPyDssJH5CfW1lEa2Hc7hQRg+jtrezVc5ep2EAKnPURzn+t03Qod5e1I3BZb3G+ZCZ+hfZnO5S5p/zEH/GxVmU5pDAw3Gx8oaqa/u96uj9A6d8c1/n70pNiBLBwgo3+KTNBlu1cFoNcB3ByN/FKjyNf+vflip1w5VuYC8k1S3EsgFq7aIBCO4TivvQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=RyD8tGt069pWXz7NSDkgYMS5MXvQRRKeuJlO5vmgTWY=; b=CQR2GnIHWCxyOtsGvpALD0mxxlilsWDBzOn1kktdUKcB2cwXdt84A9LZU+ToyZkVz1TeOK1cOExXEMJ5XKTNp9FRlclAlUDjF8/GZoKr9hxmIXUjG/W+NeXy3KmY+SDo5JGzNOCzEGMebltOtRFTJFyPC6OBrcSdnEk0e0knFFaVB+zMnIURo03i8WbeFK+Dto6QzeWq6tKfCA1o3fMoINOkIvIb6o7A6vVL+zPJdf+OMaCgxlJJHmyjxTvlO1d8dXvauRYhQgY1znGQuPpQ3WNYR4NkcMNiKq/x60FkU561xXEdMfYYLxb3rQaGXadJCZYJVr27z/dUddF/mqrvSA== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=none; dmarc=none; dkim=none; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=outlook.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=RyD8tGt069pWXz7NSDkgYMS5MXvQRRKeuJlO5vmgTWY=; b=IPyiseMHdO3bj/djQi3y/93irEs3UjBCjGeukmcf+vNeK9anzC+9pzTG3LiPHM0FR3XJkmseVUKI5m2iwyMm24No8B1IA8bE8sRx+REz2LL4KCwnDZtOICqAg3jyOJ7B30VP3vsSZnbU9IkZ5WWDLVm6/zmyeyb4DDIBrVIeG432WYuqhiOrf01yVWbLmtOP4wfzq5EFrjE10Ep4APP4UI58QoAwL7dGFoseumPbbIIa5K+bq4H2nVgMBeRDIsLfBgq2UiIM7EQdi/IiNucsQQ0WIHIhHu7G5vTOQVLzUyGv8NCXN1qx4c2oN3cOazqvxlzGlwNV/jG01krooo+Yhw== Received: from TYAP286MB0315.JPNP286.PROD.OUTLOOK.COM (2603:1096:404:8041::8) by TYWP286MB3126.JPNP286.PROD.OUTLOOK.COM (2603:1096:400:2a0::5) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6954.21; Fri, 3 Nov 2023 01:31:19 +0000 Received: from TYAP286MB0315.JPNP286.PROD.OUTLOOK.COM ([fe80::465a:2534:4d99:a25b]) by TYAP286MB0315.JPNP286.PROD.OUTLOOK.COM ([fe80::465a:2534:4d99:a25b%6]) with mapi id 15.20.6954.022; Fri, 3 Nov 2023 01:31:19 +0000 From: Shiji Yang To: linux-leds@vger.kernel.org, devicetree@vger.kernel.org Cc: Pavel Machek , Lee Jones , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Jisheng Zhang , linux-kernel@vger.kernel.org, Shiji Yang Subject: [PATCH v3] dt-bindings: leds: add 'internet' and 'signal' function definitions Date: Fri, 3 Nov 2023 09:30:58 +0800 Message-ID: X-Mailer: git-send-email 2.39.2 X-TMN: [pinm7NMrVH0X7bFV4bSovBDD9JLP8xvW] X-ClientProxiedBy: TYCP286CA0351.JPNP286.PROD.OUTLOOK.COM (2603:1096:405:7c::20) To TYAP286MB0315.JPNP286.PROD.OUTLOOK.COM (2603:1096:404:8041::8) X-Microsoft-Original-Message-ID: <20231103013058.13089-1-yangshiji66@outlook.com> MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: TYAP286MB0315:EE_|TYWP286MB3126:EE_ X-MS-Office365-Filtering-Correlation-Id: 2b1a5da0-2e8b-4398-b391-08dbdc0c9424 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: HYCTO5mRe60s8S6JROEdiMnqF0qNgAztmCDD56Jh/wAHk1TkWejkr8Torrl4oWyLbgIw2i5LGXVzsgNVog9ONbv8h+wpT9nIsipJUbVE5siu1PFgJ3JPINS1I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WHBWCfpkz46vNUbrtYZdv7WQ051FraCqnsLabEk+TuwPQhGIDx6N1LoOToSQ3MZ7AX7/aWtnBa68TB3TMQW0zzwqFcYJeg2DbClp8Tm6664xGUSht9jxyVqs28Tbhgr/127IJ/jAJwX9tvJaR4jT92Z0MYPbO/ml0Tc77AXFnOCrFuCPmh6xtVMXt/anBuOzQv3mKTnpBj3aXM8n4Rt2Oi6g80fi6B0EJ0hi0n89nluU/243vVb2FUUIaQciPiMi5kRHmEFrR3DfZiTdTJ3U55H7bHajevfJIVIrfLHyAUEbMmXy///+imES3cuhXiAiyYVVcms6otTrVMmGj/qi957mj67g4eIsatgAkBdnCZtqDlSenGNasJPOzpIWEHLUmMmeH1lR8fuQ3I6WgrWTZPRoYQnta3+QtF7VcealA855+3o/jaqLH3O8hEySUVMc8grplaImg/KHPzbrVYUaEQxUBRrDJVhVW/MLxMBH7C8cR4s/tKVJQp75GnO1Eo9aSA/sncIWFXnYFUd4EC2MOE4M4EwyH2LUUVtK4mukAmwAoc6KcdCrHEUa3J0v7RhgSGnKrUKvFKKpKCVC8mbI+CxsculA22MRogkSbc7dXDuE3e06IWo/12sLtC0fiUl+SqRDS9TiAeznvaim5FPwfMDNem5gjqq8qsMQ+80pq6rOFtiY5Si+oXAW+qij7QWNSnAOE3123NPFJomsMqw2+iyy+/hi+jU/Ue6uTmRg/Y6hTDIY6adXD/rl/cYVTx2iqTuEE8m7T83ms= X-OriginatorOrg: outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: 2b1a5da0-2e8b-4398-b391-08dbdc0c9424 X-MS-Exchange-CrossTenant-AuthSource: TYAP286MB0315.JPNP286.PROD.OUTLOOK.COM X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 03 Nov 2023 01:31:19.5337 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 84df9e7f-e9f6-40af-b435-aaaaaaaaaaaa X-MS-Exchange-CrossTenant-RMS-PersistedConsumerOrg: 00000000-0000-0000-0000-000000000000 X-MS-Exchange-Transport-CrossTenantHeadersStamped: TYWP286MB3126 Precedence: bulk List-ID: X-Mailing-List: linux-leds@vger.kernel.org These two types of LEDs are widely used in routers and NICs. The 'signal' LED is used to display the wireless signal strength. Usually, there are 3~4 LEDs in one group to indicate the signal strength, similar to the signal icon on a mobile phone. The 'internet' LED can indicate whether the device can access a specific server. It's different from 'wan'. 'wan' usually indicates whether the WAN port is connected to the modem (internet services may still be unavailable). But the 'internet' shows if the device can successfully ping servers such as 8.8.8.8 to detect the internet connection status. When the router is running in AP only mode, we can even connect LAN port to the AC/modem to connect to the internet. In this case, the 'internet' LED should be on. On some routers, both 'internet' and 'wan' are available and can be controlled separately. Signed-off-by: Shiji Yang --- Changes in v2: * Remove the LED name sorting patch as it changes the ABI. * Add "devicetree@vger.kernel.org" to '--to' list. Thanks to Rob Herring and Krzysztof Kozlowski for letting me know I can send patch to multiple mailing list at once. Changes in v3: * Add more information about the new added LEDs. * Remove the missing LED fix as Jisheng Zhang has already sent a similar one. I should search the mailing list first... v1: https://lore.kernel.org/all/TYAP286MB0315FE921FF113BF76F7B700BCA0A@TYAP286MB0315.JPNP286.PROD.OUTLOOK.COM/ v2: https://lore.kernel.org/all/TYAP286MB03159A83A77E6FD59F271D9BBCA0A@TYAP286MB0315.JPNP286.PROD.OUTLOOK.COM/ include/dt-bindings/leds/common.h | 2 ++ 1 file changed, 2 insertions(+) diff --git a/include/dt-bindings/leds/common.h b/include/dt-bindings/leds/common.h index 9a0d33d02..55a426e39 100644 --- a/include/dt-bindings/leds/common.h +++ b/include/dt-bindings/leds/common.h @@ -88,11 +88,13 @@ #define LED_FUNCTION_FLASH "flash" #define LED_FUNCTION_HEARTBEAT "heartbeat" #define LED_FUNCTION_INDICATOR "indicator" +#define LED_FUNCTION_INTERNET "internet" #define LED_FUNCTION_LAN "lan" #define LED_FUNCTION_MAIL "mail" #define LED_FUNCTION_MTD "mtd" #define LED_FUNCTION_PANIC "panic" #define LED_FUNCTION_PROGRAMMING "programming" +#define LED_FUNCTION_RSSI "rssi" #define LED_FUNCTION_RX "rx" #define LED_FUNCTION_SD "sd" #define LED_FUNCTION_STANDBY "standby"