Re: [PATCH v2] i2c: add EFI i2c master driver

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

 



On Thu, Apr 04, 2024 at 07:28:46AM +0200, Tomas Marek wrote:
> Hi Sascha,
> 
> Thank you.
> 
> On Wed, Apr 03, 2024 at 02:13:59PM +0200, Sascha Hauer wrote:
> > Hi Tomas,
> > 
> > Thanks for the patch. I applied it with some minor adjustments.
> > 
> > On Wed, Apr 03, 2024 at 09:49:09AM +0200, Tomas Marek wrote:
> > > +static void i2c_msg_to_efi_op(
> > > +	const struct efi_i2c_priv *i2c_priv,
> > > +	const struct i2c_msg *msg,
> > > +	struct efi_i2c_operation **op)
> > 
> > No need to pass a pointer to a pointer to the array, changed that to
> > *op.
> 
> I'm afraid this won't work. The **op was an in/out pointer to the EFI
> request operation array. The incremented pointer value was used by
> subsequent calls to i2c_msg_to_efi_op(). If a pointer is used instead
> of a pointer to a pointer, the op variable in the
> i2c_msgs_to_efi_transaction() function isn't modified, and all I2C
> messages are now stored in the first item of the EFI operations array.

Ah, alright, now I understand the code. I reverted back to your original
version.

Sascha

-- 
Pengutronix e.K.                           |                             |
Steuerwalder Str. 21                       | http://www.pengutronix.de/  |
31137 Hildesheim, Germany                  | Phone: +49-5121-206917-0    |
Amtsgericht Hildesheim, HRA 2686           | Fax:   +49-5121-206917-5555 |




[Index of Archives]     [Linux Embedded]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [XFree86]

  Powered by Linux