Received: by 2002:a05:6358:11c7:b0:104:8066:f915 with SMTP id i7csp4707489rwl; Mon, 3 Apr 2023 08:32:58 -0700 (PDT) X-Google-Smtp-Source: AKy350aRzCvkEDqVJ/QWS5Qrh7/HsrLrY3LzwtwaL6ub4IxK/wqw19vj8yzKPHtSq9zYHu4DW4Oo X-Received: by 2002:a17:90b:1a8b:b0:23f:4370:2c67 with SMTP id ng11-20020a17090b1a8b00b0023f43702c67mr40716493pjb.26.1680535978259; Mon, 03 Apr 2023 08:32:58 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1680535978; cv=none; d=google.com; s=arc-20160816; b=w638+l3dOTTQGw90xoCEUShjEY2z9W09g34GfCE3MnR93IVNylfyz0z37SypmmtW36 JdSmMh+YZPw6G+kT85kc0I4YzDubHad2TBU7jYzALzmun3HWeu78XcTxk4HkpCGPYZs/ O0jYB2vMTGhahiwBmU9ij9BGp1zDqvlXSXu6SKLjv+MwhqM/AVwfrTHRfi1PjQbNlih3 3o0WhPlyWvrnb/0r9bcfaiesY15q52zhgBInVZ0bD5Ht8dPjqL4XMReekmTm+r/5DVoq jgutpGLGz+FSEoinntFfF23177J+xH7QnxyLQL7oirQ910Pa1QrVyWLaxo3DMQ/6G+9J xpEg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date:dkim-signature; bh=/+20JBJaASJiHllLcAKtoJ1jR606tnbtfKQ5j05D9C4=; b=Aqkg/r1L+AgtgdJ8Bs4gLfVAhIrB/3G2RnisR4nbh8Jb6V7OYxA066CattnLkMkX+n 1G5rmwbgwCbWU4yTQqjM6kqzhX2qWWpulYzShDagYuv6DVCutUOsO75a5xtWDHcQfdKm qVFaZ8Qo334kRFUtBCUbqj2LcAG2R9/WK+F4w+WnJPqv71RRHwmehggVv3aRiedIdx6R eb6PmWv0D17QnDB5cuSVq98LD41mB+7VIw7HW9aLk4p0nDHUg3SXPt6foxo7GU4GKXix qI1yqKFup8O4ApGHujoOq6Um7Kao71L2BR8Smu3MAveqZlIMgUqnSFnbWs+3Vkc+t6Et 9EXg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@ucw.cz header.s=gen1 header.b=Nim0RUyw; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=ucw.cz Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id u27-20020a63235b000000b005031abe8d8bsi346124pgm.745.2023.04.03.08.32.43; Mon, 03 Apr 2023 08:32:57 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@ucw.cz header.s=gen1 header.b=Nim0RUyw; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=ucw.cz Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232715AbjDCPYA (ORCPT + 99 others); Mon, 3 Apr 2023 11:24:00 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:57696 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230108AbjDCPX7 (ORCPT ); Mon, 3 Apr 2023 11:23:59 -0400 Received: from jabberwock.ucw.cz (jabberwock.ucw.cz [46.255.230.98]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 905E118C; Mon, 3 Apr 2023 08:23:58 -0700 (PDT) Received: by jabberwock.ucw.cz (Postfix, from userid 1017) id 1DC491C0DFD; Mon, 3 Apr 2023 17:23:56 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ucw.cz; s=gen1; t=1680535436; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=/+20JBJaASJiHllLcAKtoJ1jR606tnbtfKQ5j05D9C4=; b=Nim0RUywF55I5QTq6a5tEMFkLTBvxDUf5atsqLCthbPnd2GDYj5kByGOzHoI/fVoZ3do6X Nm4yXgCb4zsqfX/5Kpb7y3cRjk61juLRgju8oxIuUBgL5l7EPmab1z9ssm0FbASLBNSu83 DeahazT5TI8WIj+2fbzT6pT5UOBAzbI= Date: Mon, 3 Apr 2023 17:23:55 +0200 From: Pavel Machek To: "H. Nikolaus Schaller" Cc: Marek =?iso-8859-1?Q?Beh=FAn?= , Lee Jones , linux-leds@vger.kernel.org, linux-kernel@vger.kernel.org, letux-kernel@openphoenux.org, NeilBrown , Linus Walleij Subject: Re: [PATCH] leds: tca6507: fix error handling of using fwnode_property_read_string Message-ID: References: MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="RvdtlErZpwC/giq0" Content-Disposition: inline In-Reply-To: X-Spam-Status: No, score=-0.2 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,DKIM_VALID_EF,SPF_HELO_NONE,SPF_NONE autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org --RvdtlErZpwC/giq0 Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Sun 2023-04-02 13:12:59, H. Nikolaus Schaller wrote: > Commit 96f524105b9c ("leds: tca6507: use fwnode API instead of OF") >=20 > changed to fwnode API but did not take into account that a missing proper= ty > "linux,default-trigger" now seems to return an error and as a side effect > sets value to -1. This seems to be different from of_get_property() which > always returned NULL in any case of error. >=20 > Neglecting this side-effect leads to >=20 > [ 11.201965] Unable to handle kernel paging request at virtual address = ffffffff when read >=20 > in the strcmp() of led_trigger_set_default() if there is no led-trigger > defined in the DTS. >=20 > I don't know if this was recently introduced somewhere in the fwnode lib > or if the effect was missed in initial testing. Anyways it seems to be a > bug to ignore the error return value of an optional value here in the > driver. >=20 > Fixes: 96f524105b9c ("leds: tca6507: use fwnode API instead of OF") > Cc: Marek Beh=FAn > Cc: NeilBrown > Cc: Linus Walleij > Signed-off-by: H. Nikolaus Schaller Acked-by: Pavel Machek BR, Pavel --=20 People of Russia, stop Putin before his war on Ukraine escalates. --RvdtlErZpwC/giq0 Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iF0EABECAB0WIQRPfPO7r0eAhk010v0w5/Bqldv68gUCZCrviwAKCRAw5/Bqldv6 8uQ4AJ9rOLLlv5G2BzpYWe8ul/PHu2RIqACgri1XbusH5tIqu5gkm1e/2B7bUKs= =PFP8 -----END PGP SIGNATURE----- --RvdtlErZpwC/giq0--