Received: by 10.192.165.148 with SMTP id m20csp2183908imm; Sat, 28 Apr 2018 14:31:51 -0700 (PDT) X-Google-Smtp-Source: AB8JxZoA1epVac9yy3M39ARoM2+Xnc3WzUyTCQINyUFlB0kk8cs4D36CTHEVmXf7/VFQGph2k9tj X-Received: by 2002:a63:925c:: with SMTP id s28-v6mr6015046pgn.368.1524951110961; Sat, 28 Apr 2018 14:31:50 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1524951110; cv=none; d=google.com; s=arc-20160816; b=BrRDFRsXCheRYhfrjWecxYWip6dgWudV+ZulwCyuue28LWNRhyiebOanymD5wSaEl1 lm6Y/dbLU3n9ymYqbOXeoiadRaBF4j/SX1+Rk/U6vTO6UhrunRBVtfrOnLYHG82s5jrX 9hv/koc8+e05oJjZYr63q5nuEn+QxhiHAexGi68BGXmYafsN/OhoauMCBrgXHygeZjmV fABsu2vvkBXXKEO3dhZGs8ER8+XU23uP1vPQSq3L0a0qD6qvxyeLtURGBdLphhP2gKc5 y2L7BD+Ady8be/up00Xeza+L69FGtwUzJyxwJqyewiYQ5lIOWn9CPIDJiSp2G3rK+uzN 2VnA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:sensitivity:importance:date :subject:to:from:message-id:mime-version:arc-authentication-results; bh=t/vVHAdI+v2i5k28+85H8Qsye5R+T9+E73UGCgyMWkg=; b=J0iDxDlprFpla/1wOPX0q/T2V0crJImuTp5bCmD3sAr6sJhV8ELYcW8ZnuQ8JAkvtJ WZl2Cp5BMLTlkGiXtqMkpAIq4Nq0MkNZjydMqeLLef5RyjzPeiMwBEbJAFT+9SFiwBXC 6x3R/D80tcqlcNgzbtgqRzdvwS/rWjelCpDiNIeojy/eQFxLCy5WInl8vSehNhy9Vc96 aIuIhcNy9BedM1sH1aQlZJnv3hsR9y1SEa3xH+dFUu6j/uqI4QpD0CO1hiDbQgnYTNNE PArGmMGcyUQzs0kjWSevLyJTN0cWdpgaYh/7880cZjLgUtsex+CZbB5LdDjGgz+qzEMp 0//Q== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id j91-v6si4268244pld.14.2018.04.28.14.31.36; Sat, 28 Apr 2018 14:31:50 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751974AbeD1Vac (ORCPT + 99 others); Sat, 28 Apr 2018 17:30:32 -0400 Received: from mout.gmx.net ([212.227.17.21]:35447 "EHLO mout.gmx.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751151AbeD1Vab (ORCPT ); Sat, 28 Apr 2018 17:30:31 -0400 Received: from [46.94.155.166] ([46.94.155.166]) by 3c-app-gmx-bs73.server.lan (via HTTP); Sat, 28 Apr 2018 23:30:29 +0200 MIME-Version: 1.0 Message-ID: From: "John Smith" To: linux-kernel@vger.kernel.org Subject: Re: [PATCH 3.18 18/52] HID: i2c-hid: fix size check and type usage Content-Type: text/plain; charset=UTF-8 Date: Sat, 28 Apr 2018 23:30:29 +0200 Importance: normal Sensitivity: Normal References: X-UI-Message-Type: mail X-Priority: 3 X-Provags-ID: V03:K1:Nc74xovWl5r4cXaAlZPIul9kAapsNt1obQ5eOqFk88G njXCYnyp1l2Dh1pMP2uE2C0Z/0HaznbwY7k+PO+9e/qMHVl72w cySaG06N6hwjejKuh6cP/40zU+ygQoAnJ4s/j/4d2I7LkJY8zg y87FWIFmulctxuwnTdtcPjO2s7vf7a1m+SKd/uyn+EBjr8oa7/ WzWb5N9daU8HDp8zDy3bp7xptAN8cz8R1/ckwo0EhzmeAZktR/ eT6j/G+gNBGj4CKDixRKwR4afls9a6Zvx/vZEqMJ2vqIa86Olv JRioyk= X-UI-Out-Filterresults: notjunk:1;V01:K0:6aOZK9UNsyM=:RxjnPZgs2Gk+5DTcxUDoe+ YCHK/HO+JmZu3RNFze/PPnDq+L2jloUpOfoOFllmcX2uruFVUUn+9rIGbD2ZVi479z2ODv3pS HB6KrnFfaNZa4a6QYS87rBCKD7ZoPkXvWCRYh+tlTqXXgt/7SFF6hgWeIrOpQm+c4F5CZVRcy nBp1XzTVZzupdMmJLdg6bunIxiMrLwTPGMyRiZLiFSCH38a3DmfdHmcMCOV61rCNoj4arsNEJ EplvyIszJH7mQpSiiSPBcFCLZeVYZh2S5UOc0TnI8UTgEpqJvo54LrFv1dW/e9zAXUeRTF7la CfnImZdN/qxChRZQX31iWV9AKWlfJmrMavc+yEC4Qpcv/kVtpHTakh06jLCPXyYgKAaTJraoi imwecAcMQD9X0zKvyfxMyFnqiZ04Q+BivMd+tioWlxbn5LtNv/LwpVmDKdWGu1kP2IM60C+fO dP+l8prKk/z1Hr0/tZYPJkhSpKso+hY9wdywuChDu4UxFr1Umswc Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org > - if (ret_size > size) { > + if ((ret_size > size) || (ret_size <= 2)) { > dev_err(&ihid->client->dev, "%s: incomplete report (%d/%d)\n", > __func__, size, ret_size); > return; This change spams in the dmesg output. Could you please undo this change? Or - if ((ret_size > size) || (ret_size <= 2)) { + if ((ret_size > size) || (ret_size < 2)) { $ dmesg [ 1781.266353] i2c_hid i2c-ALP0017:00: i2c_hid_get_input: incomplete report (30/2) [ 1781.273898] i2c_hid i2c-ALP0017:00: i2c_hid_get_input: incomplete report (30/2) [ 1781.281464] i2c_hid i2c-ALP0017:00: i2c_hid_get_input: incomplete report (30/2) [ 1781.289064] i2c_hid i2c-ALP0017:00: i2c_hid_get_input: incomplete report (30/2) [ 1781.296607] i2c_hid i2c-ALP0017:00: i2c_hid_get_input: incomplete report (30/2) [ 1781.304131] i2c_hid i2c-ALP0017:00: i2c_hid_get_input: incomplete report (30/2) [ 1781.311751] i2c_hid i2c-ALP0017:00: i2c_hid_get_input: incomplete report (30/2) [ 1781.319315] i2c_hid i2c-ALP0017:00: i2c_hid_get_input: incomplete report (30/2) [ 1781.326882] i2c_hid i2c-ALP0017:00: i2c_hid_get_input: incomplete report (30/2)