From patchwork Tue Feb 20 19:46:55 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: David Tadokoro X-Patchwork-Id: 13565098 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 48B7FC48BC3 for ; Wed, 21 Feb 2024 08:09:12 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 3D85C10E65B; Wed, 21 Feb 2024 08:09:05 +0000 (UTC) Authentication-Results: gabe.freedesktop.org; dkim=pass (2048-bit key; secure) header.d=usp.br header.i=@usp.br header.b="jo7dazof"; dkim-atps=neutral Received: from mail-pf1-f174.google.com (mail-pf1-f174.google.com [209.85.210.174]) by gabe.freedesktop.org (Postfix) with ESMTPS id EDBE710E548 for ; Tue, 20 Feb 2024 19:47:37 +0000 (UTC) Received: by mail-pf1-f174.google.com with SMTP id d2e1a72fcca58-6e45d0c9676so1789878b3a.0 for ; Tue, 20 Feb 2024 11:47:37 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=usp.br; s=usp-google; t=1708458457; x=1709063257; darn=lists.freedesktop.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=Q6VIzixTXzfsOehBNdTAI/rwoARfHVoZJfkUg/7sqYs=; b=jo7dazofMUTXm+ZVYxatgP8h8GL15OCTwCEBx2KHmltqIl+giMuSwSE0melsQ0ILpO TBYkbyjGU+iHpX14KGKifwtB0+lGNhV5/9WHwkVHrX1Ip44BaE1Y7ub1xIOadTEGoJne es+Cy06jmXlbvIUu28MoztFsxO2BPmiawCMV7Kzy+j+rmY8pXf8DcHYb1XVCVquMsDO2 T6EQTqxanqMbd2l7+GoPspH9ySatKUzcKONfiKeGvxAO9NAsvoEHLqa8//5EU3JqCj7p b3Ry9o3Mrz2RSA2ENaVks3KcA3NS9t/5aUO4ZuSpdK3uehluENjrKcBapMZ5RQ7l+msq lE8A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1708458457; x=1709063257; 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=Q6VIzixTXzfsOehBNdTAI/rwoARfHVoZJfkUg/7sqYs=; b=Uc2uQdf5zFVL2U2qdrXQn4VK374le2rXiDQe3cYTbwlSh2PmhTuCMDnAbf22K1SfzJ zs22cCjlzE3mR98w3PYKOCTO/U4ZesbS2RszlOwLCO4cMx72M2ZrcbB9NDv+7MFCbH7E N9NFA1URaHGBLRXvCRHDrMbOub6BBZeO2bikx1HnrDilOqFnboDMGnUgZn76yPgvyZNx UoHJx3dpB3lUP6i9aWJIIxh3SFktVNQ85jU735fbhZZfhmYBIrW2Av/929gTfLQ4NBZV 9N1ldmM4ZhECNfG6eIW8CpXyf+mg6xdtEs+hAMWlhDl6Ac+FGFE7W8PnOZUqZqGgGcIY n5Gw== X-Forwarded-Encrypted: i=1; AJvYcCUYNG1RFAZm+kRRtK2Fp6JMbU0LcG0J4ahd4vQYntLL9SY5ROPPrIWMZIpgoCjAom+lXJNUCcjEfZYfADURPHrCvtsy3V8IIfZzYiwsi0sP X-Gm-Message-State: AOJu0YwwUsAbgpA5t1QSlkX4HwtCtn7rm+kZgfELpCvl//MLZC3P4WFw iCUVNF48Tx9Q6Zm4w5mjCbFs4AZcuvhM0BI++BA6BSxNuBCQ4+uN+WoXxEET3ik= X-Google-Smtp-Source: AGHT+IFgSkgcVtlGl29yJIA184G9Y9bRu08SmE/6+uoV1knpPK9Evk4Db0EYpHCqkt1tBAyEziIoXg== X-Received: by 2002:a05:6a20:93a2:b0:19e:5dda:6bd with SMTP id x34-20020a056a2093a200b0019e5dda06bdmr25055183pzh.8.1708458457453; Tue, 20 Feb 2024 11:47:37 -0800 (PST) Received: from localhost.localdomain ([185.153.176.89]) by smtp.gmail.com with ESMTPSA id u21-20020aa78395000000b006e0ad616be3sm7293482pfm.110.2024.02.20.11.47.34 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 20 Feb 2024 11:47:37 -0800 (PST) From: David Tadokoro To: harry.wentland@amd.com, sunpeng.li@amd.com, Rodrigo.Siqueira@amd.com, alexander.deucher@amd.com, christian.koenig@amd.com, Xinhui.Pan@amd.com, airlied@gmail.com, daniel@ffwll.ch Cc: David Tadokoro , amd-gfx@lists.freedesktop.org, dri-devel@lists.freedesktop.org Subject: [PATCH 1/3] drm/amd/display: add prefix to rv1_clk_mgr_clk.c function Date: Tue, 20 Feb 2024 16:46:55 -0300 Message-Id: <20240220194657.243378-2-davidbtadokoro@usp.br> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20240220194657.243378-1-davidbtadokoro@usp.br> References: <20240220194657.243378-1-davidbtadokoro@usp.br> MIME-Version: 1.0 X-Mailman-Approved-At: Wed, 21 Feb 2024 08:08:40 +0000 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 function defined in dc/clk_mgr/dcn10/rv1_clk_mgr_clk.c doesn't have a name that indicates where it was declared. To better filter results in debug tools like ftrace, prefix this function with 'rv1_clk_mgr_clk_'. Signed-off-by: David Tadokoro --- drivers/gpu/drm/amd/display/dc/clk_mgr/dcn10/rv1_clk_mgr_clk.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/gpu/drm/amd/display/dc/clk_mgr/dcn10/rv1_clk_mgr_clk.c b/drivers/gpu/drm/amd/display/dc/clk_mgr/dcn10/rv1_clk_mgr_clk.c index 61dd12198a3c..b63e0e92d118 100644 --- a/drivers/gpu/drm/amd/display/dc/clk_mgr/dcn10/rv1_clk_mgr_clk.c +++ b/drivers/gpu/drm/amd/display/dc/clk_mgr/dcn10/rv1_clk_mgr_clk.c @@ -49,7 +49,7 @@ /* Only used by testing framework*/ -void rv1_dump_clk_registers(struct clk_state_registers *regs, struct clk_bypass *bypass, struct clk_mgr *clk_mgr_base) +void rv1_clk_mgr_clk_dump_clk_registers(struct clk_state_registers *regs, struct clk_bypass *bypass, struct clk_mgr *clk_mgr_base) { struct clk_mgr_internal *clk_mgr = TO_CLK_MGR_INTERNAL(clk_mgr_base); From patchwork Tue Feb 20 19:46:56 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: David Tadokoro X-Patchwork-Id: 13565090 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 D8A1EC48BC3 for ; Wed, 21 Feb 2024 08:09:04 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 6FD1210E64B; Wed, 21 Feb 2024 08:09:03 +0000 (UTC) Authentication-Results: gabe.freedesktop.org; dkim=pass (2048-bit key; secure) header.d=usp.br header.i=@usp.br header.b="IgAC8GwE"; dkim-atps=neutral Received: from mail-pg1-f178.google.com (mail-pg1-f178.google.com [209.85.215.178]) by gabe.freedesktop.org (Postfix) with ESMTPS id 7D8C010E548 for ; Tue, 20 Feb 2024 19:47:46 +0000 (UTC) Received: by mail-pg1-f178.google.com with SMTP id 41be03b00d2f7-5dbf7b74402so4798095a12.0 for ; Tue, 20 Feb 2024 11:47:46 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=usp.br; s=usp-google; t=1708458466; x=1709063266; darn=lists.freedesktop.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=WEwAJnG85LZhHLPhtupVWGgKznsoezSxNC+Z5m8WKxs=; b=IgAC8GwEV0bBgxF8H8j1+nyMc37PXwT6TSw7dbJoKK2kO/U1BZR0FLEiyQDwWUuj/L VkLsqg/WNPlhgwLF/PTBLQK3X2VmZsyEZqR9vT1lHaWMP1MFtqxTCQKnD6vY7wm2xa6G 875E4/+DJKAve+JGSFaGrZL/cWWpL7SJ/+fgLDpHj1CDNBSEKd8Z3vR6jc8uv8CIUN0J S/PkeuTP0KkZ9Gcl3+HjweANW1zQw0hYlqj5wF/b1r7fvV5V21UzCGVKEqwrjpUbLHaM vGwVmwz2XJi81F/Z8lU+9axCTE9yyXgZThfY7YlWkrOMKA31MFqj/jZX0cpedVIF6Z/W OqDQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1708458466; x=1709063266; 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=WEwAJnG85LZhHLPhtupVWGgKznsoezSxNC+Z5m8WKxs=; b=T/E0rPc4lXvIITyLZMeCTfrdyq2V+S+reo53ssHKM3up3n/3c5FbXGWN7VNcTJ0zFc OwRmROcmJXYMArxZrZ1MJP1aSlb5hcESXxU+5XpowBaqh45AffWylJAV9pAsGcSqX63k mkRSkdYlRp6npLqwAR6CKQ/0g/Bwn/yuAy0geMYTZs77W9bsF7z7DNHuCc0Q1LY/PSWf U4JFgrtsFuwb8GvLgrFYQCy1H7F2QaJO6JmeY5Wfk0Mz07f2Phbmo4GAb3iT5IN7vnch RYnXmKaG4N+pN3H1hsrnSGM1S1Xy4vf31aCTjSfPIHsMY6J0EFPYwy6E+YpYEghsDg/p kASw== X-Forwarded-Encrypted: i=1; AJvYcCX4fsKvAMowreAbaRNa0sWT2whNKuzl7RAodgoAYEbdJg0j7OW/Gx4TyItB4VzatU12xFpkxdqmviMWMm/bXr8qVk8rjg17yprhlkMU4D5s X-Gm-Message-State: AOJu0YwxZBiZXq315ERSbh4UmMvu5YrEH7KWBg9TeU/tQVDNpTxmuctB Ut1PsEKmwLIUIEaW746PwHpQ7t1AhJTFajasFODIROPFEgs34pn3g1oDlNCeHH8= X-Google-Smtp-Source: AGHT+IHT/6ByV3nCKHTDzWjbdXhJg67w1/vgAwad3K/qgGS5NL2u7SrgCHlhoCDACT7hRksY4kRgGA== X-Received: by 2002:a05:6a21:3982:b0:19e:a1a3:b14 with SMTP id ad2-20020a056a21398200b0019ea1a30b14mr19115226pzc.1.1708458465992; Tue, 20 Feb 2024 11:47:45 -0800 (PST) Received: from localhost.localdomain ([185.153.176.89]) by smtp.gmail.com with ESMTPSA id u21-20020aa78395000000b006e0ad616be3sm7293482pfm.110.2024.02.20.11.47.42 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 20 Feb 2024 11:47:45 -0800 (PST) From: David Tadokoro To: harry.wentland@amd.com, sunpeng.li@amd.com, Rodrigo.Siqueira@amd.com, alexander.deucher@amd.com, christian.koenig@amd.com, Xinhui.Pan@amd.com, airlied@gmail.com, daniel@ffwll.ch Cc: David Tadokoro , amd-gfx@lists.freedesktop.org, dri-devel@lists.freedesktop.org Subject: [PATCH 2/3] drm/amd/display: add prefix to rv1_clk_mgr.c functions Date: Tue, 20 Feb 2024 16:46:56 -0300 Message-Id: <20240220194657.243378-3-davidbtadokoro@usp.br> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20240220194657.243378-1-davidbtadokoro@usp.br> References: <20240220194657.243378-1-davidbtadokoro@usp.br> MIME-Version: 1.0 X-Mailman-Approved-At: Wed, 21 Feb 2024 08:08:40 +0000 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 functions defined in dc/clk_mgr/dcn10/rv1_clk_mgr.c don't have names that indicates where they were declared. To better filter results in debug tools like ftrace, prefix these functions with 'rv1_clk_mgr_'. Signed-off-by: David Tadokoro --- .../display/dc/clk_mgr/dcn10/rv1_clk_mgr.c | 22 +++++++++---------- 1 file changed, 11 insertions(+), 11 deletions(-) diff --git a/drivers/gpu/drm/amd/display/dc/clk_mgr/dcn10/rv1_clk_mgr.c b/drivers/gpu/drm/amd/display/dc/clk_mgr/dcn10/rv1_clk_mgr.c index 60761ff3cbf1..093084a48daa 100644 --- a/drivers/gpu/drm/amd/display/dc/clk_mgr/dcn10/rv1_clk_mgr.c +++ b/drivers/gpu/drm/amd/display/dc/clk_mgr/dcn10/rv1_clk_mgr.c @@ -34,12 +34,12 @@ #include "rv1_clk_mgr_vbios_smu.h" #include "rv1_clk_mgr_clk.h" -static void rv1_init_clocks(struct clk_mgr *clk_mgr) +static void rv1_clk_mgr_init_clocks(struct clk_mgr *clk_mgr) { memset(&(clk_mgr->clks), 0, sizeof(struct dc_clocks)); } -static int rv1_determine_dppclk_threshold(struct clk_mgr_internal *clk_mgr, struct dc_clocks *new_clocks) +static int rv1_clk_mgr_determine_dppclk_threshold(struct clk_mgr_internal *clk_mgr, struct dc_clocks *new_clocks) { bool request_dpp_div = new_clocks->dispclk_khz > new_clocks->dppclk_khz; bool dispclk_increase = new_clocks->dispclk_khz > clk_mgr->base.clks.dispclk_khz; @@ -85,18 +85,18 @@ static int rv1_determine_dppclk_threshold(struct clk_mgr_internal *clk_mgr, stru return disp_clk_threshold; } -static void ramp_up_dispclk_with_dpp( +static void rv1_clk_mgr_ramp_up_dispclk_with_dpp( struct clk_mgr_internal *clk_mgr, struct dc *dc, struct dc_clocks *new_clocks, bool safe_to_lower) { int i; - int dispclk_to_dpp_threshold = rv1_determine_dppclk_threshold(clk_mgr, new_clocks); + int dispclk_to_dpp_threshold = rv1_clk_mgr_determine_dppclk_threshold(clk_mgr, new_clocks); bool request_dpp_div = new_clocks->dispclk_khz > new_clocks->dppclk_khz; /* this function is to change dispclk, dppclk and dprefclk according to - * bandwidth requirement. Its call stack is rv1_update_clocks --> + * bandwidth requirement. Its call stack is rv1_clk_mgr_update_clocks --> * update_clocks --> dcn10_prepare_bandwidth / dcn10_optimize_bandwidth * --> prepare_bandwidth / optimize_bandwidth. before change dcn hw, * prepare_bandwidth will be called first to allow enough clock, @@ -187,7 +187,7 @@ static void ramp_up_dispclk_with_dpp( clk_mgr->base.clks.max_supported_dppclk_khz = new_clocks->max_supported_dppclk_khz; } -static void rv1_update_clocks(struct clk_mgr *clk_mgr_base, +static void rv1_clk_mgr_update_clocks(struct clk_mgr *clk_mgr_base, struct dc_state *context, bool safe_to_lower) { @@ -274,7 +274,7 @@ static void rv1_update_clocks(struct clk_mgr *clk_mgr_base, /* program dispclk on = as a w/a for sleep resume clock ramping issues */ if (should_set_clock(safe_to_lower, new_clocks->dispclk_khz, clk_mgr_base->clks.dispclk_khz) || new_clocks->dispclk_khz == clk_mgr_base->clks.dispclk_khz) { - ramp_up_dispclk_with_dpp(clk_mgr, dc, new_clocks, safe_to_lower); + rv1_clk_mgr_ramp_up_dispclk_with_dpp(clk_mgr, dc, new_clocks, safe_to_lower); clk_mgr_base->clks.dispclk_khz = new_clocks->dispclk_khz; send_request_to_lower = true; } @@ -291,7 +291,7 @@ static void rv1_update_clocks(struct clk_mgr *clk_mgr_base, } } -static void rv1_enable_pme_wa(struct clk_mgr *clk_mgr_base) +static void rv1_clk_mgr_enable_pme_wa(struct clk_mgr *clk_mgr_base) { struct clk_mgr_internal *clk_mgr = TO_CLK_MGR_INTERNAL(clk_mgr_base); struct pp_smu_funcs_rv *pp_smu = NULL; @@ -305,10 +305,10 @@ static void rv1_enable_pme_wa(struct clk_mgr *clk_mgr_base) } static struct clk_mgr_funcs rv1_clk_funcs = { - .init_clocks = rv1_init_clocks, + .init_clocks = rv1_clk_mgr_init_clocks, .get_dp_ref_clk_frequency = dce12_get_dp_ref_freq_khz, - .update_clocks = rv1_update_clocks, - .enable_pme_wa = rv1_enable_pme_wa, + .update_clocks = rv1_clk_mgr_update_clocks, + .enable_pme_wa = rv1_clk_mgr_enable_pme_wa, }; static struct clk_mgr_internal_funcs rv1_clk_internal_funcs = { From patchwork Tue Feb 20 19:46:57 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: David Tadokoro X-Patchwork-Id: 13565099 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 42AA0C5475B for ; Wed, 21 Feb 2024 08:09:14 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 630CD10E655; Wed, 21 Feb 2024 08:09:06 +0000 (UTC) Authentication-Results: gabe.freedesktop.org; dkim=pass (2048-bit key; secure) header.d=usp.br header.i=@usp.br header.b="AvVguWfU"; dkim-atps=neutral Received: from mail-pf1-f182.google.com (mail-pf1-f182.google.com [209.85.210.182]) by gabe.freedesktop.org (Postfix) with ESMTPS id BB5F310E548 for ; Tue, 20 Feb 2024 19:47:50 +0000 (UTC) Received: by mail-pf1-f182.google.com with SMTP id d2e1a72fcca58-6e3ffafa708so2825650b3a.1 for ; Tue, 20 Feb 2024 11:47:50 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=usp.br; s=usp-google; t=1708458470; x=1709063270; darn=lists.freedesktop.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=/rfF5m6vNt6+z97Bq6fmRU0kV10rXjJY38OISp8QurM=; b=AvVguWfUYJE/YE+3oHScbghaKf577yn1LcUKzx+hrSri3wGw285KtJ5TxThaUsn1jl y+6SypjMbWEIWz7b39HG5mjjkwcQPTEyJdGEUNQznPgaGJVbKOK9/vVUgcNMGnZ7OjIk SGSA3NUF9CA7YshnyOETtr0gAYaenPlzWdqnpd67Mmw3Yk6YaeXVP1lq4gF1/dU/kRov cIBfWIfhkLtCAzUO+1E9DGQfYA53nYVdUpSUDx90X4W4mXhXo3tNmGityOps9jV0mp/T Q6IlEmn4h7GafIgtVWd9F7bmQ+mVCnhTZrney8gayoGOWqN6Keqj3VJKLZq73+Tp42F4 IFvQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1708458470; x=1709063270; 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=/rfF5m6vNt6+z97Bq6fmRU0kV10rXjJY38OISp8QurM=; b=nLRWzrZ3A7FHRcRBAuzyY0zCtevG9e8wKcMyGWel1P3yFcZihL+ZF0ojRpcqyVsyPR aUPQVirv/lSN2ShYRMDiyAg7iLZjY+lzyDj92hqPtSctZd5qQQsqDTXDtowEmALj4BIq Q/v1GLnJtE+yUWjEmeuKn6kA7sT7NAU9JqRUM6wGOWQgkdDkStOaB26AtSUnBuXAU/iK x1ECCGAI/OM+yPg3qrrQZO3Qqqd1CYACYEOOXAHgMXIOaf/utDDkA/bzNvQhluydW+H3 uHWdVUwURKr5ahDy1WsLA2qc0EBgcDIQzuB76MHZnn/3w+JV01XwRFeLlRjSlmEE/HAj rVmQ== X-Forwarded-Encrypted: i=1; AJvYcCU7PdvSYxZvYncTbXal3APHdw5u1v595zdg8t8MhmK6HI+pLQ5oHj7rhA3yRdPwPjLfB8ZrE2bdCcJt9OMax+zKkv+7h9JfHXIwVbZbh+s0 X-Gm-Message-State: AOJu0Yxa2vZBufPfsFYJjRoLiHSaklAoRU6Yn265shm7bPSrQFI2LOPv +LGLx51gEhocLRmxkQQEOfR0fXCSyDEzn7DHN5tftyLSiemXYfc6AntN0P4qEnI= X-Google-Smtp-Source: AGHT+IGnWwdG7CL0BtV8R2A3YBFuZU/pQKWvEybJ349/zXthCZwJvV4AKsmxTNvR0W7LM5AsqUP5Jg== X-Received: by 2002:aa7:8455:0:b0:6e4:148e:2946 with SMTP id r21-20020aa78455000000b006e4148e2946mr7616833pfn.25.1708458470319; Tue, 20 Feb 2024 11:47:50 -0800 (PST) Received: from localhost.localdomain ([185.153.176.89]) by smtp.gmail.com with ESMTPSA id u21-20020aa78395000000b006e0ad616be3sm7293482pfm.110.2024.02.20.11.47.47 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 20 Feb 2024 11:47:50 -0800 (PST) From: David Tadokoro To: harry.wentland@amd.com, sunpeng.li@amd.com, Rodrigo.Siqueira@amd.com, alexander.deucher@amd.com, christian.koenig@amd.com, Xinhui.Pan@amd.com, airlied@gmail.com, daniel@ffwll.ch Cc: David Tadokoro , amd-gfx@lists.freedesktop.org, dri-devel@lists.freedesktop.org Subject: [PATCH 3/3] drm/amd/display: add prefix to rv1_clk_mgr_vbios_smu.c functions Date: Tue, 20 Feb 2024 16:46:57 -0300 Message-Id: <20240220194657.243378-4-davidbtadokoro@usp.br> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20240220194657.243378-1-davidbtadokoro@usp.br> References: <20240220194657.243378-1-davidbtadokoro@usp.br> MIME-Version: 1.0 X-Mailman-Approved-At: Wed, 21 Feb 2024 08:08:40 +0000 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 functions defined in dc/clk_mgr/dcn10/rv1_clk_mgr_vbios_smu.c don't have names that indicate where they were declared. To better filter results in debug tools like ftrace, prefix these functions with 'rv1_clk_mgr_vbios_smu_'. Signed-off-by: David Tadokoro --- .../drm/amd/display/dc/clk_mgr/dcn10/rv1_clk_mgr.c | 2 +- .../dc/clk_mgr/dcn10/rv1_clk_mgr_vbios_smu.c | 14 +++++++------- .../dc/clk_mgr/dcn10/rv1_clk_mgr_vbios_smu.h | 4 ++-- 3 files changed, 10 insertions(+), 10 deletions(-) diff --git a/drivers/gpu/drm/amd/display/dc/clk_mgr/dcn10/rv1_clk_mgr.c b/drivers/gpu/drm/amd/display/dc/clk_mgr/dcn10/rv1_clk_mgr.c index 093084a48daa..3109c6651f1c 100644 --- a/drivers/gpu/drm/amd/display/dc/clk_mgr/dcn10/rv1_clk_mgr.c +++ b/drivers/gpu/drm/amd/display/dc/clk_mgr/dcn10/rv1_clk_mgr.c @@ -312,7 +312,7 @@ static struct clk_mgr_funcs rv1_clk_funcs = { }; static struct clk_mgr_internal_funcs rv1_clk_internal_funcs = { - .set_dispclk = rv1_vbios_smu_set_dispclk, + .set_dispclk = rv1_clk_mgr_vbios_smu_set_dispclk, .set_dprefclk = dce112_set_dprefclk }; diff --git a/drivers/gpu/drm/amd/display/dc/clk_mgr/dcn10/rv1_clk_mgr_vbios_smu.c b/drivers/gpu/drm/amd/display/dc/clk_mgr/dcn10/rv1_clk_mgr_vbios_smu.c index 89b79dd39628..7823186250d3 100644 --- a/drivers/gpu/drm/amd/display/dc/clk_mgr/dcn10/rv1_clk_mgr_vbios_smu.c +++ b/drivers/gpu/drm/amd/display/dc/clk_mgr/dcn10/rv1_clk_mgr_vbios_smu.c @@ -83,7 +83,7 @@ static const struct IP_BASE MP1_BASE = { { { { 0x00016000, 0, 0, 0, 0 } }, * the register is NOT EQUAL to zero, and because the translation in msg_if.h * won't work with REG_WAIT. */ -static uint32_t rv1_smu_wait_for_response(struct clk_mgr_internal *clk_mgr, unsigned int delay_us, unsigned int max_retries) +static uint32_t rv1_clk_mgr_vbios_smu_wait_for_response(struct clk_mgr_internal *clk_mgr, unsigned int delay_us, unsigned int max_retries) { uint32_t res_val = VBIOSSMC_Status_BUSY; @@ -101,7 +101,7 @@ static uint32_t rv1_smu_wait_for_response(struct clk_mgr_internal *clk_mgr, unsi return res_val; } -static int rv1_vbios_smu_send_msg_with_param(struct clk_mgr_internal *clk_mgr, +static int rv1_clk_mgr_vbios_smu_send_msg_with_param(struct clk_mgr_internal *clk_mgr, unsigned int msg_id, unsigned int param) { uint32_t result; @@ -115,7 +115,7 @@ static int rv1_vbios_smu_send_msg_with_param(struct clk_mgr_internal *clk_mgr, /* Trigger the message transaction by writing the message ID */ REG_WRITE(MP1_SMN_C2PMSG_67, msg_id); - result = rv1_smu_wait_for_response(clk_mgr, 10, 1000); + result = rv1_clk_mgr_vbios_smu_wait_for_response(clk_mgr, 10, 1000); ASSERT(result == VBIOSSMC_Result_OK); @@ -123,14 +123,14 @@ static int rv1_vbios_smu_send_msg_with_param(struct clk_mgr_internal *clk_mgr, return REG_READ(MP1_SMN_C2PMSG_83); } -int rv1_vbios_smu_set_dispclk(struct clk_mgr_internal *clk_mgr, int requested_dispclk_khz) +int rv1_clk_mgr_vbios_smu_set_dispclk(struct clk_mgr_internal *clk_mgr, int requested_dispclk_khz) { int actual_dispclk_set_mhz = -1; struct dc *dc = clk_mgr->base.ctx->dc; struct dmcu *dmcu = dc->res_pool->dmcu; /* Unit of SMU msg parameter is Mhz */ - actual_dispclk_set_mhz = rv1_vbios_smu_send_msg_with_param( + actual_dispclk_set_mhz = rv1_clk_mgr_vbios_smu_send_msg_with_param( clk_mgr, VBIOSSMC_MSG_SetDispclkFreq, khz_to_mhz_ceil(requested_dispclk_khz)); @@ -144,11 +144,11 @@ int rv1_vbios_smu_set_dispclk(struct clk_mgr_internal *clk_mgr, int requested_di return actual_dispclk_set_mhz * 1000; } -int rv1_vbios_smu_set_dprefclk(struct clk_mgr_internal *clk_mgr) +int rv1_clk_mgr_vbios_smu_set_dprefclk(struct clk_mgr_internal *clk_mgr) { int actual_dprefclk_set_mhz = -1; - actual_dprefclk_set_mhz = rv1_vbios_smu_send_msg_with_param( + actual_dprefclk_set_mhz = rv1_clk_mgr_vbios_smu_send_msg_with_param( clk_mgr, VBIOSSMC_MSG_SetDprefclkFreq, khz_to_mhz_ceil(clk_mgr->base.dprefclk_khz)); diff --git a/drivers/gpu/drm/amd/display/dc/clk_mgr/dcn10/rv1_clk_mgr_vbios_smu.h b/drivers/gpu/drm/amd/display/dc/clk_mgr/dcn10/rv1_clk_mgr_vbios_smu.h index 083cb3158859..d6d50cd3755d 100644 --- a/drivers/gpu/drm/amd/display/dc/clk_mgr/dcn10/rv1_clk_mgr_vbios_smu.h +++ b/drivers/gpu/drm/amd/display/dc/clk_mgr/dcn10/rv1_clk_mgr_vbios_smu.h @@ -26,7 +26,7 @@ #ifndef DAL_DC_DCN10_RV1_CLK_MGR_VBIOS_SMU_H_ #define DAL_DC_DCN10_RV1_CLK_MGR_VBIOS_SMU_H_ -int rv1_vbios_smu_set_dispclk(struct clk_mgr_internal *clk_mgr, int requested_dispclk_khz); -int rv1_vbios_smu_set_dprefclk(struct clk_mgr_internal *clk_mgr); +int rv1_clk_mgr_vbios_smu_set_dispclk(struct clk_mgr_internal *clk_mgr, int requested_dispclk_khz); +int rv1_clk_mgr_vbios_smu_set_dprefclk(struct clk_mgr_internal *clk_mgr); #endif /* DAL_DC_DCN10_RV1_CLK_MGR_VBIOS_SMU_H_ */