RE: [PATCH v10 1/2] i2c: i2c-mlxbf: I2C SMBus driver for Mellanox BlueField SoC

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

 



Wolfram,

Thank you for your comments.
Please note that I posted a v11.

> -----Original Message-----
> From: Wolfram Sang <wsa+renesas@xxxxxxxxxxxxxxxxxxxx>
> Sent: Monday, September 21, 2020 3:34 PM
> To: Khalil Blaiech <kblaiech@xxxxxxxxxx>
> Cc: linux-i2c@xxxxxxxxxxxxxxx; Khalil Blaiech <kblaiech@xxxxxxxxxxxx>;
> Vadim Pasternak <vadimp@xxxxxxxxxxxx>
> Subject: Re: [PATCH v10 1/2] i2c: i2c-mlxbf: I2C SMBus driver for Mellanox
> BlueField SoC
> 
> On Mon, Sep 21, 2020 at 11:50:14AM -0400, Khalil Blaiech wrote:
> > From: Khalil Blaiech <kblaiech@xxxxxxxxxxxx>
> >
> > Add BlueField I2C driver to offer master and slave support for
> > Mellanox BlueField SoCs. The driver implements an SMBus adapter
> > and interfaces to multiple busses that can be probed using both
> > ACPI and Device Tree infrastructures.
> >
> > The driver supports several SMBus operations to transfer data
> > back and forth from/to various I2C devices. It is mainly intended
> > to be consumed by userspace tools and utilities, such as i2c-tools
> > and decode-dimms to collect memory module information.
> >
> > On the other hand, the driver has a slave function to support,
> > among others, an IPMB interface that requires both master and
> > slave functions to handle transfers between the BlueField SoC
> > and a board management controllers (e.g., BMC).
> >
> > Signed-off-by: Khalil Blaiech <kblaiech@xxxxxxxxxxxx>
> > Reviewed-by: Vadim Pasternak <vadimp@xxxxxxxxxxxx>
> 
> It still seems nobody has time for even a high level review of this huge
> driver. From a visual glimpse, the driver looks mostly OK to me. It
> probably makes sense to fix issues incrementally from here on.
> 
> So, let's just fix these static analyzer warnings and I'll apply it for
> v5.10.

Sounds good :)

> 
>     CHECKPATCH
> CHECK: struct mutex definition without comment
> #462: FILE: drivers/i2c/busses/i2c-mlxbf.c:372:
> +	struct mutex *lock;

Done.

> 
> WARNING: Prefer 'fallthrough;' over fallthrough comment
> #1330: FILE: drivers/i2c/busses/i2c-mlxbf.c:1240:
> +		/* Fall-through. */
> 

Done.

> WARNING: Prefer 'fallthrough;' over fallthrough comment
> #2000: FILE: drivers/i2c/busses/i2c-mlxbf.c:1910:
> +			/* Fall-through. */
> 

Done.

> 
>     SPARSE
> drivers/i2c/busses/i2c-mlxbf.c:513:16: warning: cast to restricted __be32
> drivers/i2c/busses/i2c-mlxbf.c:513:16: warning: cast to restricted __be32
> drivers/i2c/busses/i2c-mlxbf.c:513:16: warning: cast to restricted __be32
> drivers/i2c/busses/i2c-mlxbf.c:513:16: warning: cast to restricted __be32
> drivers/i2c/busses/i2c-mlxbf.c:513:16: warning: cast to restricted __be32
> drivers/i2c/busses/i2c-mlxbf.c:513:16: warning: cast to restricted __be32

Done.

> drivers/i2c/busses/i2c-mlxbf.c:527:34: warning: incorrect type in argument 3
> (different base types)
> drivers/i2c/busses/i2c-mlxbf.c:527:34:    expected unsigned int [usertype] val
> drivers/i2c/busses/i2c-mlxbf.c:527:34:    got restricted __be32 [usertype]

Done.

> 
> Thanks for your patience!
> 
>    Wolfram

Thanks,
-Khalil





[Index of Archives]     [Linux GPIO]     [Linux SPI]     [Linux Hardward Monitoring]     [LM Sensors]     [Linux USB Devel]     [Linux Media]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux