Re: [PATCH v5 4/5] iio: amplifiers: hmc425a: use pointers in match table

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

 



On Tue, 2024-02-20 at 17:34 +0200, Dumitru Ceclan wrote:
> Change the match table to use pointers instead of device ids.
> Remove type from state as it is not used anymore.
> 
> Signed-off-by: Dumitru Ceclan <mitrutzceclan@xxxxxxxxx>
> ---

One comment (Jonathan might be able to address that while applying)... With that:

Reviewed-by: Nuno Sa <nuno.sa@xxxxxxxxxx>

>  drivers/iio/amplifiers/hmc425a.c | 29 +++++++++++++++--------------
>  1 file changed, 15 insertions(+), 14 deletions(-)
> 
> diff --git a/drivers/iio/amplifiers/hmc425a.c b/drivers/iio/amplifiers/hmc425a.c
> index 13e018a59637..77872e2dfdfe 100644
> --- a/drivers/iio/amplifiers/hmc425a.c
> +++ b/drivers/iio/amplifiers/hmc425a.c
> @@ -41,15 +41,14 @@ struct hmc425a_chip_info {
>  
>  struct hmc425a_state {
>  	struct	mutex lock; /* protect sensor state */
> -	struct	hmc425a_chip_info *chip_info;
> +	const struct	hmc425a_chip_info *chip_info;

Since you're doing this, I believe you should also constify hmc425a_chip_info_tbl[]
and mention it in the commit message.

- Nuno Sá






[Index of Archives]     [Device Tree Compilter]     [Device Tree Spec]     [Linux Driver Backports]     [Video for Linux]     [Linux USB Devel]     [Linux PCI Devel]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [XFree86]     [Yosemite Backpacking]


  Powered by Linux