From nobody Tue Feb 10 09:59:07 2026 Delivered-To: importer@patchew.org Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass(p=none dis=none) header.from=jablonski.xyz ARC-Seal: i=1; a=rsa-sha256; t=1769784779; cv=none; d=zohomail.com; s=zohoarc; b=GmRFeE3TYnDTh8SjfEQ+afJoS5MxA4LlnS2E2jcgpf0Tw4YlHvKM1kvIyoAwCW0fUEq+OinhOYI/HQf9NwFhmeJM5Va6j8MnkHlw+PRGVfZMogiJE8dJSoJ/PBXbv2yfBGN5FlZPTSSL06E/bUK/HtgcI5bt7Uc+qf7dMSiWjnI= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1769784779; h=Content-Transfer-Encoding:Cc:Cc:Date:Date:From:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:Subject:To:To:Message-Id:Reply-To; bh=uCYbYki+RrEf0+bAMdGHQku8jFfKWrGr3ucgiXfFkIw=; b=h3fsI43jWtcyCcZOwxBaQpNmgBQjAaBpIOYjUhVMXdLx9H2af/3Vt9OWoMPjovCEENDHwndkb5rlEixyL/g2zCQMwYBUdG5TIPUrSfiTFaM8o0SULAaayrTRlzT3q888K3t8Wphp2aM3N+QwCcg2Z+xw0gWBKZQEZsFtClYiDXU= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass header.from= (p=none dis=none) Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1769784779408276.37312841924984; Fri, 30 Jan 2026 06:52:59 -0800 (PST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1vlppR-0004kL-0Q; Fri, 30 Jan 2026 09:50:33 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1vlppO-0004j2-VN for qemu-devel@nongnu.org; Fri, 30 Jan 2026 09:50:30 -0500 Received: from fhigh-b2-smtp.messagingengine.com ([202.12.124.153]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1vlppL-00038U-GE for qemu-devel@nongnu.org; Fri, 30 Jan 2026 09:50:30 -0500 Received: from phl-compute-02.internal (phl-compute-02.internal [10.202.2.42]) by mailfhigh.stl.internal (Postfix) with ESMTP id 581427A0168; Fri, 30 Jan 2026 09:50:26 -0500 (EST) Received: from phl-frontend-04 ([10.202.2.163]) by phl-compute-02.internal (MEProxy); Fri, 30 Jan 2026 09:50:26 -0500 Received: by mail.messagingengine.com (Postfix) with ESMTPA; Fri, 30 Jan 2026 09:50:25 -0500 (EST) Received: from localhost (chomposaur [local]) by chomposaur (OpenSMTPD) with ESMTPA id ab85122e; Fri, 30 Jan 2026 14:50:19 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=jablonski.xyz; h=cc:cc:content-transfer-encoding:content-type:date:date:from :from:in-reply-to:in-reply-to:message-id:mime-version:references :reply-to:subject:subject:to:to; s=fm2; t=1769784626; x= 1769871026; bh=uCYbYki+RrEf0+bAMdGHQku8jFfKWrGr3ucgiXfFkIw=; b=p pNhS6svsD8drA+muQlDtT9fpU+gdJs4lVi3/QXhE+zNH3AXTeNmhWtgpRuZS3Z5G /XF6YRATfXHJuH5oy63ki7BEnQ/2XtFPMJ8Xbn/FBJ0+WL+VrIRbm2C3RlxaFvuC RBlS16mfiJtX+hgt3uhD/Y0sVxrdjtYXLFTQ6b2NDH4Fiy4UuSMj2d5xogGMQWgQ jKp4hIhYP5U88kX1J1nKXdqKLPxHxE9A1lhQ3rK3pU6RnVMhW/f4weGEun45Ux7U bec+DCwvzGSP5PcKyeIuJ7vwsOVMdL7ifmeZwEvJxOSOZdnfX9FDCfcdhqNGRq48 D+K06X7eCo7cnPutXuVvA== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:cc:content-transfer-encoding :content-type:date:date:feedback-id:feedback-id:from:from :in-reply-to:in-reply-to:message-id:mime-version:references :reply-to:subject:subject:to:to:x-me-proxy:x-me-sender :x-me-sender:x-sasl-enc; s=fm3; t=1769784626; x=1769871026; bh=u CYbYki+RrEf0+bAMdGHQku8jFfKWrGr3ucgiXfFkIw=; b=ObvD9AM0jh8YjczJi 2e7YWkBe3EpG1scMk0c0VqmQVaMkKa3Jw/yDzjkmDWf6csAUwicZFtgD6ycOrvjA 6zi0n+Hf9valgxliCsbQJBEwx46jG9yz9qKd29ULFLSMrju5xJgurP9FbwL/1hpd XF12Fl/H03REzu9qnJNcCIupzOFQ9NJejuvzX5kpwaXn32uDvko7uUeHJo5Aafzl E0yTCASRWq54FdYzsLKBTg22vsP6J71za+QrgZHZe91wXEE2QDXrX8RjP4t9YkdQ OSkG0unHAJe3KxlEN964gxM32KyBYU1I3MSgQrud+1F88utsJIGcfTBwAihEb5gu OjVmw== X-ME-Sender: X-ME-Received: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgeefgedrtddtgdduieelfedvucetufdoteggodetrf dotffvucfrrhhofhhilhgvmecuhfgrshhtofgrihhlpdfurfetoffkrfgpnffqhgenuceu rghilhhouhhtmecufedttdenucgfrhhlucfvnfffucdljedtmdenucfjughrpefhvfevuf ffkffojghfggfgsedtkeertdertddtnecuhfhrohhmpeevhhgrugculfgrsghlohhnshhk ihcuoegthhgrugesjhgrsghlohhnshhkihdrgiihiieqnecuggftrfgrthhtvghrnhepgf eiteejhfelheefieetjefgleejfffhueffvdduieejgfeuueeuvddvkeejhfelnecuvehl uhhsthgvrhfuihiivgeptdenucfrrghrrghmpehmrghilhhfrhhomheptghhrggusehjrg gslhhonhhskhhirdighiiipdhnsggprhgtphhtthhopeefpdhmohguvgepshhmthhpohhu thdprhgtphhtthhopegthhgrugesjhgrsghlohhnshhkihdrgiihiidprhgtphhtthhope gsrghlrghtohhnsegvihhkrdgsmhgvrdhhuhdprhgtphhtthhopehqvghmuhdquggvvhgv lhesnhhonhhgnhhurdhorhhg X-ME-Proxy: Feedback-ID: ib26944c1:Fastmail From: Chad Jablonski To: qemu-devel@nongnu.org Cc: balaton@eik.bme.hu, Chad Jablonski Subject: [PATCH v6 16/20] ati-vga: Remove ATIVGAState param from ati_2d_do_blt Date: Fri, 30 Jan 2026 09:50:01 -0500 Message-ID: <20260130145005.731129-17-chad@jablonski.xyz> X-Mailer: git-send-email 2.52.0 In-Reply-To: <20260130145005.731129-1-chad@jablonski.xyz> References: <20260130145005.731129-1-chad@jablonski.xyz> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Received-SPF: pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Received-SPF: pass client-ip=202.12.124.153; envelope-from=chad@jablonski.xyz; helo=fhigh-b2-smtp.messagingengine.com X-Spam_score_int: -2 X-Spam_score: -0.3 X-Spam_bar: / X-Spam_report: (-0.3 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, FROM_SUSPICIOUS_NTLD=0.499, PDS_OTHER_BAD_TLD=1.999, RCVD_IN_DNSWL_LOW=-0.7, RCVD_IN_VALIDITY_RPBL_BLOCKED=0.001, RCVD_IN_VALIDITY_SAFE_BLOCKED=0.001, SPF_HELO_PASS=-0.001, SPF_PASS=-0.001, UNPARSEABLE_RELAY=0.001 autolearn=no autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: qemu development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: qemu-devel-bounces+importer=patchew.org@nongnu.org X-ZohoMail-DKIM: pass (identity @jablonski.xyz) X-ZM-MESSAGEID: 1769784780718158500 Content-Type: text/plain; charset="utf-8" This completes the decoupling from the ATIVGAState struct. Signed-off-by: Chad Jablonski --- hw/display/ati_2d.c | 17 ++++++++--------- 1 file changed, 8 insertions(+), 9 deletions(-) diff --git a/hw/display/ati_2d.c b/hw/display/ati_2d.c index 5c15c3ec70..89a9d006af 100644 --- a/hw/display/ati_2d.c +++ b/hw/display/ati_2d.c @@ -68,6 +68,10 @@ static void ati_set_dirty(VGACommonState *vga, const ATI= 2DCtx *ctx) { DisplaySurface *ds =3D qemu_console_surface(vga->con); unsigned dst_offset =3D ctx->dst_bits - vga->vram_ptr; + DPRINTF("%p %u ds: %p %d %d rop: %x\n", vga->vram_ptr, + vga->vbe_start_addr, surface_data(ds), surface_stride(ds), + surface_bits_per_pixel(ds), + ctx->rop3 >> 16); if (ctx->dst_bits >=3D vga->vram_ptr + vga->vbe_start_addr && ctx->dst_bits < vga->vram_ptr + vga->vbe_start_addr + vga->vbe_regs[VBE_DISPI_INDEX_YRES] * vga->vbe_line_offset) { @@ -114,16 +118,12 @@ static void setup_2d_blt_ctx(const ATIVGAState *s, AT= I2DCtx *ctx) } } =20 -static void ati_2d_do_blt(ATIVGAState *s, ATI2DCtx *ctx, uint8_t use_pixma= n) +static void ati_2d_do_blt(ATI2DCtx *ctx, uint8_t use_pixman) { /* FIXME it is probably more complex than this and may need to be */ /* rewritten but for now as a start just to get some output: */ bool use_pixman_fill =3D use_pixman & BIT(0); bool use_pixman_blt =3D use_pixman & BIT(1); - DPRINTF("%p %u ds: %p %d %d rop: %x\n", s->vga.vram_ptr, - s->vga.vbe_start_addr, surface_data(ds), surface_stride(ds), - surface_bits_per_pixel(ds), - ctx->rop3 >> 16); if (!ctx->bpp) { qemu_log_mask(LOG_GUEST_ERROR, "Invalid bpp\n"); return; @@ -140,9 +140,8 @@ static void ati_2d_do_blt(ATIVGAState *s, ATI2DCtx *ctx= , uint8_t use_pixman) qemu_log_mask(LOG_UNIMP, "blt outside vram not implemented\n"); return; } - DPRINTF("%d %d %d, %d %d %d, (%d,%d) -> (%d,%d) %dx%d %c %c\n", - s->regs.src_offset, dst_offset, s->regs.default_offset, - ctx->src_stride, ctx->dst_stride, s->regs.default_pitch, + DPRINTF("%d %d, (%d,%d) -> (%d,%d) %dx%d %c %c\n", + ctx->src_stride, ctx->dst_stride, ctx->src.x, ctx->src.y, ctx->dst.x, ctx->dst.y, ctx->dst.width, ctx->dst.height, (ctx->left_to_right ? '>' : '<'), @@ -278,6 +277,6 @@ void ati_2d_blt(ATIVGAState *s) { ATI2DCtx ctx; setup_2d_blt_ctx(s, &ctx); - ati_2d_do_blt(s, &ctx, s->use_pixman); + ati_2d_do_blt(&ctx, s->use_pixman); ati_set_dirty(&s->vga, &ctx); } --=20 2.52.0