Open clystron opened 5 years ago
Almost forgot:
I can load the module manually with modprobe and everything works fine but that should not be required with devicetree.
The failure to load the abx80x module is raised by upstream commit af503716ac1444db61d80cb6d17cfe62929c21df. The commit message asserts that no in-kernel drivers should be adversely affected by the change, but you appear to have found a counter-example. Personally, I think the fact that each driver has to register i2c:
and of:
aliases is ugly - the matter should have been handled in the I2C framework - but that's where we are. A quick glance suggests the problem still exists in the 5.2 kernel.
A bit of scripted greping says the following drivers are also affected:
a8293
ad714x_i2c
af9033
arizona_i2c
at24
au8522_decoder
cs53l32a
cx25840
cxd2099
cxd2820r
ds1621
ds2482
dvb_pll
e4000
edt_ft5x06
fc2580
goodix
hdc100x
helene
jc42
lgdt330x
m88rs6000t
mcp3422
mn88472
mn88473
msp3400
mt2060
mt9v011
mxl301rf
ov7640
pwm_pca9685
qm1d1b0004
qm1d1c0042
radio_si470x_i2c
radio_tea5764
rtc_fm3130
rtc_m41t80
rtc_max6900
rtc_pcf8563
rtc_pcf8583
rtc_x1205
s2250
saa7115
saa7706h
sc16is7xx
sht21
sht3x
shtc1
si2157
si2165
snd_soc_adau1701
snd_soc_adau1977_i2c
sony_btf_mpx
sp2
ssd1307fb
tc90522
tda10071
tda18212
tda18250
tef6862
ts2020
tsl4531
tua9001
tuner
tw2804
tw9903
tw9906
uda1342
veml6070
wl1273_core
wm8775
Of those, only 7 are currently used by overlays:
ds1621
goodix
hdc100x
mcp3422
sht3x
tsl4531
veml6070
The quick fix is to revert the offending patch - it does revert cleanly - but ultimately either the abx80x driver has to advertise of:
aliases or the I2C framework has to be enhanced to take care of it.
Do you have any suggestions or comments, @martinezjavier?
@pelwell I think that the correct fix is to add a proper OF device ID table to the abx80x driver.
I just saw that my original post did not show the real MODALIAS, this is how it looks exactly:
MODALIAS=of:N<NULL>T<NULL>Cabracon,abx80x
Does that look like a "good" OF alias? The NULLs do seem strange to me...
It does look strange, but that's how all OF aliases turn out - it's nothing to be concerned about.
This issue (or a similar one) also affects the cs4271, used by the SuperAudioBoard overlay. Do codecs with a SPI bus driver also have the same issue, or is that handled differently?
Yes, this issue also affects other codecs. There is more discussion and a proposed fix in https://github.com/raspberrypi/linux/issues/3061. SPI could potentially have the same problem, although the framework isn't currently forcing the use of "of:" aliases, but if it did the same patch to i2cprobe will fix it.
The SuperAudioBoard uses I2C not SPI. The proposed fix repairs the problem with my spin off of the SuperAudioBoard which uses the SuperAudioboard overlay.
Describe the bug I have been using the i2c-rtc overlay with an ab1805 RTC ("dtoverlay=i2c-rtc,abx80x"), after upgrading the kernel from 4.14 (raspberrypi-kernel=1.20190401-1) to 4.19 (raspberrypi-kernel=1.20190517-1) the module for the RTC does not get loaded any more. It looks like something is up with the MODALIAS and therefor the module is not found, see below for an output of udevadm monitor -p -k -u when manually loading the overlay for both kernels
Expected behaviour (Kernel 4.14)
Actual behaviour (Kernel 4.19)
System Pi3B