Received: by 2002:a05:6a10:af89:0:0:0:0 with SMTP id iu9csp3976342pxb; Tue, 25 Jan 2022 00:26:46 -0800 (PST) X-Google-Smtp-Source: ABdhPJx4lXj6M2uI5o6drI3ExE0tRvXtcfNOULa7kCqeeE+AglV404zWsWdBRgYsHmsonp3RV09y X-Received: by 2002:a17:906:2ec8:: with SMTP id s8mr15452285eji.746.1643099206535; Tue, 25 Jan 2022 00:26:46 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1643099206; cv=none; d=google.com; s=arc-20160816; b=vQdIcbaZbVcNILZNUa6WAW8z8GHEiYk2kVHG9fVADVwUxKkR7sbTJlX3Z9Z6kC4zk9 coD7oyO4RC2ooWqPNxvt6g6N5n0yiUYPerZcaljHE9qwCIh8jt04wuAyrcG1uoUNS5wo F4ZutGigDdlyoQ9+8LUK52evcMRiNLgBeVFXw8NKkgaR1whp8IXoK2p5FxsBgrVptsNc 3q3P+9n/MZ7Auy3fgGT1zHDwXvXrJBc2fQ+uySMfCR5blnDh1dw2wqY3B5/rVMs5h+3k 6ufd+902jJg9j13nF1qh2rkwsDUlJO+5rBn1YA7Rx9YTCZti7+0vmfXXRuPeFnIYUVrL M2KA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=xdiI9VGQW6gwmNT/X80o8SZWk0Bb/m5TdjO2YU/oIcA=; b=EeV+39aVYAYEDd/QJ9AI0MQOrhL3UC+9fdLoF4bZ95zdyIqHer8Aw927fin35RD6/1 Wm6VUO3+pfIgqLgXD8E4RvkgSbjMvt1KqFOPCbRmQs0KqDYaW2hRmzaMzs5yk5vxYXvo pFXkSDJJ/kFiyPuF+0NGUheQXENXTpx2UDest6qrWW/fZy9DLqt8Lu/S0+npftyjvCN2 vVboebd8rrvntukiFvk4ml3Mz57VrmCOizPhQQw8/r8D2t41Ty61F6a02jEuW/aYMAg6 cAukx2cray/LpD9gtIPSshaB2ztQ2BjdC1Lg07Hq9LLUrMDdSJ6kNCwP/Z6lTEI5sJkP QKvg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=zOgpe3As; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id js1si11090269ejc.557.2022.01.25.00.26.21; Tue, 25 Jan 2022 00:26:46 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=zOgpe3As; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S3420864AbiAYCZm (ORCPT + 99 others); Mon, 24 Jan 2022 21:25:42 -0500 Received: from dfw.source.kernel.org ([139.178.84.217]:49358 "EHLO dfw.source.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1349747AbiAXTVP (ORCPT ); Mon, 24 Jan 2022 14:21:15 -0500 Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by dfw.source.kernel.org (Postfix) with ESMTPS id E1CF2612FA; Mon, 24 Jan 2022 19:21:14 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id C57C7C340E5; Mon, 24 Jan 2022 19:21:13 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1643052074; bh=s1zOZaBKK25K2dWFszrxbwGQGSRLpyHYOg5sPtaaNN0=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=zOgpe3AsXCON5gF8Io9Kx4LlIl2IQr8pBuijB3v72jboshCKIMTOfv5+nOuhajYWS WCaFhKup8mUJGg/se87e2veOVdgBvrSQA/YgSspv3LQ+1t0x16cdWPiqt9Xony4p/r 0a37D9h8bsi5J05vzZ7sqOF0YPV1II3OVG72py8g= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Sean Young , Mauro Carvalho Chehab , Sasha Levin Subject: [PATCH 4.19 148/239] media: igorplugusb: receiver overflow should be reported Date: Mon, 24 Jan 2022 19:43:06 +0100 Message-Id: <20220124183947.801806290@linuxfoundation.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20220124183943.102762895@linuxfoundation.org> References: <20220124183943.102762895@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Sean Young [ Upstream commit 8fede658e7ddb605bbd68ed38067ddb0af033db4 ] Without this, some IR will be missing mid-stream and we might decode something which never really occurred. Signed-off-by: Sean Young Signed-off-by: Mauro Carvalho Chehab Signed-off-by: Sasha Levin --- drivers/media/rc/igorplugusb.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/drivers/media/rc/igorplugusb.c b/drivers/media/rc/igorplugusb.c index f563ddd7f7392..98a13532a5968 100644 --- a/drivers/media/rc/igorplugusb.c +++ b/drivers/media/rc/igorplugusb.c @@ -73,9 +73,11 @@ static void igorplugusb_irdata(struct igorplugusb *ir, unsigned len) if (start >= len) { dev_err(ir->dev, "receive overflow invalid: %u", overflow); } else { - if (overflow > 0) + if (overflow > 0) { dev_warn(ir->dev, "receive overflow, at least %u lost", overflow); + ir_raw_event_reset(ir->rc); + } do { rawir.duration = ir->buf_in[i] * 85333; -- 2.34.1