On 20/04/23 22:02, Svyatoslav Ryhel wrote:
>>>> ..]
>>>>
>>>>> +static int ssd2825_spi_write(struct udevice *dev, int reg,
>>>>> + const void *buf, int flags)
>>>>> +{
>>>>> + struct spi_slave *slave = dev_get_parent_priv(dev);
>>>>> + u8 command[2];
>>>>> +
>>>>> + if (flags & SSD2825_CMD_SEND) {
>>>>> + command[0] = SSD2825_CMD_MASK;
>>>>> + command[1] = reg;
>>>>> + spi_xfer(slave, 9, &command,
>>>>> + NULL, SPI_XFER_ONCE);
>>>> Please can you use dm_spi_xfer() instead, thoughout?
>>>>
>>> I will replace it, but isn't spi_xfer preferable over dm_spi_xfer?
>>> I remember that I had doubts about which to use.
>> No, we should use the dm variants where available, since then we can
>> drop the old ones.
>>
> I have switched to the dm version and it seems to fit even better, everything
> works perfectly fine.
>
Yes, please switch to dm_spi_xfer() for DM compatible clients.
--
Regards
Vignesh
- [PATCH v1 4/6] video: panel: add Renesas R69328 MIPI D... Svyatoslav Ryhel
- Re: [PATCH v1 4/6] video: panel: add Renesas R693... Simon Glass
- Re: [PATCH v1 4/6] video: panel: add Renesas ... Svyatoslav Ryhel
- Re: [PATCH v1 4/6] video: panel: add Rene... Simon Glass
- Re: [PATCH v1 4/6] video: panel: add ... Svyatoslav Ryhel
- [PATCH v1 2/6] video: bridge: add Solomon SSD2825 DSI/... Svyatoslav Ryhel
- Re: [PATCH v1 2/6] video: bridge: add Solomon SSD... Simon Glass
- Re: [PATCH v1 2/6] video: bridge: add Solomon... Svyatoslav Ryhel
- Re: [PATCH v1 2/6] video: bridge: add Sol... Simon Glass
- Re: [PATCH v1 2/6] video: bridge: add... Svyatoslav Ryhel
- Re: [PATCH v1 2/6] video: bridge... Vignesh Raghavendra
- [PATCH v1 3/6] video: panel: add Renesas R61307 MIPI D... Svyatoslav Ryhel
- [PATCH v1 5/6] video: tegra: add DC based PWM backligh... Svyatoslav Ryhel
- [PATCH v1 6/6] video: panel: add generic endeavoru pan... Svyatoslav Ryhel

