AnsweredAssumed Answered

How do I build the 4.1.15 kernel with FrameBuffer support?

Question asked by Michael Worster on Jan 9, 2017
Latest reply on Jan 10, 2017 by Michael Worster

I was using the latest imx_4.1.15_1.0.0_ga kernel branch and attempting to do a build using the imx_v6_v7_defconfig. Once I attempted to build the zImage target the build broke due to missing FB references. Below is a snippet of the process I used to get the code and build the defconfig/kernel


mike@mike-VirtualBox:~/fsl_test/kernel4$ git clone git:// --branch imx_4.1.15_1.0.0_ga

mike@mike-VirtualBox:~/fsl_test/kernel4$ make O=/home/mike/fsl_test/k4_output/ imx_v6_v7_defconfig
make[1]: Entering directory `/home/mike/fsl_test/k4_output'
  HOSTCC  scripts/basic/fixdep
  GEN     ./Makefile
  HOSTCC  scripts/kconfig/conf.o
  SHIPPED scripts/kconfig/
  SHIPPED scripts/kconfig/zconf.lex.c
  SHIPPED scripts/kconfig/zconf.hash.c
  HOSTCC  scripts/kconfig/
  HOSTLD  scripts/kconfig/conf
# configuration written to .config
make[1]: Leaving directory `/home/mike/fsl_test/k4_output'
mike@mike-VirtualBox:~/fsl_test/kernel4$ make O=/home/mike/fsl_test/k4_output/ zImage LOADADDR=0x10008000
make[1]: Entering directory `/home/mike/fsl_test/k4_output'
  GEN     ./Makefile
scripts/kconfig/conf  --silentoldconfig Kconfig
make[1]: Leaving directory `/home/mike/fsl_test/k4_output'
make[1]: Entering directory `/home/mike/fsl_test/k4_output'
  CHK     include/config/kernel.release


  UPD     include/generated/compile.h
  CC      init/version.o
  LD      init/built-in.o

drivers/built-in.o: In function `mxsfb_probe':
:(.text+0x45f4c): undefined reference to `mxc_dispdrv_gethandle'
make[1]: *** [vmlinux] Error 1



I've found that the missing reference comes from drivers/video/fbdev/mxc/mxc_dispdrv.c and can be added in by including:


to the defconfig, once that is in place there are additional build issues that show up:


drivers/built-in.o: In function `mxcfb_blank':
:(.text+0x43674): undefined reference to `ipu_disable_channel'
:(.text+0x43688): undefined reference to `ipu_uninit_sync_panel'
:(.text+0x43694): undefined reference to `ipu_uninit_channel'


Which can be fixed by adding in:


Once that is added there is a new problem, as both drivers/mxc/ipu3/ipu_capture.c and drivers/gpu/ipu-v3/ipu-csi.c include the same "exports" and thus there is a multiple definition issue:


drivers/mxc/built-in.o: In function `ipu_csi_init_interface':
:(.text+0x12f18): multiple definition of `ipu_csi_init_interface'
drivers/gpu/built-in.o::(.text+0x3a4fc): first defined here
drivers/mxc/built-in.o:(___ksymtab+ipu_csi_init_interface+0x0): multiple definition of `__ksymtab_ipu_csi_init_interface'
drivers/gpu/built-in.o:(___ksymtab_gpl+ipu_csi_init_interface+0x0): first defined here
drivers/mxc/built-in.o: In function `__crc_ipu_csi_init_interface':

... (A number of these)



(One example:)

drivers/mxc/ipu3/ipu_capture.c:ipu_csi_init_interface(struct ipu_soc *ipu, uint16_t width, uint16_t height,
drivers/gpu/ipu-v3/ipu-csi.c:int ipu_csi_init_interface(struct ipu_csi *csi,


So my question becomes:

How can I do a standard Linux Kernel 4.1.15 build with the imx_v6_v7_defconfig which includes Framebuffer support? Seems either I'm missing something, or there is something wrong with this config.