]> git.baikalelectronics.ru Git - kernel.git/commit
rndis_host: set proper input size for OID_GEN_PHYSICAL_MEDIUM request
authorAndrey Zhizhikin <andrey.zhizhikin@leica-geosystems.com>
Fri, 8 Jan 2021 09:58:39 +0000 (09:58 +0000)
committerJakub Kicinski <kuba@kernel.org>
Tue, 12 Jan 2021 01:54:40 +0000 (17:54 -0800)
commit7796eb8d40db0018e20e07e3332e3f87eee87ffb
tree584128295d53e812a7cb9158b9c9434893f2864a
parent1266addb91d754cebc5c87ce2f2b17da09fd6b5c
rndis_host: set proper input size for OID_GEN_PHYSICAL_MEDIUM request

MSFT ActiveSync implementation requires that the size of the response for
incoming query is to be provided in the request input length. Failure to
set the input size proper results in failed request transfer, where the
ActiveSync counterpart reports the NDIS_STATUS_INVALID_LENGTH (0xC0010014L)
error.

Set the input size for OID_GEN_PHYSICAL_MEDIUM query to the expected size
of the response in order for the ActiveSync to properly respond to the
request.

Fixes: 5c4466b14caa ("rndis_host: Add RNDIS physical medium checking into generic_rndis_bind()")
Signed-off-by: Andrey Zhizhikin <andrey.zhizhikin@leica-geosystems.com>
Link: https://lore.kernel.org/r/20210108095839.3335-1-andrey.zhizhikin@leica-geosystems.com
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
drivers/net/usb/rndis_host.c