Re: [PATCH 05/12] net: dsa: ocelot: drop of_match_ptr for ID table

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Sat, Mar 11, 2023 at 06:32:56PM +0100, Krzysztof Kozlowski wrote:
> The driver can match only via the DT table so the table should be always
> used and the of_match_ptr does not have any sense (this also allows ACPI
> matching via PRP0001, even though it might not be relevant here).
> 
>   drivers/net/dsa/ocelot/ocelot_ext.c:143:34: error: ‘ocelot_ext_switch_of_match’ defined but not used [-Werror=unused-const-variable=]
> 
> Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@xxxxxxxxxx>
> ---
>  drivers/net/dsa/ocelot/ocelot_ext.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/net/dsa/ocelot/ocelot_ext.c b/drivers/net/dsa/ocelot/ocelot_ext.c
> index 063150659816..228737a32080 100644
> --- a/drivers/net/dsa/ocelot/ocelot_ext.c
> +++ b/drivers/net/dsa/ocelot/ocelot_ext.c
> @@ -149,7 +149,7 @@ MODULE_DEVICE_TABLE(of, ocelot_ext_switch_of_match);
>  static struct platform_driver ocelot_ext_switch_driver = {
>  	.driver = {
>  		.name = "ocelot-ext-switch",
> -		.of_match_table = of_match_ptr(ocelot_ext_switch_of_match),
> +		.of_match_table = ocelot_ext_switch_of_match,
>  	},
>  	.probe = ocelot_ext_probe,
>  	.remove = ocelot_ext_remove,
> -- 
> 2.34.1
> 

Acked-by: Colin Foster <colin.foster@xxxxxxxxxxxxxxxx>



[Index of Archives]     [Linux NFS]     [Linux NILFS]     [Linux USB Devel]     [Linux Audio Users]     [Photo]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux