From nobody Wed Dec 17 06:33:57 2025 Received: from mail.manjaro.org (mail.manjaro.org [116.203.91.91]) (using TLSv1.2 with cipher DHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 091C1196DA4; Mon, 17 Jun 2024 20:22:17 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=116.203.91.91 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1718655740; cv=none; b=Eq3BXExS9HgzG5Lq3JNMb3Eta0E4P3CIt1NEWwic3EMeqSgW3dGfa6NNZ4SMlSxSaGP1XQRN7LFvE3P6bP4Bt7jxc0lQtC/aRQth6gMgMoRRFcl7l5bgUKFNgfI5o+aTq12PeGiAvL3pD3Jowxy2toaUAQbfIzu1vJijdDgB4YQ= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1718655740; c=relaxed/simple; bh=lDmE6Oc99oUhAcr5WIwumgLA+GcsneQdxF8Anei0cF8=; h=From:To:Cc:Subject:Date:Message-Id:MIME-Version:Content-Type; b=FuEASu9ybcKBe8Q+wYaWqG8y72wD9uoRUevhEYJrZJQrMbOPppiSn8mcanMDhmxZ+q/0VXM0BXDijhmz/xGV7VhJMgx6rqTyb2RWylHwu+N7SxcBGnVNmc+c53cr7QCNmilUlo8vd6osplvzBH7KsSSxKzRyln1fRG93ivPnoUs= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=manjaro.org; spf=pass smtp.mailfrom=manjaro.org; dkim=pass (2048-bit key) header.d=manjaro.org header.i=@manjaro.org header.b=ijh+uWnh; arc=none smtp.client-ip=116.203.91.91 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=manjaro.org Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=manjaro.org Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=manjaro.org header.i=@manjaro.org header.b="ijh+uWnh" From: Dragan Simic DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=manjaro.org; s=2021; t=1718655735; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=KE0itf7SPq2y4IgF/9FfRchQi+X27+0vxz0kqB+YZMM=; b=ijh+uWnh8LENHexsTozHC6SCsZIJn8G4mw7xG0hs93oJN1KIgpWNCrQ67kUjpTIq8E+K2G lbJPkDV0kis73ZrBp0t/RC2PvLK5IyiPq2a4ZDeBxcbTUeD71na3sUM+X3Wu/xeSbVf6J3 2o4eZVyURX04DEc4qpGkAdxAmhasS6WyyYbbcZq+GDt6sTAnwMXXfZfUUnrs/cwiaEUXiZ mG4rSG7QBXwqWLoFsvJ5JusfPzew6UIw6yXaKRHTk9FRB/0e7Zydl8BujE2WPcmFy2hS5L G7GHchrWa0t8/mPid2Vj2P8Ebxul08P+4FTC8gwPdIUQRblg+GHU0mjSe+H5eQ== To: dri-devel@lists.freedesktop.org, lima@lists.freedesktop.org Cc: yuq825@gmail.com, maarten.lankhorst@linux.intel.com, mripard@kernel.org, tzimmermann@suse.de, airlied@gmail.com, daniel@ffwll.ch, linux-kernel@vger.kernel.org, Philip Muller , Oliver Smith , Daniel Smith , stable@vger.kernel.org Subject: [PATCH] drm/lima: Mark simple_ondemand governor as softdep Date: Mon, 17 Jun 2024 22:22:02 +0200 Message-Id: Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Authentication-Results: ORIGINATING; auth=pass smtp.auth=dsimic@manjaro.org smtp.mailfrom=dsimic@manjaro.org Content-Type: text/plain; charset="utf-8" Lima DRM driver uses devfreq to perform DVFS, while using simple_ondemand devfreq governor by default. This causes driver initialization to fail on boot when simple_ondemand governor isn't built into the kernel statically, as a result of the missing module dependency and, consequently, the required governor module not being included in the initial ramdisk. Thus, let's mark simple_ondemand governor as a softdep for Lima, to have its kernel module included in the initial ramdisk. This is a rather longstanding issue that has forced distributions to build devfreq governors statically into their kernels, [1][2] or may have forced some users to introduce unnecessary workarounds. Having simple_ondemand marked as a softdep for Lima may not resolve this issue for all Linux distributions. In particular, it will remain unresolved for the distributions whose utilities for the initial ramdisk generation do not handle the available softdep information [3] properly yet. However, so= me Linux distributions already handle softdeps properly while generating their initial ramdisks, [4] and this is a prerequisite step in the right direction for the distributions that don't handle them properly yet. [1] https://gitlab.manjaro.org/manjaro-arm/packages/core/linux-pinephone/-/= blob/6.7-megi/config?ref_type=3Dheads#L5749 [2] https://gitlab.com/postmarketOS/pmaports/-/blob/7f64e287e7732c9eaa02965= 3e73ca3d4ba1c8598/main/linux-postmarketos-allwinner/config-postmarketos-all= winner.aarch64#L4654 [3] https://git.kernel.org/pub/scm/utils/kernel/kmod/kmod.git/commit/?id=3D= 49d8e0b59052999de577ab732b719cfbeb89504d [4] https://github.com/archlinux/mkinitcpio/commit/97ac4d37aae084a050be512f= 6d8f4489054668ad Cc: Philip Muller Cc: Oliver Smith Cc: Daniel Smith Cc: stable@vger.kernel.org Fixes: 1996970773a3 ("drm/lima: Add optional devfreq and cooling device sup= port") Signed-off-by: Dragan Simic --- drivers/gpu/drm/lima/lima_drv.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/gpu/drm/lima/lima_drv.c b/drivers/gpu/drm/lima/lima_dr= v.c index 739c865b556f..10bce18b7c31 100644 --- a/drivers/gpu/drm/lima/lima_drv.c +++ b/drivers/gpu/drm/lima/lima_drv.c @@ -501,3 +501,4 @@ module_platform_driver(lima_platform_driver); MODULE_AUTHOR("Lima Project Developers"); MODULE_DESCRIPTION("Lima DRM Driver"); MODULE_LICENSE("GPL v2"); +MODULE_SOFTDEP("pre: governor_simpleondemand");