Skip to contentSkip to conversation

iio: pressure: sdp500: Add missing select CRC8

PATCH In review Jonathan Cameron 2 participants 4 messages Sep 29, 2024 – Sep 30, 2024 IIO

lore
Share & tools
lore

Jonathan Cameron

author maintainer
#0 lore raw

PATCH 1/1 iio: pressure: sdp500: Add missing select CRC8

From: Jonathan Cameron <[email protected]>

Fix:
sh4-linux-ld: drivers/iio/pressure/sdp500.o: in function `sdp500_probe':

Quoted 1 line
Quoted 1 line

drivers/iio/pressure/sdp500.c:130:(.text+0xe8): undefined reference to `crc8_populate_msb'

sh4-linux-ld: drivers/iio/pressure/sdp500.o: in function `sdp500_read_raw':

Quoted 1 line
Quoted 1 line

drivers/iio/pressure/sdp500.c:74:(.text+0x200): undefined reference to `crc8'

by adding missing select.

---
 drivers/iio/pressure/Kconfig | 1 +
 1 file changed, 1 insertion(+)
drivers/iio/pressure/Kconfig +1 -0
index ce369dbb17fc..df65438c771e 100644
@@ -253,6 +253,7 @@ config MS5637
 config SDP500
 	tristate "Sensirion SDP500 differential pressure sensor I2C driver"
 	depends on I2C
+	select CRC8
 	help
 	  Say Y here to build support for Sensirion SDP500 differential pressure
 	  sensor I2C driver.
Signature · 1 line
2.46.2
author maintainer
#1 lore raw
Quoted 9 lines · On Sun, 29 Sep 2024 18:21:05 +0100 Jonathan Cameron <[email protected]> wrote:

From: Jonathan Cameron <[email protected]>

Fix:

   sh4-linux-ld: drivers/iio/pressure/sdp500.o: in function `sdp500_probe':
Quoted 1 line
Quoted 1 line

drivers/iio/pressure/sdp500.c:130:(.text+0xe8): undefined reference to `crc8_populate_msb'

sh4-linux-ld: drivers/iio/pressure/sdp500.o: in function `sdp500_read_raw':

Quoted 1 line
Quoted 1 line

drivers/iio/pressure/sdp500.c:74:(.text+0x200): undefined reference to `crc8'

by adding missing select.

I've applied this one to the fixes-togreg branch of iio.git so the build issue stops occuring in linux-next.

I'll be rebasing that on rc1 shortly anyway so if anyone wants to review that would be ideal!

Jonathan

Quoted 20 lines
---
 drivers/iio/pressure/Kconfig | 1 +
 1 file changed, 1 insertion(+)
drivers/iio/pressure/Kconfig +1 -0
index ce369dbb17fc..df65438c771e 100644
@@ -253,6 +253,7 @@ config MS5637
 config SDP500
 	tristate "Sensirion SDP500 differential pressure sensor I2C driver"
 	depends on I2C
+	select CRC8
 	help
 	  Say Y here to build support for Sensirion SDP500 differential pressure
 	  sensor I2C driver.
Reviewed-by on v1 1/1
#2 lore raw
In reply to Jonathan Cameron
Quoted 22 lines · Jonathan Cameron

From: Jonathan Cameron <[email protected]>

Fix:

   sh4-linux-ld: drivers/iio/pressure/sdp500.o: in function `sdp500_probe':
Quoted 1 line
Quoted 1 line

drivers/iio/pressure/sdp500.c:130:(.text+0xe8): undefined reference to `crc8_populate_msb'

sh4-linux-ld: drivers/iio/pressure/sdp500.o: in function `sdp500_read_raw':

Quoted 1 line
Quoted 1 line

drivers/iio/pressure/sdp500.c:74:(.text+0x200): undefined reference to `crc8'

by adding missing select.

---
 drivers/iio/pressure/Kconfig | 1 +
 1 file changed, 1 insertion(+)
drivers/iio/pressure/Kconfig +0 -0
index ce369dbb17fc..df65438c771e 100644

drivers/iio/pressure/Kconfig config MS5637 · line 259

Quoted 7 lines
drivers/iio/pressure/Kconfig +1 -0
@@ -253,6 +253,7 @@ config MS5637
 config SDP500
 	tristate "Sensirion SDP500 differential pressure sensor I2C driver"
 	depends on I2C
+	select CRC8
 	help
 	  Say Y here to build support for Sensirion SDP500 differential pressure
 	  sensor I2C driver.

A good example where just including the header is not enough. I bet this is not the first time that something similar happens with CRC8, let alone before sending upstream :)

author maintainer
#3 lore raw
Quoted 18 lines · On Sun, 29 Sep 2024 19:27:43 +0200 Javier Carrasco…
Quoted 17 lines · Jonathan Cameron

From: Jonathan Cameron <[email protected]>

Fix:

   sh4-linux-ld: drivers/iio/pressure/sdp500.o: in function `sdp500_probe':  
Quoted 1 line
Quoted 1 line

drivers/iio/pressure/sdp500.c:130:(.text+0xe8): undefined reference to `crc8_populate_msb'

sh4-linux-ld: drivers/iio/pressure/sdp500.o: in function `sdp500_read_raw':

Quoted 1 line
Quoted 1 line

drivers/iio/pressure/sdp500.c:74:(.text+0x200): undefined reference to `crc8'

by adding missing select.

---
 drivers/iio/pressure/Kconfig | 1 +
 1 file changed, 1 insertion(+)
Quoted 16 lines

drivers/iio/pressure/Kconfig config MS5637 · line 259

Quoted 12 lines
drivers/iio/pressure/Kconfig +1 -0
index ce369dbb17fc..df65438c771e 100644
@@ -253,6 +253,7 @@ config MS5637
 config SDP500
 	tristate "Sensirion SDP500 differential pressure sensor I2C driver"
 	depends on I2C
+	select CRC8
 	help
 	  Say Y here to build support for Sensirion SDP500 differential pressure
 	  sensor I2C driver.  

A good example where just including the header is not enough. I bet this is not the first time that something similar happens with CRC8, let alone before sending upstream :)

Indeed. This is probably about the 5th time it has happened in IIO, yet I still don't remember to check :(

Jonathan

Quoted 2 lines