From e671da4acdd29c9d290b76a69525e41f0bea65a4 Mon Sep 17 00:00:00 2001 From: Tapas Dey Date: Wed, 26 Aug 2020 20:13:21 +0530 Subject: [PATCH] NFC: Fix NFC firmware download issue Due to insufficient kernel buffer size, NFC firmware download fails during NFC initialization. Increased kernel buffer size to support frame size of 554 in FW download mode. Change-Id: I1e870389da1221a01b1a785ff1e5b6b175a88117 Signed-off-by: Tapas Dey --- drivers/nfc/qti/nfc_common.h | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/drivers/nfc/qti/nfc_common.h b/drivers/nfc/qti/nfc_common.h index 5478f383c13f..fcba61544fdf 100644 --- a/drivers/nfc/qti/nfc_common.h +++ b/drivers/nfc/qti/nfc_common.h @@ -62,7 +62,12 @@ #define COLD_RESET_OID 0x1E #define MAX_NCI_PAYLOAD_LEN (255) -#define MAX_BUFFER_SIZE (NCI_HDR_LEN + MAX_NCI_PAYLOAD_LEN) +/* + * From MW 11.04 buffer size increased to support + * frame size of 554 in FW download mode + * Frame len(2) + Frame Header(6) + DATA(512) + HASH(32) + CRC(2) + RFU(4) + */ +#define MAX_BUFFER_SIZE (558) // Maximum retry count for standby writes #define MAX_RETRY_COUNT (3)