tree:
git://anongit.freedesktop.org/drm/drm-misc for-linux-next
head: 6eca310e8924ab98c73b81dfd39e7dd553ceddfd
commit: 6eca310e8924ab98c73b81dfd39e7dd553ceddfd [9/9] drm/nouveau/kms/nv50-: Add basic
DPCD backlight support for nouveau
config: arc-randconfig-r005-20210608 (attached as .config)
compiler: arceb-elf-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 remote add drm-drm-misc
git://anongit.freedesktop.org/drm/drm-misc
git fetch --no-tags drm-drm-misc for-linux-next
git checkout 6eca310e8924ab98c73b81dfd39e7dd553ceddfd
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-9.3.0 make.cross ARCH=arc
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp(a)intel.com>
All errors (new ones prefixed by >>):
drivers/gpu/drm/nouveau/dispnv50/disp.c: In function 'nv50_mstm_cleanup':
drivers/gpu/drm/nouveau/dispnv50/disp.c:1390:6: warning: variable 'ret' set but
not used [-Wunused-but-set-variable]
1390 | int ret;
| ^~~
drivers/gpu/drm/nouveau/dispnv50/disp.c: In function 'nv50_mstm_prepare':
drivers/gpu/drm/nouveau/dispnv50/disp.c:1414:6: warning: variable 'ret' set but
not used [-Wunused-but-set-variable]
1414 | int ret;
| ^~~
drivers/gpu/drm/nouveau/dispnv50/disp.c: In function
'nv50_sor_atomic_disable':
> drivers/gpu/drm/nouveau/dispnv50/disp.c:1665:52: error:
'struct nouveau_connector' has no member named 'backlight'
1665
| struct nouveau_backlight *backlight = nv_connector->backlight;
| ^~
> drivers/gpu/drm/nouveau/dispnv50/disp.c:1670:28: error:
dereferencing pointer to incomplete type 'struct nouveau_backlight'
1670
| if (backlight && backlight->uses_dpcd) {
| ^~
drivers/gpu/drm/nouveau/dispnv50/disp.c: At top level:
drivers/gpu/drm/nouveau/dispnv50/disp.c:2661:1: warning: no previous prototype for
'nv50_display_create' [-Wmissing-prototypes]
2661 | nv50_display_create(struct drm_device *dev)
| ^~~~~~~~~~~~~~~~~~~
vim +1665 drivers/gpu/drm/nouveau/dispnv50/disp.c
1652
1653 /* TODO: Should we extend this to PWM-only backlights?
1654 * As well, should we add a DRM helper for waiting for the backlight to
acknowledge
1655 * the panel backlight has been shut off? Intel doesn't seem to do this, and
uses a
1656 * fixed time delay from the vbios…
1657 */
1658 static void
1659 nv50_sor_atomic_disable(struct drm_encoder *encoder, struct drm_atomic_state
*state)
1660 {
1661 struct nouveau_encoder *nv_encoder = nouveau_encoder(encoder);
1662 struct nouveau_drm *drm = nouveau_drm(nv_encoder->base.base.dev);
1663 struct nouveau_crtc *nv_crtc = nouveau_crtc(nv_encoder->crtc);
1664 struct nouveau_connector *nv_connector = nv50_outp_get_old_connector(state,
nv_encoder);
1665 struct nouveau_backlight *backlight =
nv_connector->backlight;
1666 struct drm_dp_aux *aux =
&nv_connector->aux;
1667 int ret;
1668 u8 pwr;
1669
1670 if (backlight && backlight->uses_dpcd) {
1671 ret = drm_edp_backlight_disable(aux, &backlight->edp_info);
1672 if (ret < 0)
1673 NV_ERROR(drm, "Failed to disable backlight on [CONNECTOR:%d:%s]:
%d\n",
1674 nv_connector->base.base.id, nv_connector->base.name, ret);
1675 }
1676
1677 if (nv_encoder->dcb->type == DCB_OUTPUT_DP) {
1678 int ret = drm_dp_dpcd_readb(aux, DP_SET_POWER, &pwr);
1679
1680 if (ret == 0) {
1681 pwr &= ~DP_SET_POWER_MASK;
1682 pwr |= DP_SET_POWER_D3;
1683 drm_dp_dpcd_writeb(aux, DP_SET_POWER, pwr);
1684 }
1685 }
1686
1687 nv_encoder->update(nv_encoder, nv_crtc->index, NULL, 0, 0);
1688 nv50_audio_disable(encoder, nv_crtc);
1689 nv50_hdmi_disable(&nv_encoder->base.base, nv_crtc);
1690 nv50_outp_release(nv_encoder);
1691 nv_encoder->crtc = NULL;
1692 }
1693
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org