From patchwork Mon Feb 19 14:19:55 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Tony Lindgren X-Patchwork-Id: 13562777 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id E1271C48BF8 for ; Mon, 19 Feb 2024 14:21:00 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 06AA010E29A; Mon, 19 Feb 2024 14:21:00 +0000 (UTC) Authentication-Results: gabe.freedesktop.org; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=atomide.com header.i=@atomide.com header.b="Z/lYE2GV"; dkim-atps=neutral Received: from mail5.25mail.st (mail5.25mail.st [74.50.62.9]) by gabe.freedesktop.org (Postfix) with ESMTPS id 1BCF910E29A for ; Mon, 19 Feb 2024 14:20:57 +0000 (UTC) Received: from localhost (91-158-86-216.elisa-laajakaista.fi [91.158.86.216]) by mail5.25mail.st (Postfix) with ESMTPSA id 99DE160889; Mon, 19 Feb 2024 14:20:37 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=atomide.com; s=25mailst; t=1708352456; bh=ZSH7/4/ogQNJvFIc5NcMaWCz0kQiV+UenYex7AkYtQk=; h=From:To:Cc:Subject:Date:From; b=Z/lYE2GV//A62pJ9OjB5upx3ePwmFrY2rQzyYEJL8zvCUtAU1I++UGkADrqGTG3tg J3Czysgt8i1l4Z4WxuTRax1d3XorzTFxAtCKE2paA6Q5WxuqcZ1oObwQPC15yVFnHY vGAiM3Zl5eYuDR8SDli4Tibzv0NN/qAL+pKqAecrQledgdJLDczLXOddlA3f3w9imY A3e0RZgzRxDrkWr2VlQD53ZXeIqRfRQTS0Z++lw7BMj4xF2vwFeYeD+4sbqdBcunzY 7mDlpOw86eaE259CXaKyCt6RBAand/julO4WvI01h2QTJvZNA9116LEo6MN2w7FLFu 5Ct8ahsBf1XtQ== From: Tony Lindgren To: Tomi Valkeinen , Maarten Lankhorst , Maxime Ripard , Thomas Zimmermann , David Airlie , Daniel Vetter , Javier Martinez Canillas , Sam Ravnborg Cc: dri-devel@lists.freedesktop.org Subject: [PATCH 1/2] drm/omapdrm: Fix console by implementing fb_dirty Date: Mon, 19 Feb 2024 16:19:55 +0200 Message-ID: <20240219142001.19727-1-tony@atomide.com> X-Mailer: git-send-email 2.43.1 MIME-Version: 1.0 X-BeenThere: dri-devel@lists.freedesktop.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Direct Rendering Infrastructure - Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" The framebuffer console stopped updating with commit f231af498c29 ("drm/fb-helper: Disconnect damage worker from update logic"). Let's fix the issue by implementing fb_dirty similar to what was done with commit 039a72ce7e57 ("drm/i915/fbdev: Implement fb_dirty for intel custom fb helper"). Fixes: f231af498c29 ("drm/fb-helper: Disconnect damage worker from update logic") Signed-off-by: Tony Lindgren Reviewed-by: Thomas Zimmermann --- drivers/gpu/drm/omapdrm/omap_fbdev.c | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/drivers/gpu/drm/omapdrm/omap_fbdev.c b/drivers/gpu/drm/omapdrm/omap_fbdev.c --- a/drivers/gpu/drm/omapdrm/omap_fbdev.c +++ b/drivers/gpu/drm/omapdrm/omap_fbdev.c @@ -238,8 +238,20 @@ static int omap_fbdev_create(struct drm_fb_helper *helper, return ret; } +static int omap_fbdev_dirty(struct drm_fb_helper *helper, struct drm_clip_rect *clip) +{ + if (!(clip->x1 < clip->x2 && clip->y1 < clip->y2)) + return 0; + + if (helper->fb->funcs->dirty) + return helper->fb->funcs->dirty(helper->fb, NULL, 0, 0, clip, 1); + + return 0; +} + static const struct drm_fb_helper_funcs omap_fb_helper_funcs = { .fb_probe = omap_fbdev_create, + .fb_dirty = omap_fbdev_dirty, }; static struct drm_fb_helper *get_fb(struct fb_info *fbi)