update SMB_BWRITE documentation, clarify SMB_BREAD
After removal of SMB_TRANS some information in the description of SMB_BWRITE has become stale. E.g., the maximum block size has been restored to 32. Also, the descriptions of SMB_BREAD and SMB_BWRITE had some incorrect information on the SMBus protocol details. MFC after: 1 week X-MFC with: r308242 Differential Revision: https://reviews.freebsd.org/D8431
This commit is contained in:
parent
87acb7f815
commit
f1cd40a19d
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=308532
@ -141,26 +141,25 @@ in
|
|||||||
.Em BlockWrite
|
.Em BlockWrite
|
||||||
first sends the byte from
|
first sends the byte from
|
||||||
.Fa cmd
|
.Fa cmd
|
||||||
to the device, followed by
|
to the device, then the byte from
|
||||||
|
.Fa wcount
|
||||||
|
followed by
|
||||||
.Fa wcount
|
.Fa wcount
|
||||||
bytes of data that are taken from the buffer pointed to by
|
bytes of data that are taken from the buffer pointed to by
|
||||||
.Fa wbuf .
|
.Fa wbuf .
|
||||||
The SMBus specification mandates that no more than 32 bytes of
|
The SMBus specification mandates that no more than 32 bytes of
|
||||||
data can be transferred in a single block read or write command,
|
data can be transferred in a single block read or write command.
|
||||||
but since
|
|
||||||
.Xr smbus 4
|
|
||||||
is also used to access I2C devices, the limit has been increased
|
|
||||||
to 1024.
|
|
||||||
This value can be read from the constant
|
This value can be read from the constant
|
||||||
.Dv SMB_MAXBLOCKSIZE .
|
.Dv SMB_MAXBLOCKSIZE .
|
||||||
.It Dv SMB_BREAD Ta
|
.It Dv SMB_BREAD Ta
|
||||||
.Em BlockRead
|
.Em BlockRead
|
||||||
first sends the byte from
|
first sends the byte from
|
||||||
.Fa cmd
|
.Fa cmd
|
||||||
to the device, then reads
|
to the device, then reads a count of data bytes that the device
|
||||||
.Fa rcount
|
is going to provide and then reads that many bytes.
|
||||||
bytes of data that from the device.
|
The count is returned in
|
||||||
This data is returned in the buffer pointed to by
|
.Fa rcount.
|
||||||
|
The data is returned in the buffer pointed to by
|
||||||
.Fa rbuf .
|
.Fa rbuf .
|
||||||
.El
|
.El
|
||||||
.Pp
|
.Pp
|
||||||
|
Loading…
Reference in New Issue
Block a user