From: Anatolij Gustschin <agust@denx.de>
To: u-boot@lists.denx.de
Subject: [PATCH] video: ipuv3: remove non-DM code
Date: Tue, 26 May 2020 12:03:22 +0200 [thread overview]
Message-ID: <20200526100322.12259-5-agust@denx.de> (raw)
In-Reply-To: <20200526100322.12259-1-agust@denx.de>
All ipuv3 users have been converted, drop obsolete code.
Signed-off-by: Anatolij Gustschin <agust@denx.de>
---
drivers/video/imx/Kconfig | 2 +-
drivers/video/imx/mxc_ipuv3_fb.c | 43 --------------------------------
2 files changed, 1 insertion(+), 44 deletions(-)
diff --git a/drivers/video/imx/Kconfig b/drivers/video/imx/Kconfig
index c33620e075..78eb0f29fb 100644
--- a/drivers/video/imx/Kconfig
+++ b/drivers/video/imx/Kconfig
@@ -1,7 +1,7 @@
config VIDEO_IPUV3
bool "i.MX IPUv3 Core video support"
- depends on (VIDEO || DM_VIDEO) && (MX5 || MX6)
+ depends on DM_VIDEO && (MX5 || MX6)
help
This enables framebuffer driver for i.MX processors working
on the IPUv3(Image Processing Unit) internal graphic processor.
diff --git a/drivers/video/imx/mxc_ipuv3_fb.c b/drivers/video/imx/mxc_ipuv3_fb.c
index 017a8fb22a..f1ab7a8375 100644
--- a/drivers/video/imx/mxc_ipuv3_fb.c
+++ b/drivers/video/imx/mxc_ipuv3_fb.c
@@ -38,10 +38,6 @@ DECLARE_GLOBAL_DATA_PTR;
static int mxcfb_map_video_memory(struct fb_info *fbi);
static int mxcfb_unmap_video_memory(struct fb_info *fbi);
-#if !CONFIG_IS_ENABLED(DM_VIDEO)
-/* graphics setup */
-static GraphicDevice panel;
-#endif
static struct fb_videomode const *gmode;
static uint8_t gdisp;
static uint32_t gpixfmt;
@@ -391,12 +387,7 @@ static int mxcfb_map_video_memory(struct fb_info *fbi)
}
fbi->fix.smem_len = roundup(fbi->fix.smem_len, ARCH_DMA_MINALIGN);
-#if CONFIG_IS_ENABLED(DM_VIDEO)
fbi->screen_base = (char *)gd->video_bottom;
-#else
- fbi->screen_base = (char *)memalign(ARCH_DMA_MINALIGN,
- fbi->fix.smem_len);
-#endif
fbi->fix.smem_start = (unsigned long)fbi->screen_base;
if (fbi->screen_base == 0) {
@@ -410,10 +401,7 @@ static int mxcfb_map_video_memory(struct fb_info *fbi)
(uint32_t) fbi->fix.smem_start, fbi->fix.smem_len);
fbi->screen_size = fbi->fix.smem_len;
-
-#if CONFIG_IS_ENABLED(VIDEO)
gd->fb_base = fbi->fix.smem_start;
-#endif
/* Clear the screen */
memset((char *)fbi->screen_base, 0, fbi->fix.smem_len);
@@ -543,18 +531,6 @@ static int mxcfb_probe(u32 interface_pix_fmt, uint8_t disp,
mxcfb_set_par(fbi);
-#if !CONFIG_IS_ENABLED(DM_VIDEO)
- panel.winSizeX = mode->xres;
- panel.winSizeY = mode->yres;
- panel.plnSizeX = mode->xres;
- panel.plnSizeY = mode->yres;
-
- panel.frameAdrs = (u32)fbi->screen_base;
- panel.memSize = fbi->screen_size;
-
- panel.gdfBytesPP = 2;
- panel.gdfIndex = GDF_16BIT_565RGB;
-#endif
#ifdef DEBUG
ipu_dump_registers();
#endif
@@ -584,23 +560,6 @@ void ipuv3_fb_shutdown(void)
}
}
-#if !CONFIG_IS_ENABLED(DM_VIDEO)
-void *video_hw_init(void)
-{
- int ret;
-
- ret = ipu_probe();
- if (ret)
- puts("Error initializing IPU\n");
-
- ret = mxcfb_probe(gpixfmt, gdisp, gmode);
- debug("Framebuffer at 0x%x\n", (unsigned int)panel.frameAdrs);
- gd->fb_base = panel.frameAdrs;
-
- return (void *)&panel;
-}
-#endif
-
int ipuv3_fb_init(struct fb_videomode const *mode,
uint8_t disp,
uint32_t pixfmt)
@@ -612,7 +571,6 @@ int ipuv3_fb_init(struct fb_videomode const *mode,
return 0;
}
-#if CONFIG_IS_ENABLED(DM_VIDEO)
enum {
/* Maximum display size we support */
LCD_MAX_WIDTH = 1920,
@@ -710,4 +668,3 @@ U_BOOT_DRIVER(ipuv3_video) = {
.priv_auto_alloc_size = sizeof(struct ipuv3_video_priv),
.flags = DM_FLAG_PRE_RELOC,
};
-#endif /* CONFIG_DM_VIDEO */
--
2.17.1
next prev parent reply other threads:[~2020-05-26 10:03 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-05-26 10:03 [PATCH] apalis_imx6: fix video stdout in default environment Anatolij Gustschin
2020-05-26 10:03 ` [PATCH] cm_fx6: " Anatolij Gustschin
2020-06-19 13:38 ` Anatolij Gustschin
2020-05-26 10:03 ` [PATCH] colibri_imx6: " Anatolij Gustschin
2020-05-26 20:54 ` [PATCH v2] " Anatolij Gustschin
2020-05-28 16:06 ` Igor Opaniuk
2020-06-19 13:37 ` Anatolij Gustschin
2020-05-26 10:03 ` [PATCH] nitrogen6x: update video console name Anatolij Gustschin
2020-05-26 15:22 ` Troy Kisky
2020-06-19 13:39 ` Anatolij Gustschin
2020-05-26 10:03 ` Anatolij Gustschin [this message]
2020-05-26 20:52 ` [PATCH v2] apalis_imx6: fix video stdout in default environment Anatolij Gustschin
2020-05-28 16:07 ` Igor Opaniuk
2020-06-19 13:36 ` Anatolij Gustschin
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=20200526100322.12259-5-agust@denx.de \
--to=agust@denx.de \
--cc=u-boot@lists.denx.de \
/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