From: Sascha Hauer <s.hauer@pengutronix.de>
To: Bo Sun <bo@mboxify.com>
Cc: barebox@lists.infradead.org
Subject: Re: [PATCH 1/1] spi: convert transfer delay to new spi_delay struct
Date: Mon, 30 Jun 2025 10:08:17 +0200 [thread overview]
Message-ID: <aGJF8Ta5BPke9Rqz@pengutronix.de> (raw)
In-Reply-To: <20250627122811.1051283-2-bo@mboxify.com>
Hi,
On Fri, Jun 27, 2025 at 08:28:11PM +0800, Bo Sun wrote:
> Replace the deprecated delay_usecs field with the new spi_delay struct
> in spi_transfer structure. Update spi_transfer_one_message to use
> spi_delay_exec and the mc13xxx driver to use the new structure.
>
> Signed-off-by: Bo Sun <bo@mboxify.com>
> ---
> drivers/mfd/mc13xxx.c | 5 ++++-
> drivers/spi/spi.c | 4 +---
> include/spi/spi.h | 8 ++++----
> 3 files changed, 9 insertions(+), 8 deletions(-)
>
> diff --git a/drivers/mfd/mc13xxx.c b/drivers/mfd/mc13xxx.c
> index 288bd407ff..393f163671 100644
> --- a/drivers/mfd/mc13xxx.c
> +++ b/drivers/mfd/mc13xxx.c
> @@ -84,7 +84,10 @@ static int spi_rw(struct spi_device *spi, void * buf, size_t len)
> .rx_buf = buf,
> .len = len,
> .cs_change = 0,
> - .delay_usecs = 0,
It's initialized to 0, so
if (xfer->delay_usecs)
udelay(xfer->delay_usecs);
will do just nothing.
> + .delay = {
> + .value = 0,
> + .unit = SPI_DELAY_UNIT_USECS,
> + },
I just dropped this and adjusted the commit message accordingly.
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 |
next prev parent reply other threads:[~2025-06-30 8:10 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-06-27 12:28 [PATCH 0/1] " Bo Sun
2025-06-27 12:28 ` [PATCH 1/1] " Bo Sun
2025-06-30 8:06 ` Sascha Hauer
2025-06-30 8:08 ` Sascha Hauer [this message]
2025-06-30 8:38 ` bo
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=aGJF8Ta5BPke9Rqz@pengutronix.de \
--to=s.hauer@pengutronix.de \
--cc=barebox@lists.infradead.org \
--cc=bo@mboxify.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox