public inbox for stable@vger.kernel.org
 help / color / mirror / Atom feed
From: Sasha Levin <sashal@kernel.org>
To: linux-kernel@vger.kernel.org, stable@vger.kernel.org
Cc: Harry Wentland <harry.wentland@amd.com>,
	Alex Hung <alex.hung@amd.com>,
	Louis Chauvet <louis.chauvet@bootlin.com>,
	Sasha Levin <sashal@kernel.org>,
	maarten.lankhorst@linux.intel.com, mripard@kernel.org,
	tzimmermann@suse.de, airlied@gmail.com, simona@ffwll.ch,
	dri-devel@lists.freedesktop.org
Subject: [PATCH AUTOSEL 6.13 08/17] drm/vkms: Round fixp2int conversion in lerp_u16
Date: Mon,  3 Mar 2025 11:29:40 -0500	[thread overview]
Message-ID: <20250303162951.3763346-8-sashal@kernel.org> (raw)
In-Reply-To: <20250303162951.3763346-1-sashal@kernel.org>

From: Harry Wentland <harry.wentland@amd.com>

[ Upstream commit 8ec43c58d3be615a71548bc09148212013fb7e5f ]

fixp2int always rounds down, fixp2int_ceil rounds up. We need
the new fixp2int_round.

Signed-off-by: Alex Hung <alex.hung@amd.com>
Signed-off-by: Harry Wentland <harry.wentland@amd.com>
Reviewed-by: Louis Chauvet <louis.chauvet@bootlin.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20241220043410.416867-3-alex.hung@amd.com
Signed-off-by: Louis Chauvet <louis.chauvet@bootlin.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
---
 drivers/gpu/drm/vkms/vkms_composer.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/gpu/drm/vkms/vkms_composer.c b/drivers/gpu/drm/vkms/vkms_composer.c
index 3f0977d746bee..87dfb9f69ee5b 100644
--- a/drivers/gpu/drm/vkms/vkms_composer.c
+++ b/drivers/gpu/drm/vkms/vkms_composer.c
@@ -98,7 +98,7 @@ static u16 lerp_u16(u16 a, u16 b, s64 t)
 
 	s64 delta = drm_fixp_mul(b_fp - a_fp,  t);
 
-	return drm_fixp2int(a_fp + delta);
+	return drm_fixp2int_round(a_fp + delta);
 }
 
 static s64 get_lut_index(const struct vkms_color_lut *lut, u16 channel_value)
-- 
2.39.5


  parent reply	other threads:[~2025-03-03 16:30 UTC|newest]

Thread overview: 19+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-03-03 16:29 [PATCH AUTOSEL 6.13 01/17] phy: ti: gmii-sel: Do not use syscon helper to build regmap Sasha Levin
2025-03-03 16:29 ` [PATCH AUTOSEL 6.13 02/17] ASoC: tas2770: Fix volume scale Sasha Levin
2025-03-03 16:29 ` [PATCH AUTOSEL 6.13 03/17] ASoC: tas2764: Fix power control mask Sasha Levin
2025-03-03 16:29 ` [PATCH AUTOSEL 6.13 04/17] ASoC: tas2764: Set the SDOUT polarity correctly Sasha Levin
2025-03-03 16:29 ` [PATCH AUTOSEL 6.13 05/17] fuse: don't truncate cached, mutated symlink Sasha Levin
2025-03-03 16:29 ` [PATCH AUTOSEL 6.13 06/17] ASoC: dapm-graph: set fill colour of turned on nodes Sasha Levin
2025-03-03 16:29 ` [PATCH AUTOSEL 6.13 07/17] ASoC: SOF: Intel: don't check number of sdw links when set dmic_fixup Sasha Levin
2025-03-03 16:29 ` Sasha Levin [this message]
2025-03-03 16:29 ` [PATCH AUTOSEL 6.13 09/17] perf/x86/intel: Use better start period for frequency mode Sasha Levin
2025-03-03 16:29 ` [PATCH AUTOSEL 6.13 10/17] x86/of: Don't use DTB for SMP setup if ACPI is enabled Sasha Levin
2025-03-03 16:29 ` [PATCH AUTOSEL 6.13 11/17] x86/irq: Define trace events conditionally Sasha Levin
2025-03-03 16:29 ` [PATCH AUTOSEL 6.13 12/17] perf/x86/rapl: Add support for Intel Arrow Lake U Sasha Levin
2025-03-03 16:29 ` [PATCH AUTOSEL 6.13 13/17] mptcp: safety check before fallback Sasha Levin
2025-03-03 17:05   ` Matthieu Baerts
2025-03-15  1:39     ` Sasha Levin
2025-03-03 16:29 ` [PATCH AUTOSEL 6.13 14/17] drm/nouveau: Do not override forced connector status Sasha Levin
2025-03-03 16:29 ` [PATCH AUTOSEL 6.13 15/17] net: Handle napi_schedule() calls from non-interrupt Sasha Levin
2025-03-03 16:29 ` [PATCH AUTOSEL 6.13 16/17] block: fix 'kmem_cache of name 'bio-108' already exists' Sasha Levin
2025-03-03 16:29 ` [PATCH AUTOSEL 6.13 17/17] vhost: return task creation error instead of NULL Sasha Levin

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20250303162951.3763346-8-sashal@kernel.org \
    --to=sashal@kernel.org \
    --cc=airlied@gmail.com \
    --cc=alex.hung@amd.com \
    --cc=dri-devel@lists.freedesktop.org \
    --cc=harry.wentland@amd.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=louis.chauvet@bootlin.com \
    --cc=maarten.lankhorst@linux.intel.com \
    --cc=mripard@kernel.org \
    --cc=simona@ffwll.ch \
    --cc=stable@vger.kernel.org \
    --cc=tzimmermann@suse.de \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox