Received: by 2002:a05:6a10:206:0:0:0:0 with SMTP id 6csp2432571pxj; Mon, 10 May 2021 02:52:02 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyQoWyj6Tq7EZck4Pp+yWn+AS+WKmaYNemAC4qu0lfX/rWxm9HnjT/0Z30f2DiuBpkHSRWJ X-Received: by 2002:a6b:6615:: with SMTP id a21mr17489171ioc.161.1620640322241; Mon, 10 May 2021 02:52:02 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1620640322; cv=none; d=google.com; s=arc-20160816; b=krpkOQy4b5jN80PAoOxUUaX8ZWRgGVdRvPHacPSZMYgLH3TrJG2XYEzY3oKUicOOmv qS3qpE7BhP9OleP75wu0kAq2xxz6pElbLos2npCrpvXhL/NBKhLHypfnQjNYIiWwkpio RQPRRm25+2i2i/sbtnFZ+Q019DCebd+nfQ5o4NAjuEZLoqkPc1aO+PW5DUvcVLczaUBu krR5zl0nNp+f5k7CJy+WFwfx4vF5gDiA4yAN28NV60AcjeGZS1oz7prgwYh+XRfcY8p8 mhQbUXSFpbbHUQE5FCYAbJU3DyCSFMQX8spD6qVBs10Mu/dTPkPz4Db5iqErkmCES/aq 0L0g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :message-id:date:subject:cc:to:from; bh=P98YIaLqPPQxUSK4TSQMNZzhBCJOqD38FrrxEt1VyMY=; b=HJWkIHHqTVGy4crmCSR0KUIE8F1wagJfB+KygmqvvfpORqzymnER6jtdn2fEBSwggp P16HhOvJ+udBad97t4QQh+9dIx2QfzIDCkKooaqYHlWplA1ANOMjFs68uiQbipBhkAws n3bfV7jD9faH8Bq3AxQN0plSNMBg+ZkO1udgRfvfZuXTo1uFv9OMywq85Lv+8l/0ZmSS Y8ac2gTLP3c1hUzhoRsFECRG1Lvg9VdGrPEIJE0hlVUAnU8uY4eehRFVYxTflOrJnO07 KykCt8+c6CJMiyCfC6aGe6BjlDxMK1paIsNetNloQzszxQ+7p1MVLK6mgxqFwuBPhUQl VJjg== ARC-Authentication-Results: i=1; mx.google.com; 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=fail (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 c188si8363020iof.9.2021.05.10.02.51.49; Mon, 10 May 2021 02:52:02 -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; 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=fail (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230474AbhEJJwN (ORCPT + 99 others); Mon, 10 May 2021 05:52:13 -0400 Received: from fgw22-7.mail.saunalahti.fi ([62.142.5.83]:16880 "EHLO fgw22-7.mail.saunalahti.fi" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230468AbhEJJwD (ORCPT ); Mon, 10 May 2021 05:52:03 -0400 Received: from localhost (88-115-248-186.elisa-laajakaista.fi [88.115.248.186]) by fgw22.mail.saunalahti.fi (Halon) with ESMTP id 37901f08-b175-11eb-88cb-005056bdf889; Mon, 10 May 2021 12:50:57 +0300 (EEST) From: Andy Shevchenko To: Pavel Machek , Andy Shevchenko , Amireddy Mallikarjuna reddy , Linus Walleij , =?UTF-8?q?Marek=20Beh=C3=BAn?= , Abanoub Sameh , Dan Murphy , Krzysztof Kozlowski , linux-leds@vger.kernel.org, linux-kernel@vger.kernel.org Cc: Andy Shevchenko Subject: [PATCH v1 00/28] leds: cleanups and fwnode refcounting bug fixes Date: Mon, 10 May 2021 12:50:17 +0300 Message-Id: <20210510095045.3299382-1-andy.shevchenko@gmail.com> X-Mailer: git-send-email 2.31.1 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org When analyzing the current state of affairs with fwnode reference counting I found that a lot of core doesn't take it right. Here is a bunch of corresponding fixes against LED drivers. The series includes some cleanups and a few other fixes grouped by a driver. First two patches are taking care of -ENOTSUPP error code too prevent its appearance in the user space. Andy Shevchenko (28): leds: class: The -ENOTSUPP should never be seen by user space leds: core: The -ENOTSUPP should never be seen by user space leds: el15203000: Give better margin for usleep_range() leds: el15203000: Make error handling more robust leds: el15203000: Correct headers (of*.h -> mod_devicetable.h) leds: el15203000: Introduce to_el15203000_led() helper leds: lgm-sso: Fix clock handling leds: lgm-sso: Put fwnode in any case during ->probe() leds: lgm-sso: Don't spam logs when probe is deferred leds: lgm-sso: Remove unneeded of_match_ptr() leds: lgm-sso: Remove explicit managed resource cleanups leds: lgm-sso: Drop duplicate NULL check for GPIO operations leds: lgm-sso: Convert to use list_for_each_entry*() API leds: lm3532: select regmap I2C API leds: lm3532: Make error handling more robust leds: lm36274: Put fwnode in error case during ->probe() leds: lm36274: Correct headers (of*.h -> mod_devicetable.h) leds: lm3692x: Put fwnode in any case during ->probe() leds: lm3692x: Correct headers (of*.h -> mod_devicetable.h) leds: lm3697: Update header block to reflect reality leds: lm3697: Make error handling more robust leds: lm3697: Don't spam logs when probe is deferred leds: lp50xx: Put fwnode in error case during ->probe() leds: lt3593: Put fwnode in any case during ->probe() leds: lt3593: Make use of device properties leds: pwm: Make error handling more robust leds: rt8515: Put fwnode in any case during ->probe() leds: sgm3140: Put fwnode in any case during ->probe() drivers/leds/Kconfig | 7 ++- drivers/leds/blink/leds-lgm-sso.c | 86 +++++++++++++------------------ drivers/leds/flash/leds-rt8515.c | 4 +- drivers/leds/led-class.c | 4 -- drivers/leds/led-core.c | 7 ++- drivers/leds/leds-el15203000.c | 54 ++++++++----------- drivers/leds/leds-lm3532.c | 7 +-- drivers/leds/leds-lm36274.c | 3 +- drivers/leds/leds-lm3692x.c | 11 ++-- drivers/leds/leds-lm3697.c | 22 ++++---- drivers/leds/leds-lp50xx.c | 2 +- drivers/leds/leds-lt3593.c | 13 ++--- drivers/leds/leds-pwm.c | 16 +++--- drivers/leds/leds-sgm3140.c | 8 +-- 14 files changed, 106 insertions(+), 138 deletions(-) -- 2.31.1