diff options
author | nsouch <nsouch@FreeBSD.org> | 1999-01-09 18:08:24 +0000 |
---|---|---|
committer | nsouch <nsouch@FreeBSD.org> | 1999-01-09 18:08:24 +0000 |
commit | e670443158fa0f8567cc666000f1cf5819c156ca (patch) | |
tree | dc9371aa53218a6e6b09f54a5dd8c837e4342de9 /sys/dev/smbus/smb.h | |
parent | 674988520c88d8bdd31977e29964f169a47a72b1 (diff) | |
download | FreeBSD-src-e670443158fa0f8567cc666000f1cf5819c156ca.zip FreeBSD-src-e670443158fa0f8567cc666000f1cf5819c156ca.tar.gz |
Change /dev/smb and /dev/iic interface to allow user programs to interact with
devices dynamically. That means,
+ only one /dev/iic or /dev/smb device for each smb/iic bus to access
+ I2C/SMB device address must be given to any ioctl
+ new devices may be plugged and accessed after boot, which was
impossible previously (device addresses were hardcoded into
the kernel)
Diffstat (limited to 'sys/dev/smbus/smb.h')
-rw-r--r-- | sys/dev/smbus/smb.h | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/sys/dev/smbus/smb.h b/sys/dev/smbus/smb.h index 1338a15..e0ebef8 100644 --- a/sys/dev/smbus/smb.h +++ b/sys/dev/smbus/smb.h @@ -23,7 +23,7 @@ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. * - * $Id: smb.h,v 1.1 1998/08/13 17:13:20 son Exp $ + * $Id: smb.h,v 1.1 1998/09/03 21:00:08 nsouch Exp $ * */ #ifndef __SMB_H @@ -34,6 +34,7 @@ struct smbcmd { char cmd; int count; + u_char slave; union { char byte; short word; @@ -48,8 +49,8 @@ struct smbcmd { } data; }; -#define SMB_QUICK_WRITE _IO('i', 1) -#define SMB_QUICK_READ _IO('i', 2) +#define SMB_QUICK_WRITE _IOW('i', 1, struct smbcmd) +#define SMB_QUICK_READ _IOW('i', 2, struct smbcmd) #define SMB_SENDB _IOW('i', 3, struct smbcmd) #define SMB_RECVB _IOW('i', 4, struct smbcmd) #define SMB_WRITEB _IOW('i', 5, struct smbcmd) |