Received: by 2002:a05:6a10:af89:0:0:0:0 with SMTP id iu9csp3715748pxb; Mon, 24 Jan 2022 16:09:33 -0800 (PST) X-Google-Smtp-Source: ABdhPJz17kXagLxzPwgH+nl3+6y79PXpj+mm0rIDW7FILuz/5l8GZ0EhQhLske952n3HTxBCAMMm X-Received: by 2002:a63:3fcd:: with SMTP id m196mr13307791pga.168.1643069372841; Mon, 24 Jan 2022 16:09:32 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1643069372; cv=none; d=google.com; s=arc-20160816; b=x05jID1poNnY719RJymrd0PsgzjKhtG3AgB6oLEMqd57CbXj782rpe3lGXM916g6b+ fLu4g7RaL8k81YUH2gxYF9kmJDKMICgJ8F0j8CoeaBX1PhaQzfafAsGWMpAiqVDyau/L qj/IhKFCOLcGwCELlUdoaRv18rdKtlO5P1C76bdIWFb1oTeKXZ2jBn/AI8uLJXcF4PBp 6BN3AIbqMYS/Kd9852/z7X1VNErSHWdJwUeidPS8A9ml34yd7EFgfKRplYnJxpol4de+ VtCcAO+lOFBDCmJMQN7dg8T521kRi3cdJXc7Hc/LxZYvZtrZJlE1N6zWs8BInrCNNw9V e5dw== 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=bWHt8I0GnhNLIrwDNN2cgibn+LRWW8M1FtQe+XtpZsU=; b=DD6GfkHrHIyHu1qRW8cOVQVU11j1Q6alKM7Opfv2UATIA+Tfh0Yv0f22oWZ1UUbUGv 5tWqgvPb3zFLksCUG3zJ4iYiTBx4zjFSNp6AdQUXG6mroJiTZ14qlkaxFMAsxPq1VJOG YP8A+HBMSCMOBxIbd1KnjUpN7C8fSKVs5U3/1q0pEP47TmmNgMvwF+4LZojloBNbp5bR hEQC9VwmVKwR1uojtXnWyS9qgRS1jtcSfDPQUTt11S2uY/tMIl9Qnru/o5iq8Hob8EN0 EhxwwEew4a7ht7931U+Ql+Gd/zOedGVTOYHxxlqcnMkuSqwu+VyyA12EC54G6KrQskk+ i/VA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=oLuMTb9b; 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 b4si14905543pfl.173.2022.01.24.16.09.20; Mon, 24 Jan 2022 16:09:32 -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=oLuMTb9b; 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 S2370590AbiAYAFp (ORCPT + 99 others); Mon, 24 Jan 2022 19:05:45 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:50544 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1847608AbiAXXUH (ORCPT ); Mon, 24 Jan 2022 18:20:07 -0500 Received: from dfw.source.kernel.org (dfw.source.kernel.org [IPv6:2604:1380:4641:c500::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 7888AC073204; Mon, 24 Jan 2022 13:27:55 -0800 (PST) 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 1595D614B4; Mon, 24 Jan 2022 21:27:55 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id EE1EEC340E4; Mon, 24 Jan 2022 21:27:53 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1643059674; bh=WPTVkbAlftiPDcELrGcS+39e8k3c46GZhJ5lqBJBBQE=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=oLuMTb9b2XCUT4uVdp3cCyoYvlnYIoIZthJnIOrvHSaEgeJW+4J8YvrL2PqxhAXMz 5TWO8frEH8k6roTwl4nEnrS+OIfIEf0NTySwcxvpK11XMN5lVQlHPN4WQBaivk5+3O v/ytmFmjwQkyi9DrgXV/xIJEI0thf135Ln0FX6EM= 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 5.16 0652/1039] media: igorplugusb: receiver overflow should be reported Date: Mon, 24 Jan 2022 19:40:41 +0100 Message-Id: <20220124184147.276927311@linuxfoundation.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20220124184125.121143506@linuxfoundation.org> References: <20220124184125.121143506@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 effaa5751d6c9..3e9988ee785f0 100644 --- a/drivers/media/rc/igorplugusb.c +++ b/drivers/media/rc/igorplugusb.c @@ -64,9 +64,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] * 85; -- 2.34.1