Skip to content
This repository has been archived by the owner on Sep 20, 2023. It is now read-only.

sysfs-spi: graceful fallback on unidirectional I/O on buggy driver #271

Closed
maruel opened this issue Aug 8, 2018 · 3 comments
Closed

sysfs-spi: graceful fallback on unidirectional I/O on buggy driver #271

maruel opened this issue Aug 8, 2018 · 3 comments

Comments

@maruel
Copy link
Contributor

maruel commented Aug 8, 2018

I want the sysfs-spi driver to not allocate memory unless explicitly needed.

Based on #264 (comment), the SPI kernel driver for MediaTek MT7688AN CPU is buggy and won't work if no read buffer is provided.

For write-only SPI devices like apa102, there's no read buffer provided when doing the SPI transaction.

That causes a problem, as this means that right now trying to use APA102 on a MT7688AN probably doesn't work. A dummy read buffer should be provided to work around the buggy driver.

The optimal case would be to allocate a dummy buffer, but only when this situation is detected.

Paging @svenschwermer.

@svenschwermer
Copy link
Contributor

@maruel
Copy link
Contributor Author

maruel commented Aug 8, 2018

Ah dang, it never occurred to me that the speed flag could only take effect on a condition, in this case if it were lower than the default speed.

This line implies support for write-only tx.

@maruel
Copy link
Contributor Author

maruel commented Sep 20, 2023

Ported to periph/host#42.

@maruel maruel closed this as completed Sep 20, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants