Received: by 2002:ab2:6816:0:b0:1f9:5764:f03e with SMTP id t22csp1211544lqo; Fri, 17 May 2024 14:39:19 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCW2F93dHK1eywPuqFOHPzicO0rWCj9qe/fggT4Qz8kYYu/86wkOgcVa29RUs+uufJprVB/iCtSyqCuiW/xQOBKFSQqGXr1GUoxHeJ4ocA== X-Google-Smtp-Source: AGHT+IFmY2FgyUBoQj7JcfQPFdzqYx6p4Al2uoNzj7WdsOq6fO2W+0yS+qpOfU5FOkp5jXfCC8PN X-Received: by 2002:a17:90b:3502:b0:2a6:217b:4492 with SMTP id 98e67ed59e1d1-2bd6035acd3mr419994a91.3.1715981959079; Fri, 17 May 2024 14:39:19 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1715981959; cv=pass; d=google.com; s=arc-20160816; b=wlqZ03Bq5rrGiX89fl3rrR6miBw84oi6N1QUWWrq817ZPkHj9rx5cmpOvmz5d3yLV9 uu+LLd1JKfdnllTXOdSYPAzaUb2joMOMy6w/t9XBrlo1vyR72Yad2JoDG8ajL4/fF+q5 DKlwdYik7D03EQ7I4RhzBLNmoUXROxkbL0fBAP1e+OvM7CmIG0FcWxjgbtfR3zB7meMq pxReKm1FoX2fzcZxKKRUxJJDkMDAVj0QdrUooG31WUkXAwuYCc2J1GQXocPpRNPpRJKc 74lR3N8mVQyfr4g88nzfwpke5yb1lMV5P5TGRroC5UHLU2GSouqxQ9aYKlE/TFeOb/ye qFeQ== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:references:in-reply-to:message-id :date:subject:cc:to:from:dkim-signature; bh=We3AVE4aBq1trFIRy44WPUFQ73H18cpHtn0h/NL3Rck=; fh=wW2o67kWHFCIvaa+Y9IOUHAWhoz98BoYdsRPeXF34qw=; b=wWQdvFWjkE3UnydD4Eu9DDdrgF2Df36n112hBhAyvLa4rS3N34E+s01MkvBYZdy2Sn YurXY2DWEXVe6GYyYgQEf/fy1DZnQRVvIDMEFHLDWSsosON3YXD1BuTjO/ndTBLCLYsc 4aDIEHvmYUQZEh4XuHTqU4Iwy7Qdipu9dJWBP5L3SXrlilLni5zvYFAGAk9jhv6k0H9u zP/XyAjE/49lcrV6QXzmBa7YG4pWSoE1KCXOiXKzUJmQgYv8BocajFnCUAkgupiHhUP8 k5f87EgWr9ZTnJ0lxdCctDjflQ1cusD44HI/MOTCme1EuCcZOzaZS8Nhfpjv+Ii8KWtw LwHw==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@chromium.org header.s=google header.b=OJu3MyUY; arc=pass (i=1 spf=pass spfdomain=chromium.org dkim=pass dkdomain=chromium.org dmarc=pass fromdomain=chromium.org); spf=pass (google.com: domain of linux-kernel+bounces-182650-linux.lists.archive=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) smtp.mailfrom="linux-kernel+bounces-182650-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=chromium.org Return-Path: Received: from sv.mirrors.kernel.org (sv.mirrors.kernel.org. [139.178.88.99]) by mx.google.com with ESMTPS id 98e67ed59e1d1-2b9f9fd2421si5144226a91.94.2024.05.17.14.39.18 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 17 May 2024 14:39:19 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-182650-linux.lists.archive=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) client-ip=139.178.88.99; Authentication-Results: mx.google.com; dkim=pass header.i=@chromium.org header.s=google header.b=OJu3MyUY; arc=pass (i=1 spf=pass spfdomain=chromium.org dkim=pass dkdomain=chromium.org dmarc=pass fromdomain=chromium.org); spf=pass (google.com: domain of linux-kernel+bounces-182650-linux.lists.archive=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) smtp.mailfrom="linux-kernel+bounces-182650-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=chromium.org Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by sv.mirrors.kernel.org (Postfix) with ESMTPS id 3B08E285ECC for ; Fri, 17 May 2024 21:39:17 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id A07DE1428F5; Fri, 17 May 2024 21:37:51 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=chromium.org header.i=@chromium.org header.b="OJu3MyUY" Received: from mail-pf1-f179.google.com (mail-pf1-f179.google.com [209.85.210.179]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 7FEC51422C9 for ; Fri, 17 May 2024 21:37:49 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.210.179 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1715981870; cv=none; b=oLG21NV9W4UPsbWuv37g/2GikVNIPwcGr6AEna9VsuxNqCsbmZ6O7QdEcIbXqrPpnkPmNND7VMOz1/8SNIc4D4nLigKd9RVvfd0O3f0NvzsxRRrPwUF2kMspNcAtTKWGaGlT57xuBRCL0InbwdglM8HUNAgtgzbHPeL0gTVLI5k= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1715981870; c=relaxed/simple; bh=5VVt/FrP2yAQArxTo9XSbAJ7t5bq1ysohglCBFIU/f0=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=n/ZJcIUSYDGQ1/TEZzE0FhMwh7f+CWF5bdOHuGLcaouhI+8Ivy60xy+Fn2aYY0nT0k0pZdJfx14LY6yxusHXCX9YCXJ2W+XtLgnlaUWayO43IRIuRbVVW27ZIS4gGgatuHbObga7Dw1MIPbyxUZTROiN+61GZLNhwCYKiEsGYnY= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=chromium.org; spf=pass smtp.mailfrom=chromium.org; dkim=pass (1024-bit key) header.d=chromium.org header.i=@chromium.org header.b=OJu3MyUY; arc=none smtp.client-ip=209.85.210.179 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=chromium.org Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=chromium.org Received: by mail-pf1-f179.google.com with SMTP id d2e1a72fcca58-6f4ed9dc7beso1329286b3a.1 for ; Fri, 17 May 2024 14:37:49 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; t=1715981869; x=1716586669; darn=vger.kernel.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=We3AVE4aBq1trFIRy44WPUFQ73H18cpHtn0h/NL3Rck=; b=OJu3MyUYebCzR0X7+2Wae56M/YMK9x02hz/amNqJnaCQDjPLKIhIam/BND00DOURs1 otHuCMAYGh2hWzx9r8/8QsI+UpY5+Xsbq4XKVVdAxx1Z6cpz+/qG8NetZeqi0GgycBd4 a/acPkOrDPlgsB5IngFD8T76QA1Upd2zBFA3w= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1715981869; x=1716586669; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=We3AVE4aBq1trFIRy44WPUFQ73H18cpHtn0h/NL3Rck=; b=OqXuN7Pxb2ezRknxF9gKMEXeKoYHTXD3RpQXp9chOE/qglRB0FcpOZ2uF0XBDh4bpS izeQLbkRHgG2yPPIJPvKWqOtBlNmOdIepZLH1ZtWNQcC0JWF25a25ao4/1HWwjOzkSpM F1mwCYXiPYKuQsncyl2DPi++dXC4wkKB14jAN4PoTCByAzXAJbwLgJGuxjtv5r0E7nhf 9RO8Ky2wsC14h3oE5AJjXxrYWCMdtkokQtn+iPgFXNndKjicSbsTsj0p+zeA+Qi7g8PJ wCbZPpjt6eLpJsj27s2MKpdSok1c2oeIgb8VRUwgbTbo+5xTbdQAoW8HqkIZ65rRvDaY PfCA== X-Forwarded-Encrypted: i=1; AJvYcCW9XryxCJWZ9c0UmoRZvsHpGmPEDAvJ9+7zLjq9s5s/OfSrZJ30MLsZiVdypavh7ws1HV+Z1t6MHsLVp46TRDw055WNlw3dH0MJGO4S X-Gm-Message-State: AOJu0Yxy9qwQ+IEscJa4Ey8He54B638n1o9oyHYjA5UUehAwuTwCvHPg qvDYO5ksXE/4XY0fEL3jTJrjwLX6qs/0ZU//xaQ41O1C9yjMcBsUi4wnrinITA== X-Received: by 2002:a05:6a00:3b05:b0:6f4:463f:af87 with SMTP id d2e1a72fcca58-6f69fbe02bfmr353213b3a.10.1715981868854; Fri, 17 May 2024 14:37:48 -0700 (PDT) Received: from dianders.sjc.corp.google.com ([2620:15c:9d:2:26de:b1dd:5:771c]) by smtp.gmail.com with ESMTPSA id d2e1a72fcca58-6f4d2b2f8b3sm15168736b3a.211.2024.05.17.14.37.47 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 17 May 2024 14:37:48 -0700 (PDT) From: Douglas Anderson To: Neil Armstrong , Jessica Zhang , Sam Ravnborg Cc: Linus Walleij , Dmitry Baryshkov , Douglas Anderson , Cong Yang , Daniel Vetter , David Airlie , Maarten Lankhorst , Maxime Ripard , Thomas Zimmermann , dri-devel@lists.freedesktop.org, linux-kernel@vger.kernel.org Subject: [PATCH 7/8] drm/panel: himax-hx83102: Check for errors on the NOP in prepare() Date: Fri, 17 May 2024 14:36:42 -0700 Message-ID: <20240517143643.7.I3fae28745bf2cacd8dac04d7a06daea50e233f46@changeid> X-Mailer: git-send-email 2.45.0.rc1.225.g2a3ae87e7f-goog In-Reply-To: <20240517213712.3135166-1-dianders@chromium.org> References: <20240517213712.3135166-1-dianders@chromium.org> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit The mipi_dsi_dcs_nop() function returns an error but we weren't checking it in hx83102_prepare(). Add a check. This is highly unlikely to matter in practice. If the NOP failed then likely later MIPI commands would fail too. Found by code inspection. Fixes: 0ef94554dc40 ("drm/panel: himax-hx83102: Break out as separate driver") Signed-off-by: Douglas Anderson --- drivers/gpu/drm/panel/panel-himax-hx83102.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/drivers/gpu/drm/panel/panel-himax-hx83102.c b/drivers/gpu/drm/panel/panel-himax-hx83102.c index 4ac7f9d8b232..1ba623e41924 100644 --- a/drivers/gpu/drm/panel/panel-himax-hx83102.c +++ b/drivers/gpu/drm/panel/panel-himax-hx83102.c @@ -547,7 +547,11 @@ static int hx83102_prepare(struct drm_panel *panel) usleep_range(10000, 11000); - mipi_dsi_dcs_nop(ctx->dsi); + ret = mipi_dsi_dcs_nop(ctx->dsi); + if (ret < 0) { + dev_err(dev, "Failed to send NOP: %d\n", ret); + goto poweroff; + } usleep_range(1000, 2000); gpiod_set_value(ctx->enable_gpio, 1); -- 2.45.0.rc1.225.g2a3ae87e7f-goog