Received: by 10.213.65.68 with SMTP id h4csp488336imn; Fri, 16 Mar 2018 09:15:19 -0700 (PDT) X-Google-Smtp-Source: AG47ELuFUuD5B6bDg91bnva450nIgXMAdEpkDxzXkzxG1L8F3lh8J4dl6s+UPQjC/yG/dbHIfIuo X-Received: by 2002:a17:902:7608:: with SMTP id k8-v6mr2738807pll.95.1521216919392; Fri, 16 Mar 2018 09:15:19 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1521216919; cv=none; d=google.com; s=arc-20160816; b=Ml9C1TqpzEY0SMNCxRij7EoRrPmz1AfsElqtBpUZTfgjmKLyRzTIxpasryWpnLaw7x CTtespB0g06pDg6bI/WCc2z8+e07GNl5JE/1fN4FbMqeJIG64bezhDaBDKf+DEVgis+5 7l6Unuefh67gYIdCNdU6NBaZztdyMNTvFxLD4gIrzF7N/ZDVTZrb6A38BLMCCG0j79Op IHWEv7NxYk0e1GaAm45R3vM8QoDAefnuxNs5/Sp7PWrBGy3wonIHaG6tV9jTVVssLScc XwWkn3/vadm3dL3ODC0OVxQeMiPer2+aFCx/pe4OGZB44n/E9ClvQzFtLUyU8NWBJSxx JzYw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:mime-version:user-agent:references :in-reply-to:message-id:date:subject:cc:to:from :arc-authentication-results; bh=P/Inr3tSyVyYKxdeOojdAOvrgRgZbJGc1gqfSn8QS/E=; b=P56AwjZiN4OHd2HtdRLXFoIjKMQhEWtYh14KFVm4HO+qPFjtER2TY8wiQSfjmsB6Re 0r/GNzGKybg1dV0oasquG3q30CfzCmu7IkoTkdy6XT1QXJZN4yjvJHTTvtIoMZr2hcm7 u9sg2zcDXfqduwZhOFnA4aPzeoaOVGkqt78XkDTnAOMGwPR1nDGBgobAPtUF+JQiHTwT EMRKT1DLwmOvrLkdqHpvU/sfWPDmrQjOBO06p5Hojh5XahRaxf51L02tpl1tIR3UcxM3 ojAtvZ/xOW3VZi24AHlpJP08DhYsUhrLMWEBXSezOzSlnUP8kzzvAixA8QomYDnU0XYw XT/w== 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 t10-v6si1996352plq.531.2018.03.16.09.15.03; Fri, 16 Mar 2018 09:15:19 -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 S964778AbeCPQNB (ORCPT + 99 others); Fri, 16 Mar 2018 12:13:01 -0400 Received: from mail.linuxfoundation.org ([140.211.169.12]:43514 "EHLO mail.linuxfoundation.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S965012AbeCPPkQ (ORCPT ); Fri, 16 Mar 2018 11:40:16 -0400 Received: from localhost (LFbn-1-12247-202.w90-92.abo.wanadoo.fr [90.92.61.202]) by mail.linuxfoundation.org (Postfix) with ESMTPSA id 5872AD4D; Fri, 16 Mar 2018 15:40:15 +0000 (UTC) From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Dan Carpenter , Eric Anholt , Sasha Levin Subject: [PATCH 4.15 028/128] drm/panel: rpi-touchscreen: propagate errors in rpi_touchscreen_i2c_read() Date: Fri, 16 Mar 2018 16:22:49 +0100 Message-Id: <20180316152337.931529587@linuxfoundation.org> X-Mailer: git-send-email 2.16.2 In-Reply-To: <20180316152336.199007505@linuxfoundation.org> References: <20180316152336.199007505@linuxfoundation.org> User-Agent: quilt/0.65 X-stable: review MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org 4.15-stable review patch. If anyone has any objections, please let me know. ------------------ From: Dan Carpenter [ Upstream commit 85b4587f8e94143bafb8b6a4003a5187b9a8753d ] There is one caller which checks whether rpi_touchscreen_i2c_read() returns negative error codes. Currently it can't because negative error codes are truncated to u8, but that's easy to fix if we change the type to int. Fixes: 2f733d6194bd ("drm/panel: Add support for the Raspberry Pi 7" Touchscreen.") Signed-off-by: Dan Carpenter Signed-off-by: Eric Anholt Link: https://patchwork.freedesktop.org/patch/msgid/20171020002845.kar2wg7gqxg7tzqi@mwanda Reviewed-by: Eric Anholt Signed-off-by: Sasha Levin Signed-off-by: Greg Kroah-Hartman --- drivers/gpu/drm/panel/panel-raspberrypi-touchscreen.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/gpu/drm/panel/panel-raspberrypi-touchscreen.c b/drivers/gpu/drm/panel/panel-raspberrypi-touchscreen.c index 890fd6ff397c..d964d454e4ae 100644 --- a/drivers/gpu/drm/panel/panel-raspberrypi-touchscreen.c +++ b/drivers/gpu/drm/panel/panel-raspberrypi-touchscreen.c @@ -221,7 +221,7 @@ static struct rpi_touchscreen *panel_to_ts(struct drm_panel *panel) return container_of(panel, struct rpi_touchscreen, base); } -static u8 rpi_touchscreen_i2c_read(struct rpi_touchscreen *ts, u8 reg) +static int rpi_touchscreen_i2c_read(struct rpi_touchscreen *ts, u8 reg) { return i2c_smbus_read_byte_data(ts->i2c, reg); } -- 2.16.2