From patchwork Tue Jan 10 10:17:47 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: AceLan Kao X-Patchwork-Id: 1723903 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@legolas.ozlabs.org Authentication-Results: legolas.ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=lists.ubuntu.com (client-ip=91.189.94.19; helo=huckleberry.canonical.com; envelope-from=kernel-team-bounces@lists.ubuntu.com; receiver=) Authentication-Results: legolas.ozlabs.org; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=gmail.com header.i=@gmail.com header.a=rsa-sha256 header.s=20210112 header.b=Gnh3s9PR; dkim-atps=neutral Received: from huckleberry.canonical.com (huckleberry.canonical.com [91.189.94.19]) (using TLSv1.2 with cipher ECDHE-ECDSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by legolas.ozlabs.org (Postfix) with ESMTPS id 4Nrmwq30Dlz23gG for ; Tue, 10 Jan 2023 21:18:19 +1100 (AEDT) Received: from localhost ([127.0.0.1] helo=huckleberry.canonical.com) by huckleberry.canonical.com with esmtp (Exim 4.86_2) (envelope-from ) id 1pFBhu-0004lF-0q; Tue, 10 Jan 2023 10:18:14 +0000 Received: from mail-pf1-f177.google.com ([209.85.210.177]) by huckleberry.canonical.com with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.86_2) (envelope-from ) id 1pFBhr-0004kJ-LS for kernel-team@lists.ubuntu.com; Tue, 10 Jan 2023 10:18:11 +0000 Received: by mail-pf1-f177.google.com with SMTP id c9so8426832pfj.5 for ; Tue, 10 Jan 2023 02:18:11 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:sender:from:to:cc:subject:date :message-id:reply-to; bh=jmTYVkRbU9ItHpbkSE3AX95LuM3uL5+JB7/P/TcbLD0=; b=Gnh3s9PR1/V74xtLQw8oCmgFD680Z7eNko6+cMLUxybcSz8lEH2QYvMallz2qzLEt4 NFUI/4Z0knIZ9AZHluerLCXhUzVkJMOTgYbCLB1I43BQP7445/xzfxB4GyqtnOFAjlnb fg6m9PPYmvgjZ2KNiuhdLh3P64A7ba2lm0ZalplIWSQNvlS1r6YwqfBLBDiBzbiXHXjB rQT96SkOW9nBrXatRy1FsHJaoneD1TXYDFilG+1o2VTdGImAeMZX7/cuZW2HSfBb6L/K xl5nvUgQuWw0xOcUmvuWjPHcHZFcenpGUD4X4deIMhMrLFYmDFAaTuEscII6OxIAB4wa StXw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:sender:x-gm-message-state:from:to :cc:subject:date:message-id:reply-to; bh=jmTYVkRbU9ItHpbkSE3AX95LuM3uL5+JB7/P/TcbLD0=; b=cYPtEcC61AcEMOKgNJMwVPoA8ct2AVKaCw2qVGL1HrHhvdzTxvulrfXMhHVQ4gVaTQ xFhFcVrfucBUM1JbLZEt5OvyUzbGuL9PNqS7UPCUs5F6uGQkikiKO7CcEr0ZurhQWdkp QtNo1LbB6K9h1ihSdZcvPk6CUjcBJCgnbENE+PYx59aofNYBV3j0mrc7WRG279icR7Az 3Y6AtRMRnxFcLdCZomZVW+sbeG2oOhTkaPPZ14aZt7jdbjYve7xMzYms79+84CrOa69j Q8Z/XayyxZwycZpAdB9BBop3d647chDJq5Nx7cBEaQO7DhU6TnjbE2TShOVPTO9+fgpB HHbw== X-Gm-Message-State: AFqh2kq4ipHg8DQBtAOCHnBef/2/2d/KaXaSKZCBtoTltlLQS7YMSpoz o8e8hREtERy/H1NNrztFDAmJRP1SyeybRQ== X-Google-Smtp-Source: AMrXdXtLLJbO1O0OoWVnKyJzRJhgtnMNzpmGtSYqzpn/BBEpfNDcnc3njG1Yh1tB7DMniKGnsbpAOA== X-Received: by 2002:a05:6a00:1787:b0:588:e132:a2f8 with SMTP id s7-20020a056a00178700b00588e132a2f8mr7266018pfg.23.1673345889600; Tue, 10 Jan 2023 02:18:09 -0800 (PST) Received: from localhost ([2001:67c:1560:8007::aac:c469]) by smtp.gmail.com with ESMTPSA id t20-20020aa79474000000b005636326fdbfsm7713179pfq.78.2023.01.10.02.18.07 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 10 Jan 2023 02:18:09 -0800 (PST) From: AceLan Kao To: kernel-team@lists.ubuntu.com Subject: [PATCH 1/9][SRU][L][OEM-6.1] drm/i915: Introduce intel_panel_init_alloc() Date: Tue, 10 Jan 2023 18:17:47 +0800 Message-Id: <20230110101755.1107104-2-acelan.kao@canonical.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20230110101755.1107104-1-acelan.kao@canonical.com> References: <20230110101755.1107104-1-acelan.kao@canonical.com> MIME-Version: 1.0 Received-SPF: pass client-ip=209.85.210.177; envelope-from=acelan@gmail.com; helo=mail-pf1-f177.google.com X-BeenThere: kernel-team@lists.ubuntu.com X-Mailman-Version: 2.1.20 Precedence: list List-Id: Kernel team discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: kernel-team-bounces@lists.ubuntu.com Sender: "kernel-team" From: Ville Syrjälä BugLink: https://launchpad.net/bugs/2001599 Introduce a place where we can initialize connector->panel after it's been allocated. We already have a intel_panel_init() so had to get creative with the name and came up with intel_panel_init_alloc(). Cc: Animesh Manna Reviewed-by: Jani Nikula Signed-off-by: Ville Syrjälä Link: https://patchwork.freedesktop.org/patch/msgid/20221125173156.31689-2-ville.syrjala@linux.intel.com (cherry picked from commit f70f8153e3642337b444fbc0c64d546a46bbcd62 drm-tip) Signed-off-by: Chia-Lin Kao (AceLan) --- drivers/gpu/drm/i915/display/intel_connector.c | 2 +- drivers/gpu/drm/i915/display/intel_panel.c | 7 +++++++ drivers/gpu/drm/i915/display/intel_panel.h | 1 + 3 files changed, 9 insertions(+), 1 deletion(-) diff --git a/drivers/gpu/drm/i915/display/intel_connector.c b/drivers/gpu/drm/i915/display/intel_connector.c index 6d5cbeb8df4da..8bb296f3d6252 100644 --- a/drivers/gpu/drm/i915/display/intel_connector.c +++ b/drivers/gpu/drm/i915/display/intel_connector.c @@ -54,7 +54,7 @@ int intel_connector_init(struct intel_connector *connector) __drm_atomic_helper_connector_reset(&connector->base, &conn_state->base); - INIT_LIST_HEAD(&connector->panel.fixed_modes); + intel_panel_init_alloc(connector); return 0; } diff --git a/drivers/gpu/drm/i915/display/intel_panel.c b/drivers/gpu/drm/i915/display/intel_panel.c index 41cec9dc42231..8d48e3ac44342 100644 --- a/drivers/gpu/drm/i915/display/intel_panel.c +++ b/drivers/gpu/drm/i915/display/intel_panel.c @@ -647,6 +647,13 @@ intel_panel_mode_valid(struct intel_connector *connector, return MODE_OK; } +void intel_panel_init_alloc(struct intel_connector *connector) +{ + struct intel_panel *panel = &connector->panel; + + INIT_LIST_HEAD(&panel->fixed_modes); +} + int intel_panel_init(struct intel_connector *connector) { struct intel_panel *panel = &connector->panel; diff --git a/drivers/gpu/drm/i915/display/intel_panel.h b/drivers/gpu/drm/i915/display/intel_panel.h index 5c5b5b7f95b6c..4b51e1c51da62 100644 --- a/drivers/gpu/drm/i915/display/intel_panel.h +++ b/drivers/gpu/drm/i915/display/intel_panel.h @@ -18,6 +18,7 @@ struct intel_connector; struct intel_crtc_state; struct intel_encoder; +void intel_panel_init_alloc(struct intel_connector *connector); int intel_panel_init(struct intel_connector *connector); void intel_panel_fini(struct intel_connector *connector); enum drm_connector_status