From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail.kernel.org ([198.145.29.99]:34716 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752441AbeD2F1V (ORCPT ); Sun, 29 Apr 2018 01:27:21 -0400 Date: Sun, 29 Apr 2018 07:27:04 +0200 From: Greg KH To: John Smith Cc: stable@vger.kernel.org Subject: Re: [PATCH 3.18 18/52] HID: i2c-hid: fix size check and type usage Message-ID: <20180429052704.GD24294@kroah.com> References: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: Sender: stable-owner@vger.kernel.org List-ID: On Sat, Apr 28, 2018 at 11:09:00PM +0200, John Smith wrote: > > - 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) Does this happen in newer kernels as well? Is there a patch there that I need to just backport to 3.18.y to remove this "noise"? thanks, greg k-h