From: Vincent Abriou <vincent.abriou@st.com>
To: dri-devel@lists.freedesktop.org
Cc: Nicolas VANHAELEWYN <nicolas.vanhaelewyn@st.com>,
Vincent Abriou <vincent.abriou@st.com>,
Fabien Dessenne <fabien.dessenne@st.com>,
Benjamin Gaignard <benjamin.gaignard@linaro.org>
Subject: [PATCH 1/1] drm/sti: enable fbdev compatibility through module param
Date: Thu, 29 Oct 2015 14:02:29 +0100 [thread overview]
Message-ID: <1446123749-7525-1-git-send-email-vincent.abriou@st.com> (raw)
DRM_STI_FBDEV is removed and replaced by the fbdev module param.
By default, the fbdev compatibility is disabled.
Signed-off-by: Vincent Abriou <vincent.abriou@st.com>
Signed-off-by: Nicolas VANHAELEWYN <nicolas.vanhaelewyn@st.com>
---
drivers/gpu/drm/sti/Kconfig | 6 ------
drivers/gpu/drm/sti/sti_drv.c | 15 ++++++++++-----
2 files changed, 10 insertions(+), 11 deletions(-)
diff --git a/drivers/gpu/drm/sti/Kconfig b/drivers/gpu/drm/sti/Kconfig
index 0a9048c..3f8d590 100644
--- a/drivers/gpu/drm/sti/Kconfig
+++ b/drivers/gpu/drm/sti/Kconfig
@@ -10,9 +10,3 @@ config DRM_STI
select FW_LOADER_USER_HELPER_FALLBACK
help
Choose this option to enable DRM on STM stiH41x chipset
-
-config DRM_STI_FBDEV
- bool "DRM frame buffer device for STMicroelectronics SoC stiH41x Serie"
- depends on DRM_STI
- help
- Choose this option to enable FBDEV on top of DRM for STM stiH41x chipset
diff --git a/drivers/gpu/drm/sti/sti_drv.c b/drivers/gpu/drm/sti/sti_drv.c
index e19c173..d47b025 100644
--- a/drivers/gpu/drm/sti/sti_drv.c
+++ b/drivers/gpu/drm/sti/sti_drv.c
@@ -30,6 +30,11 @@
#define STI_MAX_FB_HEIGHT 4096
#define STI_MAX_FB_WIDTH 4096
+/* Module parameter to enable fbdev compatibility */
+static bool fbdev_enabled;
+MODULE_PARM_DESC(fbdev, "Enable fbdev compatibility layer");
+module_param_named(fbdev, fbdev_enabled, bool, 0644);
+
static void sti_atomic_schedule(struct sti_private *private,
struct drm_atomic_state *state)
{
@@ -160,11 +165,11 @@ static int sti_load(struct drm_device *dev, unsigned long flags)
drm_mode_config_reset(dev);
-#ifdef CONFIG_DRM_STI_FBDEV
- drm_fbdev_cma_init(dev, 32,
- dev->mode_config.num_crtc,
- dev->mode_config.num_connector);
-#endif
+ if (fbdev_enabled)
+ drm_fbdev_cma_init(dev, 32,
+ dev->mode_config.num_crtc,
+ dev->mode_config.num_connector);
+
return 0;
}
--
1.9.1
_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/dri-devel
next reply other threads:[~2015-10-29 13:03 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-10-29 13:02 Vincent Abriou [this message]
2015-10-30 10:38 ` [PATCH 1/1] drm/sti: enable fbdev compatibility through module param Daniel Vetter
2015-10-30 12:22 ` Vincent ABRIOU
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1446123749-7525-1-git-send-email-vincent.abriou@st.com \
--to=vincent.abriou@st.com \
--cc=benjamin.gaignard@linaro.org \
--cc=dri-devel@lists.freedesktop.org \
--cc=fabien.dessenne@st.com \
--cc=nicolas.vanhaelewyn@st.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox