[PATCH] drm/gma500: Remove unused 'psbfb' variable

kbuild test robot lkp at intel.com
Thu Jun 21 17:33:31 UTC 2018


Hi Ville,

Thank you for the patch! Yet something to improve:

[auto build test ERROR on drm/drm-next]
[also build test ERROR on v4.18-rc1 next-20180621]
[if your patch is applied to the wrong git tree, please drop us a note to help improve the system]

url:    https://github.com/0day-ci/linux/commits/Ville-Syrjala/drm-gma500-Remove-unused-psbfb-variable/20180622-004333
base:   git://people.freedesktop.org/~airlied/linux.git drm-next
config: x86_64-allyesconfig (attached as .config)
compiler: gcc-7 (Debian 7.3.0-16) 7.3.0
reproduce:
        # save the attached .config to linux build tree
        make ARCH=x86_64 

All errors (new ones prefixed by >>):

   drivers/gpu//drm/gma500/mdfld_intel_display.c: In function 'mdfld__intel_pipe_set_base':
>> drivers/gpu//drm/gma500/mdfld_intel_display.c:198:10: error: 'psbfb' undeclared (first use in this function)
     start = psbfb->gtt->offset;
             ^~~~~
   drivers/gpu//drm/gma500/mdfld_intel_display.c:198:10: note: each undeclared identifier is reported only once for each function it appears in

vim +/psbfb +198 drivers/gpu//drm/gma500/mdfld_intel_display.c

026abc33 Kirill A. Shutemov 2012-03-08  162  
026abc33 Kirill A. Shutemov 2012-03-08  163  static int mdfld__intel_pipe_set_base(struct drm_crtc *crtc, int x, int y,
026abc33 Kirill A. Shutemov 2012-03-08  164  				struct drm_framebuffer *old_fb)
026abc33 Kirill A. Shutemov 2012-03-08  165  {
026abc33 Kirill A. Shutemov 2012-03-08  166  	struct drm_device *dev = crtc->dev;
213a8434 Alan Cox           2012-05-11  167  	struct drm_psb_private *dev_priv = dev->dev_private;
51560195 Ville Syrjälä      2016-11-18  168  	struct drm_framebuffer *fb = crtc->primary->fb;
6306865d Patrik Jakobsson   2013-07-22  169  	struct gma_crtc *gma_crtc = to_gma_crtc(crtc);
6306865d Patrik Jakobsson   2013-07-22  170  	int pipe = gma_crtc->pipe;
213a8434 Alan Cox           2012-05-11  171  	const struct psb_offset *map = &dev_priv->regmap[pipe];
026abc33 Kirill A. Shutemov 2012-03-08  172  	unsigned long start, offset;
026abc33 Kirill A. Shutemov 2012-03-08  173  	u32 dspcntr;
026abc33 Kirill A. Shutemov 2012-03-08  174  	int ret;
026abc33 Kirill A. Shutemov 2012-03-08  175  
026abc33 Kirill A. Shutemov 2012-03-08  176  	memcpy(&globle_dev, dev, sizeof(struct drm_device));
026abc33 Kirill A. Shutemov 2012-03-08  177  
026abc33 Kirill A. Shutemov 2012-03-08  178  	dev_dbg(dev->dev, "pipe = 0x%x.\n", pipe);
026abc33 Kirill A. Shutemov 2012-03-08  179  
026abc33 Kirill A. Shutemov 2012-03-08  180  	/* no fb bound */
51560195 Ville Syrjälä      2016-11-18  181  	if (!fb) {
026abc33 Kirill A. Shutemov 2012-03-08  182  		dev_dbg(dev->dev, "No FB bound\n");
026abc33 Kirill A. Shutemov 2012-03-08  183  		return 0;
026abc33 Kirill A. Shutemov 2012-03-08  184  	}
026abc33 Kirill A. Shutemov 2012-03-08  185  
51560195 Ville Syrjälä      2016-11-18  186  	ret = check_fb(fb);
026abc33 Kirill A. Shutemov 2012-03-08  187  	if (ret)
026abc33 Kirill A. Shutemov 2012-03-08  188  		return ret;
026abc33 Kirill A. Shutemov 2012-03-08  189  
213a8434 Alan Cox           2012-05-11  190  	if (pipe > 2) {
026abc33 Kirill A. Shutemov 2012-03-08  191  		DRM_ERROR("Illegal Pipe Number.\n");
026abc33 Kirill A. Shutemov 2012-03-08  192  		return -EINVAL;
026abc33 Kirill A. Shutemov 2012-03-08  193  	}
026abc33 Kirill A. Shutemov 2012-03-08  194  
026abc33 Kirill A. Shutemov 2012-03-08  195  	if (!gma_power_begin(dev, true))
026abc33 Kirill A. Shutemov 2012-03-08  196  		return 0;
026abc33 Kirill A. Shutemov 2012-03-08  197  
026abc33 Kirill A. Shutemov 2012-03-08 @198  	start = psbfb->gtt->offset;
272725c7 Ville Syrjälä      2016-12-14  199  	offset = y * fb->pitches[0] + x * fb->format->cpp[0];
026abc33 Kirill A. Shutemov 2012-03-08  200  
51560195 Ville Syrjälä      2016-11-18  201  	REG_WRITE(map->stride, fb->pitches[0]);
213a8434 Alan Cox           2012-05-11  202  	dspcntr = REG_READ(map->cntr);
026abc33 Kirill A. Shutemov 2012-03-08  203  	dspcntr &= ~DISPPLANE_PIXFORMAT_MASK;
026abc33 Kirill A. Shutemov 2012-03-08  204  
272725c7 Ville Syrjälä      2016-12-14  205  	switch (fb->format->cpp[0] * 8) {
026abc33 Kirill A. Shutemov 2012-03-08  206  	case 8:
026abc33 Kirill A. Shutemov 2012-03-08  207  		dspcntr |= DISPPLANE_8BPP;
026abc33 Kirill A. Shutemov 2012-03-08  208  		break;
026abc33 Kirill A. Shutemov 2012-03-08  209  	case 16:
b00c600e Ville Syrjälä      2016-12-14  210  		if (fb->format->depth == 15)
026abc33 Kirill A. Shutemov 2012-03-08  211  			dspcntr |= DISPPLANE_15_16BPP;
026abc33 Kirill A. Shutemov 2012-03-08  212  		else
026abc33 Kirill A. Shutemov 2012-03-08  213  			dspcntr |= DISPPLANE_16BPP;
026abc33 Kirill A. Shutemov 2012-03-08  214  		break;
026abc33 Kirill A. Shutemov 2012-03-08  215  	case 24:
026abc33 Kirill A. Shutemov 2012-03-08  216  	case 32:
026abc33 Kirill A. Shutemov 2012-03-08  217  		dspcntr |= DISPPLANE_32BPP_NO_ALPHA;
026abc33 Kirill A. Shutemov 2012-03-08  218  		break;
026abc33 Kirill A. Shutemov 2012-03-08  219  	}
213a8434 Alan Cox           2012-05-11  220  	REG_WRITE(map->cntr, dspcntr);
026abc33 Kirill A. Shutemov 2012-03-08  221  
026abc33 Kirill A. Shutemov 2012-03-08  222  	dev_dbg(dev->dev, "Writing base %08lX %08lX %d %d\n",
026abc33 Kirill A. Shutemov 2012-03-08  223  						start, offset, x, y);
213a8434 Alan Cox           2012-05-11  224  	REG_WRITE(map->linoff, offset);
213a8434 Alan Cox           2012-05-11  225  	REG_READ(map->linoff);
213a8434 Alan Cox           2012-05-11  226  	REG_WRITE(map->surf, start);
213a8434 Alan Cox           2012-05-11  227  	REG_READ(map->surf);
026abc33 Kirill A. Shutemov 2012-03-08  228  
026abc33 Kirill A. Shutemov 2012-03-08  229  	gma_power_end(dev);
026abc33 Kirill A. Shutemov 2012-03-08  230  
026abc33 Kirill A. Shutemov 2012-03-08  231  	return 0;
026abc33 Kirill A. Shutemov 2012-03-08  232  }
026abc33 Kirill A. Shutemov 2012-03-08  233  

:::::: The code at line 198 was first introduced by commit
:::::: 026abc333205c1fff80138b8c2cac3d0347685f4 gma500: initial medfield merge

:::::: TO: Kirill A. Shutemov <kirill.shutemov at linux.intel.com>
:::::: CC: Dave Airlie <airlied at redhat.com>

---
0-DAY kernel test infrastructure                Open Source Technology Center
https://lists.01.org/pipermail/kbuild-all                   Intel Corporation
-------------- next part --------------
A non-text attachment was scrubbed...
Name: .config.gz
Type: application/gzip
Size: 62392 bytes
Desc: not available
URL: <https://lists.freedesktop.org/archives/dri-devel/attachments/20180622/15cbb009/attachment-0001.gz>


More information about the dri-devel mailing list