From patchwork Tue Feb 6 15:39:08 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Imre Deak X-Patchwork-Id: 13547540 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 9D7CFC48297 for ; Tue, 6 Feb 2024 15:38:54 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id EE89610EFD6; Tue, 6 Feb 2024 15:38:53 +0000 (UTC) Authentication-Results: gabe.freedesktop.org; dkim=pass (2048-bit key; unprotected) header.d=intel.com header.i=@intel.com header.b="KUOkBvLS"; dkim-atps=neutral Received: from mgamail.intel.com (mgamail.intel.com [198.175.65.17]) by gabe.freedesktop.org (Postfix) with ESMTPS id 64E7110EFD6 for ; Tue, 6 Feb 2024 15:38:53 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1707233934; x=1738769934; h=from:to:subject:date:message-id:mime-version: content-transfer-encoding; bh=eThw1e+mfk/O9+d/aFFiSujqObBDhjG9UKEcn1Ih4NU=; b=KUOkBvLS0Jm0R0K8r4JcdXUOp4kbtctCyQDpf+nsLruO3Zx9bhpghupl BPZnbx6FkVXQ4fsgToWdmDswIAels/jXLz8pp070rbc2XPR1kiM0GUjbn LQhnuE9wdJ2x1BBsJusKVmXy2GwGIT4fGDJm1pBb5fCnxFYPmWk0mjv8t T6KpewTwRzEXBKSgaNdd5TQS2O3p8Rn3AWERkqvNIs02cFQ5wY9lQFh8w H2hWZCxdwjmFmG0QDemgi23hhR96hemPvLfN1OXT0EKxp2TER0oYY049e tZA215oh/RDO9iFaYjOUQegYMmO75ykiAp/uqUSNaholBNqCvhrnsz5iB g==; X-IronPort-AV: E=McAfee;i="6600,9927,10976"; a="914702" X-IronPort-AV: E=Sophos;i="6.05,247,1701158400"; d="scan'208";a="914702" Received: from orviesa005.jf.intel.com ([10.64.159.145]) by orvoesa109.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 06 Feb 2024 07:38:54 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="6.05,247,1701158400"; d="scan'208";a="5652240" Received: from unknown (HELO ideak-desk.fi.intel.com) ([10.237.66.155]) by orviesa005-auth.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 06 Feb 2024 07:38:52 -0800 From: Imre Deak To: intel-gfx@lists.freedesktop.org Subject: [PATCH 0/2] drm/i915: Prevent HW access during init from connector hooks Date: Tue, 6 Feb 2024 17:39:08 +0200 Message-Id: <20240206153910.1758057-1-imre.deak@intel.com> X-Mailer: git-send-email 2.39.2 MIME-Version: 1.0 X-BeenThere: intel-gfx@lists.freedesktop.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Intel graphics driver community testing & development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: intel-gfx-bounces@lists.freedesktop.org Sender: "Intel-gfx" Accessing the display HW from the connector get_modes hooks should be prevented during driver init/shutdown similarly to how this is done in the encoder detect hooks and modeset as explained in the following commits: drm/i915: Prevent modesets during driver init/shutdown drm/i915: Disable hotplug detection works during driver init/shutdown drm/i915: Disable hotplug detection handlers during driver init/shutdown For the DP-SST/HDMI connectors the above is already ensured, since for these the required HW access - to read out the display's EDID - happens in the encoders' detect hook, however other connectors do a corresponding detection/HW access from the connector get_modes hook. Disable the access during init/shutdown from these hooks as well. Imre Deak (2): drm/i915: Prevent HW access during init from SDVO TV get_modes hook drm/i915: Prevent HW access during init from connector get_modes hooks drivers/gpu/drm/i915/display/intel_crt.c | 7 +++++++ drivers/gpu/drm/i915/display/intel_dp_mst.c | 4 ++++ drivers/gpu/drm/i915/display/intel_dvo.c | 5 +++++ drivers/gpu/drm/i915/display/intel_sdvo.c | 8 ++++++++ 4 files changed, 24 insertions(+)