Received: by 2002:a05:7208:9594:b0:7e:5202:c8b4 with SMTP id gs20csp1518896rbb; Mon, 26 Feb 2024 11:52:12 -0800 (PST) X-Forwarded-Encrypted: i=3; AJvYcCVni7UmxGBwD5cL8/7mVjGPMDmWdYjmMUAcqk1/oRKFFnIyZMn1TIZlclZLVrXMdA8Yy7aIxGNDPiVHbIgKstEVdmFEdv8OmyYm2O8gvw== X-Google-Smtp-Source: AGHT+IExkwL4jY/q/LkT1cElCgleS7AHNw8R6UtrYZ5OztLWKdH1xv7W7Jq4B8mVCJD1MYNiVNlK X-Received: by 2002:a9d:7a43:0:b0:6e4:7762:bff with SMTP id z3-20020a9d7a43000000b006e477620bffmr10290521otm.34.1708977132449; Mon, 26 Feb 2024 11:52:12 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1708977132; cv=pass; d=google.com; s=arc-20160816; b=XoLSvl/nc01IKSXpHMLeWeTY5rI4AM8tZn408wlYyaoiBBeH50fJEhTqiGp51vgoRb DH13TgSpuHr8UJ7scmQcwy+SK/JE0NeWdlxTtcTw30+4b2XQJVOBXU6TVDDNcQGhIEUg ct7a9qf0Hs8IOOn6vJLNup2EhFbPH+6IaBa2dtWxhPbqSFMC+5z/iaCG7scx6ldY6Uei 8XP+3FNz4QPPx+h3BazyJZe1oIzuPn5+Ofyf8murk/pQNwFNvOextzjoi2L7Ny5VGAY7 FaquwjrDvtqp+AO0o9IyBs0ptWB0DYKbKdaDVCFma2pT0KnOC1meTwY05NUYi7xo47xM +VdA== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:references:in-reply-to:message-id :subject:cc:to:from:date:dkim-signature; bh=nzfi9bWz7OAKO9s5F5IxOOUG36RWhDBD5bflzub6j7s=; fh=JCPD7odN6IIhVKlYW7jnfqSjXSds8MuNuW1WhmI9V9s=; b=q3TO8ptHrdKxo7Ai+Tryf+kHo8oHGsbQKHN7rJPwgIdQIxCCRFMusHleipLj5KI0Ld 5YMsdiZaWGgJlYsw5Q2KbkI2ru/j88WgM6g76YVHwLk6WoadzhiwqS3ZZO3QQCautrwL LQ9FXTSD04cOnzHkhCeoEBo6x7MKeIDij0T0y+94YGVSPr8m2K7YDt6s/0qm7yrFLh4z j9kQKJcm/BMrFfQWBdpRoW0bA86/NeGHBwh31LpZ++pTGhoK6N3akkzjBscbQmCy954H f6ptOFvRZX9dqag4mOqcAse9PdavIrtqEmnXC/16vW9EI4ia6cnbxrSZjzTJ6sIFLGjr onSQ==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=lrxavY2O; arc=pass (i=1 dkim=pass dkdomain=kernel.org); spf=pass (google.com: domain of linux-kernel+bounces-82239-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.48.161 as permitted sender) smtp.mailfrom="linux-kernel+bounces-82239-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from sy.mirrors.kernel.org (sy.mirrors.kernel.org. [147.75.48.161]) by mx.google.com with ESMTPS id h10-20020a056a00230a00b006e4827e6fe6si4261005pfh.136.2024.02.26.11.52.11 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 26 Feb 2024 11:52:12 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-82239-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.48.161 as permitted sender) client-ip=147.75.48.161; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=lrxavY2O; arc=pass (i=1 dkim=pass dkdomain=kernel.org); spf=pass (google.com: domain of linux-kernel+bounces-82239-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.48.161 as permitted sender) smtp.mailfrom="linux-kernel+bounces-82239-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=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 sy.mirrors.kernel.org (Postfix) with ESMTPS id 17E98B255EF for ; Mon, 26 Feb 2024 19:27:34 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id A3DBF12FF65; Mon, 26 Feb 2024 19:27:28 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="lrxavY2O" Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (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 BDAED12F5A4; Mon, 26 Feb 2024 19:27:27 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1708975647; cv=none; b=YWw04rN75topSTo7swK7T24LdHzv83ZXigMSQPIR2TH9pL50gyvSczqjYTI0gfBkDl+mbt/OC8KGsi83Skwg7O1TLhxfDatY4wGNzLbOtKnsbN/7imu4JVglbKmDVp6tG9bpsvgIDJ+4/VlvyquAYYra8zd05w0Dt3mLt39ZYHE= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1708975647; c=relaxed/simple; bh=aJbYoUvl3lfn7Y5sMCUZh5e5qg+OrgmfaaR50t0lkJQ=; h=Date:From:To:Cc:Subject:Message-ID:In-Reply-To:References: MIME-Version:Content-Type; b=W/eK1cCqflsfzGl4LOlsBnM3Q57oc96LKPQ+e0gN/jyr/vpLExE4JzHu3p7Nx+URLjFfT9qlNqCDTamH8KmNwhRr/0CRpJJX2fS6umC89YWPDc8hk5iymAF6Jm4y0b46oKhYrPAF72jwsICj45dJzm7/PFBdhMZMKEJNcM8ke4s= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=lrxavY2O; arc=none smtp.client-ip=10.30.226.201 Received: by smtp.kernel.org (Postfix) with ESMTPSA id 5D891C433F1; Mon, 26 Feb 2024 19:27:23 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1708975647; bh=aJbYoUvl3lfn7Y5sMCUZh5e5qg+OrgmfaaR50t0lkJQ=; h=Date:From:To:Cc:Subject:In-Reply-To:References:From; b=lrxavY2Owp9oUSCoyyk7c/jH+HbEE7iLdJMWXEjCj8Iz8OrkGd21LKCfDiWtbksUn eSvBJf0UL3HTBonJ+o2BzGVV1ktYQr4FxRcBtJfuPsc/UYTYheo/M3eafrSsTdzJEK 6oRw7QJhT+D44GIXlXs7As7ovpSx6kHGaPgQPzB/qu5ymbKREirSosOsT9cMOcIKdJ H0VKJiefYNPBcuzHs2OWI35jRe+b2aCOweOAHMLVFDcc0caPndshNvFGFXiWzmRjoA FXB6lFzXyxxyxoWI1KQhBBT6iCHW1Ba/Je1/euDHbsd9+NwFwZY/qZJGMssborKpBx 2qiDHHNtLcFgA== Date: Mon, 26 Feb 2024 19:27:11 +0000 From: Jonathan Cameron To: Krzysztof Kozlowski Cc: Lars-Peter Clausen , Michael Hennerich , Nathan Chancellor , Nick Desaulniers , Bill Wendling , Justin Stitt , linux-iio@vger.kernel.org, linux-kernel@vger.kernel.org, llvm@lists.linux.dev Subject: Re: [PATCH v2 2/2] iio: proximity: isl29501: make use of of_device_id table Message-ID: <20240226192711.1da77a05@jic23-huawei> In-Reply-To: <20240225201654.49450-2-krzysztof.kozlowski@linaro.org> References: <20240225201654.49450-1-krzysztof.kozlowski@linaro.org> <20240225201654.49450-2-krzysztof.kozlowski@linaro.org> X-Mailer: Claws Mail 4.2.0 (GTK 3.24.41; x86_64-pc-linux-gnu) 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=US-ASCII Content-Transfer-Encoding: 7bit On Sun, 25 Feb 2024 21:16:54 +0100 Krzysztof Kozlowski wrote: > Reference the of_device_id table in the driver structure, so it will be > used for module autoloading and device matching. This fixes clang W=1 > warning: > > isl29501.c:999:34: error: unused variable 'isl29501_i2c_matches' [-Werror,-Wunused-const-variable] > > Signed-off-by: Krzysztof Kozlowski Applied just patch 2. Thanks, Jonathan > > --- > > Rework according to comments. > > An old v1: > https://lore.kernel.org/all/20230810111933.205619-1-krzysztof.kozlowski@linaro.org/ > --- > drivers/iio/proximity/isl29501.c | 3 +-- > 1 file changed, 1 insertion(+), 2 deletions(-) > > diff --git a/drivers/iio/proximity/isl29501.c b/drivers/iio/proximity/isl29501.c > index bcebacaf3dab..4982686fb4c3 100644 > --- a/drivers/iio/proximity/isl29501.c > +++ b/drivers/iio/proximity/isl29501.c > @@ -995,17 +995,16 @@ static const struct i2c_device_id isl29501_id[] = { > > MODULE_DEVICE_TABLE(i2c, isl29501_id); > > -#if defined(CONFIG_OF) > static const struct of_device_id isl29501_i2c_matches[] = { > { .compatible = "renesas,isl29501" }, > { } > }; > MODULE_DEVICE_TABLE(of, isl29501_i2c_matches); > -#endif > > static struct i2c_driver isl29501_driver = { > .driver = { > .name = "isl29501", > + .of_match_table = isl29501_i2c_matches, > }, > .id_table = isl29501_id, > .probe = isl29501_probe,