Source-Changes archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
CVS commit: src/sys/dev/pci
Module Name: src
Committed By: brad
Date: Wed Nov 26 21:21:09 UTC 2025
Modified Files:
src/sys/dev/pci: piixpm.c
Log Message:
piixpm(4) has iic(4) behavior and will respond to drivers trying to
see if indirect match and attach works.
However, it had an aggressive panic in its piixpm_i2c_exec() function
if there existed a command but not any data. Turn this into a
return(EINVAL) sort of thing. Without this, just modloading aht20temp
will panic a NetBSD/amd64 Virtualbox VM.
It is very common for I2C devices, especially sensor devices, to do a
READ (with or without STOP) with just a command sent, wait a while and
then do a WRITE or more READ without a command and with a data buffer.
Often the device has to have this pause in order to perform some
action.
I don't have the datasheet on the piixpm(4) chip available to me, and
it is possible that it can handle a command without data. The
interrupt function implies as much, but for now, just EINVAL the
situation.
It would have also been trivial to panic the system from userland by
opening the iic device and performing ioctl calls and it would be best
to not allow that.
To generate a diff of this commit:
cvs rdiff -u -r1.73 -r1.74 src/sys/dev/pci/piixpm.c
Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.
Home |
Main Index |
Thread Index |
Old Index