blob: 415e9a423c642ddeb842c564f58941974909defc [file] [log] [blame]
b.liue9582032025-04-17 19:18:16 +08001From be9be95ff10e16a5b4ad36f903978d0cc5747024 Mon Sep 17 00:00:00 2001
2From: Felix Fietkau <nbd@nbd.name>
3Date: Fri, 7 Jul 2017 17:04:08 +0200
4Subject: kernel: fix linux/spi/spidev.h portability issues with musl
5
6Felix will try to get this define included into musl
7
8lede-commit: 795e7cf60de19e7a076a46874fab7bb88b43bbff
9Signed-off-by: Felix Fietkau <nbd@nbd.name>
10---
11 include/uapi/linux/spi/spidev.h | 2 +-
12 1 file changed, 1 insertion(+), 1 deletion(-)
13
14--- a/include/uapi/linux/spi/spidev.h
15+++ b/include/uapi/linux/spi/spidev.h
16@@ -117,7 +117,7 @@ struct spi_ioc_transfer {
17
18 /* not all platforms use <asm-generic/ioctl.h> or _IOC_TYPECHECK() ... */
19 #define SPI_MSGSIZE(N) \
20- ((((N)*(sizeof (struct spi_ioc_transfer))) < (1 << _IOC_SIZEBITS)) \
21+ ((((N)*(sizeof (struct spi_ioc_transfer))) < (1 << 13)) \
22 ? ((N)*(sizeof (struct spi_ioc_transfer))) : 0)
23 #define SPI_IOC_MESSAGE(N) _IOW(SPI_IOC_MAGIC, 0, char[SPI_MSGSIZE(N)])
24