summaryrefslogtreecommitdiff
path: root/include/setjmp.h
diff options
context:
space:
mode:
authorVisa Hankala <visa@cvs.openbsd.org>2022-02-09 07:58:25 +0000
committerVisa Hankala <visa@cvs.openbsd.org>2022-02-09 07:58:25 +0000
commitbadf3c55e7a1fd8f77fbfbe203f5ea736817b677 (patch)
treee3b600ddd4503f232ae79414998e2dc4da89fc8d /include/setjmp.h
parente5a9220c6217b9923c1448c7956d0a6016b5e48c (diff)
Add iic_is_compatible() for matching I2C devices
When using device trees, the ia_name field of struct i2c_attach_args points to the first string of the device node's "compatible" array. However, in many cases it would be preferable to use the last, most general "compatible" entry as a device matching criterion. Enable more flexible device matching by permitting ia_name to point to the raw "compatible" data which is a concatenation of NUL-terminated strings. I2C bus code will supply the data and set ia_name and ia_namelen. I2C device drivers will use iic_is_compatible() to check matches. This method is also backwards compatible with the old, direct use of ia_name. Prompted by a related patch from kettenis@. OK kettenis@
Diffstat (limited to 'include/setjmp.h')
0 files changed, 0 insertions, 0 deletions