Received: by 2002:a05:7412:8d10:b0:f3:1519:9f41 with SMTP id bj16csp6789861rdb; Fri, 15 Dec 2023 08:20:56 -0800 (PST) X-Google-Smtp-Source: AGHT+IEJFFkp2isCyH6Yh/9Yfg1nedb8tDytd/3xl322PFgbQ/l46Xb15Ft6e0aNy62fGWcs94A5 X-Received: by 2002:a05:620a:640c:b0:77f:384f:678c with SMTP id pz12-20020a05620a640c00b0077f384f678cmr12729010qkn.122.1702657255843; Fri, 15 Dec 2023 08:20:55 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1702657255; cv=none; d=google.com; s=arc-20160816; b=1IflzV9UrNBGu2MCF9qvYl3jwgzKILbbXDJO8bHmqNhQagA4V/Lpt/heZmXS0gjXzw h20YYTe6l3afiOOVL6ilAkxdbSAr8OYmwgtmT3Xs5shITSxpLMGZ++wLyUSbliDpeIg2 UGIylPDdW15eLEq2M6e+sUrqrO8vAyXfHbQxiZuJb2/vlZ46blqXuTvOGPhvRYlBLpRy 8BbGsGbTurROlEawFEwZUEU0dM9TBFdJmpve+sD5wzk8NIq1O7umP6wT+gxbkTm/tNCt 7WV9GQ9BIyBaTW9sPMXws5cSaapAoJguvun93IZ2qO0Vd0Nd9TEttNUI8BkYhZu0zRpj H35g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=in-reply-to:content-transfer-encoding:content-disposition :mime-version:list-unsubscribe:list-subscribe:list-id:precedence :references:message-id:subject:cc:to:from:date:dkim-signature; bh=15H4lc0cZ+I74xc7dsPm6DdY8h8nlXNLWef81yNAcWQ=; fh=gmg1qH50HAGLlIBUE/v1Ko/qzh7TnJbbDJy+FT3ACrI=; b=GpDRjtvVK6XuAlhO8FR5F1lhlHXjdr2BPBlIU3AB89uhL9zYT/BWueUZE3VeioQ+2N qdEm+UiMwFF5WR6MofWJb/tqqS/AT5YoQSGxMUWBt1MF7b037nV56/uzUCBQ3X1NzX8X ingt4nMP1q1OIOzc2n1x9o7+PJEbUqrAxfOnQmr52E0zF+Wd5loec/9YvvkBy8XgalrA 4umFnZnjeQsJus3ENWxzaqRqvHfaicP7QUT/ZhYAYQm8af0CM/jnZN8FTV1UjgpDe0AF RO97n8nkhvg57MzEgi2G5ZkKsMYlmjPSuCEfv9o0jLlP6wlsGjjLfdZtgwpYEWbtmajj omFg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@t-8ch.de header.s=mail header.b=XnQLs3DJ; spf=pass (google.com: domain of linux-kernel+bounces-1283-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.199.223 as permitted sender) smtp.mailfrom="linux-kernel+bounces-1283-linux.lists.archive=gmail.com@vger.kernel.org" Return-Path: Received: from ny.mirrors.kernel.org (ny.mirrors.kernel.org. [147.75.199.223]) by mx.google.com with ESMTPS id 1-20020a05620a048100b00779e2bd2ec1si12980296qkr.701.2023.12.15.08.20.55 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 15 Dec 2023 08:20:55 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-1283-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.199.223 as permitted sender) client-ip=147.75.199.223; Authentication-Results: mx.google.com; dkim=pass header.i=@t-8ch.de header.s=mail header.b=XnQLs3DJ; spf=pass (google.com: domain of linux-kernel+bounces-1283-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.199.223 as permitted sender) smtp.mailfrom="linux-kernel+bounces-1283-linux.lists.archive=gmail.com@vger.kernel.org" Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ny.mirrors.kernel.org (Postfix) with ESMTPS id 967121C2392A for ; Fri, 15 Dec 2023 16:20:55 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 47B6D3BB30; Fri, 15 Dec 2023 16:20:47 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=t-8ch.de header.i=@t-8ch.de header.b="XnQLs3DJ" X-Original-To: linux-kernel@vger.kernel.org Received: from todd.t-8ch.de (todd.t-8ch.de [159.69.126.157]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 0CA17381C8; Fri, 15 Dec 2023 16:20:42 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=t-8ch.de Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=t-8ch.de DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=t-8ch.de; s=mail; t=1702657234; bh=gxIU+Cnud2j3bNARAoIX3HgvhIYjXRvzI1SwQ9YSFug=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=XnQLs3DJk/8GvBEHSCEaONRRri1iImcp2JcuA3XM2XBIc6Xz+GTX00I+ZlGIyYmXE +k/eelNYt3bph8Mmnfr1FugHH3LeLbjYWVapfKVOnpmK2EZloshTt1MiLg393eYSUn CqLW+LvMLunnQf7VeHExvdKJQ+AZwXQsTJkNc+5c= Date: Fri, 15 Dec 2023 17:20:32 +0100 From: Thomas =?utf-8?Q?Wei=C3=9Fschuh?= To: Srinivas Pandruvada Cc: jikos@kernel.org, jic23@kernel.org, lars@metafoo.de, Basavaraj.Natikar@amd.com, linux-input@vger.kernel.org, linux-iio@vger.kernel.org, linux-kernel@vger.kernel.org, stable@vger.kernel.org Subject: Re: [PATCH] iio: light: hid-sensor-als: Avoid failure for chromaticity support Message-ID: <9be8369c-4e23-4fa0-bc26-b236de669c8c@t-8ch.de> References: <20231215160159.648963-1-srinivas.pandruvada@linux.intel.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <20231215160159.648963-1-srinivas.pandruvada@linux.intel.com> On 2023-12-15 08:01:59-0800, Srinivas Pandruvada wrote: > With the commit ee3710f39f9d ("iio: hid-sensor-als: Add light chromaticity > support"), there is an assumption that the every HID ALS descriptor has > support of usage ids for chromaticity support. If they are not present, > probe fails for the driver . This breaks ALS functionality on majority of > platforms. > > It is possible that chromaticity usage ids are not present. When not > present, restrict number of IIO channels to not include support for > chromaticity and continue. > > Fixes: ee3710f39f9d ("iio: hid-sensor-als: Add light chromaticity support") > Reported-by: Thomas Weißschuh > Closes: https://bugzilla.kernel.org/show_bug.cgi?id=218223 > Signed-off-by: Srinivas Pandruvada > Cc: stable@vger.kernel.org > --- > drivers/iio/light/hid-sensor-als.c | 24 ++++++++++++++++-------- > 1 file changed, 16 insertions(+), 8 deletions(-) Thanks! Tested-by: Thomas Weißschuh # on Framework 13 AMD