All of lore.kernel.org
 help / color / mirror / Atom feed
* [superna9999:amlogic/v5.9/ge2d 1/1] drivers/media/platform/meson/ge2d/ge2d.c:176:8: error: implicit declaration of function 'FIELD_PREP'
@ 2020-09-15  1:09 kernel test robot
  0 siblings, 0 replies; only message in thread
From: kernel test robot @ 2020-09-15  1:09 UTC (permalink / raw)
  To: kbuild-all

[-- Attachment #1: Type: text/plain, Size: 6660 bytes --]

tree:   https://github.com/superna9999/linux amlogic/v5.9/ge2d
head:   b1a66509dd93057c3a3adb449e0a4417aebc1fe5
commit: b1a66509dd93057c3a3adb449e0a4417aebc1fe5 [1/1] media: meson: add Amlogic GE2D 2D Accelerator driver
config: riscv-allmodconfig (attached as .config)
compiler: riscv64-linux-gcc (GCC) 9.3.0
reproduce (this is a W=1 build):
        wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
        chmod +x ~/bin/make.cross
        git checkout b1a66509dd93057c3a3adb449e0a4417aebc1fe5
        # save the attached .config to linux build tree
        COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-9.3.0 make.cross ARCH=riscv 

If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp@intel.com>

All errors (new ones prefixed by >>):

   drivers/media/platform/meson/ge2d/ge2d.c: In function 'ge2d_hw_start':
>> drivers/media/platform/meson/ge2d/ge2d.c:176:8: error: implicit declaration of function 'FIELD_PREP' [-Werror=implicit-function-declaration]
     176 |        FIELD_PREP(GE2D_INTERRUPT_CTRL, 2) |
         |        ^~~~~~~~~~
   cc1: some warnings being treated as errors

# https://github.com/superna9999/linux/commit/b1a66509dd93057c3a3adb449e0a4417aebc1fe5
git remote add superna9999 https://github.com/superna9999/linux
git fetch --no-tags superna9999 amlogic/v5.9/ge2d
git checkout b1a66509dd93057c3a3adb449e0a4417aebc1fe5
vim +/FIELD_PREP +176 drivers/media/platform/meson/ge2d/ge2d.c

   146	
   147	static void ge2d_hw_start(struct meson_ge2d *ge2d)
   148	{
   149		struct ge2d_ctx *ctx = ge2d->curr;
   150		u32 reg;
   151	
   152		/* Reset */
   153		regmap_update_bits(ge2d->map, GE2D_GEN_CTRL1 << 2,
   154				   GE2D_SOFT_RST, GE2D_SOFT_RST);
   155		regmap_update_bits(ge2d->map, GE2D_GEN_CTRL1 << 2,
   156				   GE2D_SOFT_RST, 0);
   157	
   158		udelay(100);
   159	
   160		/* Implement CANVAS for non-AXG */
   161		regmap_write(ge2d->map, GE2D_SRC1_BADDR_CTRL << 2,
   162			     (vb2_dma_contig_plane_dma_addr(&ctx->in.buf->vb2_buf, 0) + 7) >> 3);
   163		regmap_write(ge2d->map, GE2D_SRC1_STRIDE_CTRL << 2,
   164			     (ctx->in.stride + 7) >> 3);
   165		regmap_write(ge2d->map, GE2D_SRC2_BADDR_CTRL << 2,
   166			     (vb2_dma_contig_plane_dma_addr(&ctx->out.buf->vb2_buf, 0) + 7) >> 3);
   167		regmap_write(ge2d->map, GE2D_SRC2_STRIDE_CTRL << 2,
   168			     (ctx->out.stride + 7) >> 3);
   169		regmap_write(ge2d->map, GE2D_DST1_BADDR_CTRL << 2,
   170			     (vb2_dma_contig_plane_dma_addr(&ctx->out.buf->vb2_buf, 0) + 7) >> 3);
   171		regmap_write(ge2d->map, GE2D_DST1_STRIDE_CTRL << 2,
   172			     (ctx->out.stride + 7) >> 3);
   173	
   174		regmap_write(ge2d->map, GE2D_GEN_CTRL0 << 2, 0);
   175		regmap_write(ge2d->map, GE2D_GEN_CTRL1 << 2,
 > 176			     FIELD_PREP(GE2D_INTERRUPT_CTRL, 2) |
   177			     FIELD_PREP(GE2D_SRC2_BURST_SIZE_CTRL, 3) |
   178			     FIELD_PREP(GE2D_SRC1_BURST_SIZE_CTRL, 0x3f));
   179		regmap_write(ge2d->map, GE2D_GEN_CTRL2 << 2,
   180			     FIELD_PREP(GE2D_DST1_COLOR_MAP, ctx->out.fmt->hw_map) |
   181			     FIELD_PREP(GE2D_DST1_FORMAT, ctx->out.fmt->hw_fmt) |
   182			     FIELD_PREP(GE2D_SRC2_COLOR_MAP, ctx->out.fmt->hw_map) |
   183			     FIELD_PREP(GE2D_SRC2_FORMAT, ctx->out.fmt->hw_fmt) |
   184			     FIELD_PREP(GE2D_SRC1_COLOR_MAP, ctx->in.fmt->hw_map) |
   185			     FIELD_PREP(GE2D_SRC1_FORMAT, ctx->in.fmt->hw_fmt));
   186		regmap_write(ge2d->map, GE2D_GEN_CTRL3 << 2,
   187			     GE2D_DST1_ENABLE);
   188	
   189		regmap_write(ge2d->map, GE2D_SRC1_CLIPX_START_END << 2,
   190			     FIELD_PREP(GE2D_START, ctx->in.crop.top) |
   191			     FIELD_PREP(GE2D_END, ctx->in.crop.top + ctx->in.crop.height));
   192		regmap_write(ge2d->map, GE2D_SRC1_CLIPY_START_END << 2,
   193			     FIELD_PREP(GE2D_START, ctx->in.crop.left) |
   194			     FIELD_PREP(GE2D_END, ctx->in.crop.left + ctx->in.crop.width));
   195		regmap_write(ge2d->map, GE2D_SRC2_CLIPX_START_END << 2,
   196			     FIELD_PREP(GE2D_START, ctx->out.crop.top) |
   197			     FIELD_PREP(GE2D_END, ctx->out.crop.top + ctx->out.crop.height));
   198		regmap_write(ge2d->map, GE2D_SRC2_CLIPY_START_END << 2,
   199			     FIELD_PREP(GE2D_START, ctx->out.crop.left) |
   200			     FIELD_PREP(GE2D_END, ctx->out.crop.left + ctx->out.crop.width));
   201		regmap_write(ge2d->map, GE2D_DST_CLIPX_START_END << 2,
   202			     FIELD_PREP(GE2D_START, ctx->out.crop.top) |
   203			     FIELD_PREP(GE2D_END, ctx->out.crop.top + ctx->out.crop.height));
   204		regmap_write(ge2d->map, GE2D_DST_CLIPY_START_END << 2,
   205			     FIELD_PREP(GE2D_START, ctx->out.crop.left) |
   206			     FIELD_PREP(GE2D_END, ctx->out.crop.left + ctx->out.crop.width));
   207	
   208		regmap_write(ge2d->map, GE2D_SRC1_X_START_END << 2,
   209			     FIELD_PREP(GE2D_END, ctx->in.height));
   210		regmap_write(ge2d->map, GE2D_SRC1_Y_START_END << 2,
   211			     FIELD_PREP(GE2D_END, ctx->in.width));
   212		regmap_write(ge2d->map, GE2D_SRC2_X_START_END << 2,
   213			     FIELD_PREP(GE2D_END, ctx->out.height));
   214		regmap_write(ge2d->map, GE2D_SRC2_Y_START_END << 2,
   215			     FIELD_PREP(GE2D_END, ctx->out.width));
   216		regmap_write(ge2d->map, GE2D_DST_X_START_END << 2,
   217			     FIELD_PREP(GE2D_END, ctx->out.height));
   218		regmap_write(ge2d->map, GE2D_DST_Y_START_END << 2,
   219			     FIELD_PREP(GE2D_END, ctx->out.width));
   220	
   221		/* Color, no blend, use source color */
   222		reg = GE2D_ALU_DO_COLOR_OPERATION_LOGIC(LOGIC_OPERATION_COPY,
   223							COLOR_FACTOR_SRC_COLOR);
   224	
   225		if (ctx->in.fmt->alpha && ctx->out.fmt->alpha)
   226			/* Take source alpha */
   227			reg |= GE2D_ALU_DO_ALPHA_OPERATION_LOGIC(LOGIC_OPERATION_COPY,
   228								 COLOR_FACTOR_SRC_ALPHA);
   229		else if (!ctx->out.fmt->alpha)
   230			/* Set alpha to 0 */
   231			reg |= GE2D_ALU_DO_ALPHA_OPERATION_LOGIC(LOGIC_OPERATION_SET,
   232								 COLOR_FACTOR_ZERO);
   233		else
   234			/* Keep original alpha */
   235			reg |= GE2D_ALU_DO_ALPHA_OPERATION_LOGIC(LOGIC_OPERATION_COPY,
   236								 COLOR_FACTOR_DST_ALPHA);
   237	
   238		regmap_write(ge2d->map, GE2D_ALU_OP_CTRL << 2, reg);
   239	
   240		/* Start */
   241		regmap_write(ge2d->map, GE2D_CMD_CTRL << 2,
   242			     (ctx->hflip ? GE2D_SRC1_Y_REV : 0) |
   243			     (ctx->vflip ? GE2D_SRC1_X_REV : 0) |
   244			     GE2D_CBUS_CMD_WR);
   245	}
   246	

---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all(a)lists.01.org

[-- Attachment #2: config.gz --]
[-- Type: application/gzip, Size: 65932 bytes --]

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2020-09-15  1:09 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-09-15  1:09 [superna9999:amlogic/v5.9/ge2d 1/1] drivers/media/platform/meson/ge2d/ge2d.c:176:8: error: implicit declaration of function 'FIELD_PREP' kernel test robot

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.