linux-stable/include
Miquel Raynal d8e4ebf870
spi: Create a helper to derive adaptive timeouts
Big transfers might take a bit of time, too constraining timeouts might
lead to false positives. In order to simplify the drivers work and with
the goal of factorizing code in mind, let's add a helper that can be
used by any spi controller driver to derive a relevant per-transfer
timeout value.

The logic is simple: we know how much time it would take to transfer a
byte, we can easily derive the total theoretical amount of time involved
for each transfer. We multiply it by two to have a bit of margin and
enforce a minimum of 500ms.

Suggested-by: Mark Brown <broonie@kernel.org>
Signed-off-by: Miquel Raynal <miquel.raynal@bootlin.com>
Link: https://lore.kernel.org/r/Message-Id: <20230622090634.3411468-2-miquel.raynal@bootlin.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
2023-06-22 15:03:18 +01:00
..
acpi
asm-generic Locking changes in v6.4: 2023-05-05 12:56:55 -07:00
clocksource
crypto
drm Merge tag 'drm-misc-fixes-2023-05-11' of git://anongit.freedesktop.org/drm/drm-misc into drm-fixes 2023-05-12 05:32:36 +10:00
dt-bindings - mailbox api: allow direct registration to a channel 2023-05-07 10:17:33 -07:00
keys
kunit
kvm s390: 2023-05-01 12:06:20 -07:00
linux spi: Create a helper to derive adaptive timeouts 2023-06-22 15:03:18 +01:00
math-emu
media media: dvb-core: Fix use-after-free due to race at dvb_register_device() 2023-05-14 06:30:58 +01:00
memory
misc
net ipv6: remove nexthop_fib6_nh_bh() 2023-05-11 18:07:05 -07:00
pcmcia
ras
rdma
rv
scsi Driver core changes for 6.4-rc1 2023-04-27 11:53:57 -07:00
soc Nothing looks out of the ordinary in this batch of clk driver updates. There 2023-04-29 17:29:39 -07:00
sound ASoC: SOF: Intel: hda-mlink: add helper to program SoundWire PCMSyCM registers 2023-05-15 10:20:14 +09:00
target
trace NFSD 6.4 Release Notes 2023-04-29 11:04:14 -07:00
uapi spi: add SPI_MOSI_IDLE_LOW mode bit 2023-05-30 15:20:08 +01:00
ufs scsi: ufs: core: Rename symbol sizeof_utp_transfer_cmd_desc() 2023-05-16 21:07:26 -04:00
vdso
video
xen