[linux-next:master 2997/5501] drivers/media/i2c/imx283.c:443:30: error: initializer element is not a compile-time constant

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



tree:   https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git master
head:   6906a84c482f098d31486df8dc98cead21cce2d0
commit: ccb4eb4496fa94a9131c63ad0c412ebfe7f9ac35 [2997/5501] media: i2c: Add imx283 camera sensor driver
config: arm-randconfig-003-20240616 (https://download.01.org/0day-ci/archive/20240616/202406160153.RvEj9c4I-lkp@xxxxxxxxx/config)
compiler: clang version 16.0.6 (https://github.com/llvm/llvm-project 7cbf1a2591520c2491aa35339f227775f4d3adf6)
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20240616/202406160153.RvEj9c4I-lkp@xxxxxxxxx/reproduce)

If you fix the issue in a separate patch/commit (i.e. not just a new version of
the same patch/commit), kindly add following tags
| Reported-by: kernel test robot <lkp@xxxxxxxxx>
| Closes: https://lore.kernel.org/oe-kbuild-all/202406160153.RvEj9c4I-lkp@xxxxxxxxx/

All errors (new ones prefixed by >>):

>> drivers/media/i2c/imx283.c:443:30: error: initializer element is not a compile-time constant
                   .crop = CENTERED_RECTANGLE(imx283_active_area, 5472, 3648),
                           ~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
   drivers/media/i2c/imx283.c:412:11: note: expanded from macro 'CENTERED_RECTANGLE'
                   .left = rect.left + ((rect.width - (_width)) / 2),      \
                           ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
   drivers/media/i2c/imx283.c:492:30: error: initializer element is not a compile-time constant
                   .crop = CENTERED_RECTANGLE(imx283_active_area, 5472, 3648),
                           ~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
   drivers/media/i2c/imx283.c:412:11: note: expanded from macro 'CENTERED_RECTANGLE'
                   .left = rect.left + ((rect.width - (_width)) / 2),      \
                           ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
   2 errors generated.


vim +443 drivers/media/i2c/imx283.c

   409	
   410	#define CENTERED_RECTANGLE(rect, _width, _height)			\
   411		{								\
   412			.left = rect.left + ((rect.width - (_width)) / 2),	\
   413			.top = rect.top + ((rect.height - (_height)) / 2),	\
   414			.width = (_width),					\
   415			.height = (_height),					\
   416		}
   417	
   418	/* Mode configs */
   419	static const struct imx283_mode supported_modes_12bit[] = {
   420		{
   421			/* 20MPix 21.40 fps readout mode 0 */
   422			.mode = IMX283_MODE_0,
   423			.bpp = 12,
   424			.width = 5472,
   425			.height = 3648,
   426			.min_hmax = 5914, /* 887 @ 480MHz/72MHz */
   427			.min_vmax = 3793, /* Lines */
   428	
   429			.veff = 3694,
   430			.vst = 0,
   431			.vct = 0,
   432	
   433			.hbin_ratio = 1,
   434			.vbin_ratio = 1,
   435	
   436			/* 20.00 FPS */
   437			.default_hmax = 6000, /* 900 @ 480MHz/72MHz */
   438			.default_vmax = 4000,
   439	
   440			.min_shr = 11,
   441			.horizontal_ob = 96,
   442			.vertical_ob = 16,
 > 443			.crop = CENTERED_RECTANGLE(imx283_active_area, 5472, 3648),
   444		},
   445		{
   446			/*
   447			 * Readout mode 2 : 2/2 binned mode (2736x1824)
   448			 */
   449			.mode = IMX283_MODE_2,
   450			.bpp = 12,
   451			.width = 2736,
   452			.height = 1824,
   453			.min_hmax = 2414, /* Pixels (362 * 480MHz/72MHz + padding) */
   454			.min_vmax = 3840, /* Lines */
   455	
   456			/* 50.00 FPS */
   457			.default_hmax = 2500, /* 375 @ 480MHz/72Mhz */
   458			.default_vmax = 3840,
   459	
   460			.veff = 1824,
   461			.vst = 0,
   462			.vct = 0,
   463	
   464			.hbin_ratio = 2,
   465			.vbin_ratio = 2,
   466	
   467			.min_shr = 12,
   468			.horizontal_ob = 48,
   469			.vertical_ob = 4,
   470	
   471			.crop = CENTERED_RECTANGLE(imx283_active_area, 5472, 3648),
   472		},
   473	};
   474	

-- 
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki




[Index of Archives]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [IETF Annouce]     [Bugtraq]     [Linux OMAP]     [Linux MIPS]     [eCos]     [Asterisk Internet PBX]     [Linux API]

  Powered by Linux