]> git.ipfire.org Git - thirdparty/kernel/linux.git/commit
ipmi:ssif: Add support for multi-part transmit messages > 2 parts
authorCorey Minyard <cminyard@mvista.com>
Fri, 27 Jul 2018 12:36:20 +0000 (07:36 -0500)
committerCorey Minyard <cminyard@mvista.com>
Tue, 18 Sep 2018 21:18:44 +0000 (16:18 -0500)
commit10042504ed92c06077b8a20a4edd67ba784847d4
tree464e4276ac66aaed576b6e168435d40b5964259e
parentbb9e2eed77a5c7c13ea31b9316776da4f757d150
ipmi:ssif: Add support for multi-part transmit messages > 2 parts

The spec was fairly confusing about how multi-part transmit messages
worked, so the original implementation only added support for two
part messages.  But after talking about it with others and finding
something I missed, I think it makes more sense.

The spec mentions smbus command 8 in a table at the end of the
section on SSIF support as the end transaction.  If that works,
then all is good and as it should be.  However, some implementations
seem to use a middle transaction <32 bytes tomark the end because of the
confusion in the spec, even though that is an SMBus violation if
the number of bytes is zero.

So this change adds some tests, if command=8 works, it uses that,
otherwise if an empty end transaction works, it uses a middle
transaction <32 bytes to mark the end.  If neither works, then
it limits the size to 63 bytes as it is now.

Cc: Harri Hakkarainen <harri@cavium.com>
Cc: Bazhenov, Dmitry <dmitry.bazhenov@auriga.com>
Cc: Mach, Dat <Dat.Mach@cavium.com>
Signed-off-by: Corey Minyard <cminyard@mvista.com>
drivers/char/ipmi/ipmi_ssif.c