diff options
author | Johan Hovold <johan@hovoldconsulting.com> | 2015-05-19 11:22:45 +0200 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@google.com> | 2015-05-20 22:52:03 -0700 |
commit | 8e929a8230794c4b034d0f4b658aa03702f3800d (patch) | |
tree | 4bffa1a3165d2dbf654d70796ac7d1da343fe7e0 /drivers/staging/greybus/operation.h | |
parent | c38cf10bbe35ba6fa10437809585fd4d0b3b604d (diff) | |
download | op-kernel-dev-8e929a8230794c4b034d0f4b658aa03702f3800d.zip op-kernel-dev-8e929a8230794c4b034d0f4b658aa03702f3800d.tar.gz |
greybus: core: add lower-limit for host-device buffers
Make sure we never end up with a host device with maximum buffer size
smaller than the shortest Greybus message.
Signed-off-by: Johan Hovold <johan@hovoldconsulting.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@google.com>
Diffstat (limited to 'drivers/staging/greybus/operation.h')
-rw-r--r-- | drivers/staging/greybus/operation.h | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/staging/greybus/operation.h b/drivers/staging/greybus/operation.h index 1edd512..740aacc 100644 --- a/drivers/staging/greybus/operation.h +++ b/drivers/staging/greybus/operation.h @@ -69,6 +69,7 @@ struct gb_operation_msg_hdr { __u8 pad[2]; /* must be zero (ignore when read) */ } __aligned(sizeof(u64)); +#define GB_OPERATION_MESSAGE_SIZE_MIN sizeof(struct gb_operation_msg_hdr) #define GB_OPERATION_MESSAGE_SIZE_MAX U16_MAX /* |