Re: [PATCH] drm/ast: Fix long time waiting on s3/s4 resume

From: kernel test robot
Date: Thu Apr 13 2023 - 23:34:05 EST


Hi Jammy,

kernel test robot noticed the following build errors:

[auto build test ERROR on e62252bc55b6d4eddc6c2bdbf95a448180d6a08d]

url: https://github.com/intel-lab-lkp/linux/commits/Jammy-Huang/drm-ast-Fix-long-time-waiting-on-s3-s4-resume/20230414-091312
base: e62252bc55b6d4eddc6c2bdbf95a448180d6a08d
patch link: https://lore.kernel.org/r/20230414011147.3858-1-jammy_huang%40aspeedtech.com
patch subject: [PATCH] drm/ast: Fix long time waiting on s3/s4 resume
config: ia64-allyesconfig (https://download.01.org/0day-ci/archive/20230414/202304141155.Hsgy2cN0-lkp@xxxxxxxxx/config)
compiler: ia64-linux-gcc (GCC) 12.1.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
# https://github.com/intel-lab-lkp/linux/commit/120de3fe25a450d9918de8bc73a4fe079bc71d9c
git remote add linux-review https://github.com/intel-lab-lkp/linux
git fetch --no-tags linux-review Jammy-Huang/drm-ast-Fix-long-time-waiting-on-s3-s4-resume/20230414-091312
git checkout 120de3fe25a450d9918de8bc73a4fe079bc71d9c
# save the config file
mkdir build_dir && cp config build_dir/.config
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-12.1.0 make.cross W=1 O=build_dir ARCH=ia64 olddefconfig
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-12.1.0 make.cross W=1 O=build_dir ARCH=ia64 SHELL=/bin/bash drivers/gpu/

If you fix the issue, kindly add following tag where applicable
| Reported-by: kernel test robot <lkp@xxxxxxxxx>
| Link: https://lore.kernel.org/oe-kbuild-all/202304141155.Hsgy2cN0-lkp@xxxxxxxxx/

All errors (new ones prefixed by >>):

>> drivers/gpu/drm/ast/ast_dp.c:122:6: error: conflicting types for 'ast_dp_launch'; have 'void(struct drm_device *, u8)' {aka 'void(struct drm_device *, unsigned char)'}
122 | void ast_dp_launch(struct drm_device *dev, u8 bPower)
| ^~~~~~~~~~~~~
In file included from drivers/gpu/drm/ast/ast_dp.c:8:
drivers/gpu/drm/ast/ast_drv.h:501:6: note: previous declaration of 'ast_dp_launch' with type 'void(struct drm_device *)'
501 | void ast_dp_launch(struct drm_device *dev);
| ^~~~~~~~~~~~~


vim +122 drivers/gpu/drm/ast/ast_dp.c

594e9c04b5864b KuoHsiang Chou 2022-04-28 118
594e9c04b5864b KuoHsiang Chou 2022-04-28 119 /*
594e9c04b5864b KuoHsiang Chou 2022-04-28 120 * Launch Aspeed DP
594e9c04b5864b KuoHsiang Chou 2022-04-28 121 */
594e9c04b5864b KuoHsiang Chou 2022-04-28 @122 void ast_dp_launch(struct drm_device *dev, u8 bPower)
594e9c04b5864b KuoHsiang Chou 2022-04-28 123 {
120de3fe25a450 Jammy Huang 2023-04-14 124 u32 i = 0;
594e9c04b5864b KuoHsiang Chou 2022-04-28 125 u8 bDPExecute = 1;
594e9c04b5864b KuoHsiang Chou 2022-04-28 126 struct ast_private *ast = to_ast_private(dev);
594e9c04b5864b KuoHsiang Chou 2022-04-28 127
594e9c04b5864b KuoHsiang Chou 2022-04-28 128 // Wait one second then timeout.
594e9c04b5864b KuoHsiang Chou 2022-04-28 129 while (ast_get_index_reg_mask(ast, AST_IO_CRTC_PORT, 0xD1, COPROCESSOR_LAUNCH) !=
594e9c04b5864b KuoHsiang Chou 2022-04-28 130 COPROCESSOR_LAUNCH) {
594e9c04b5864b KuoHsiang Chou 2022-04-28 131 i++;
594e9c04b5864b KuoHsiang Chou 2022-04-28 132 // wait 100 ms
594e9c04b5864b KuoHsiang Chou 2022-04-28 133 msleep(100);
594e9c04b5864b KuoHsiang Chou 2022-04-28 134
594e9c04b5864b KuoHsiang Chou 2022-04-28 135 if (i >= 10) {
594e9c04b5864b KuoHsiang Chou 2022-04-28 136 // DP would not be ready.
594e9c04b5864b KuoHsiang Chou 2022-04-28 137 bDPExecute = 0;
594e9c04b5864b KuoHsiang Chou 2022-04-28 138 break;
594e9c04b5864b KuoHsiang Chou 2022-04-28 139 }
594e9c04b5864b KuoHsiang Chou 2022-04-28 140 }
594e9c04b5864b KuoHsiang Chou 2022-04-28 141
120de3fe25a450 Jammy Huang 2023-04-14 142 if (!bDPExecute)
120de3fe25a450 Jammy Huang 2023-04-14 143 drm_err(dev, "Wait DPMCU executing timeout\n");
594e9c04b5864b KuoHsiang Chou 2022-04-28 144
594e9c04b5864b KuoHsiang Chou 2022-04-28 145 ast_set_index_reg_mask(ast, AST_IO_CRTC_PORT, 0xE5,
594e9c04b5864b KuoHsiang Chou 2022-04-28 146 (u8) ~ASTDP_HOST_EDID_READ_DONE_MASK,
594e9c04b5864b KuoHsiang Chou 2022-04-28 147 ASTDP_HOST_EDID_READ_DONE);
7f35680ada234c Thomas Zimmermann 2022-06-07 148 }
594e9c04b5864b KuoHsiang Chou 2022-04-28 149

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