[agd5f:drm-next 321/599] drivers/gpu/drm/amd/amdgpu/../pm/inc/smu_v13_0_0_pptable.h:194:39: warning: field overdrive_table within 'struct smu_13_0_0_powerplay_table' is less aligned than 'struct smu_13_0_0_overdrive_table' and is usually due to 'struct smu_13_0_0_powerplay_table'...

From: kernel test robot
Date: Sat May 07 2022 - 02:34:42 EST


tree: https://gitlab.freedesktop.org/agd5f/linux.git drm-next
head: 3170f5f234272247989fafee4cba4cbbc822631c
commit: 276c03a0547068026241decd2c1159df0be5941f [321/599] drm/amd/smu: Update SMU13 support for SMU 13.0.0
config: arm-randconfig-r034-20220506 (https://download.01.org/0day-ci/archive/20220507/202205071434.E4b56uaS-lkp@xxxxxxxxx/config)
compiler: clang version 15.0.0 (https://github.com/llvm/llvm-project 5e004fb787698440a387750db7f8028e7cb14cfc)
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
# install arm cross compiling tool for clang build
# apt-get install binutils-arm-linux-gnueabi
git remote add agd5f https://gitlab.freedesktop.org/agd5f/linux.git
git fetch --no-tags agd5f drm-next
git checkout 276c03a0547068026241decd2c1159df0be5941f
# save the config file
mkdir build_dir && cp config build_dir/.config
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross W=1 O=build_dir ARCH=arm SHELL=/bin/bash

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

All warnings (new ones prefixed by >>):

In file included from drivers/gpu/drm/amd/amdgpu/../pm/swsmu/smu13/smu_v13_0_0_ppt.c:39:
>> drivers/gpu/drm/amd/amdgpu/../pm/inc/smu_v13_0_0_pptable.h:194:39: warning: field overdrive_table within 'struct smu_13_0_0_powerplay_table' is less aligned than 'struct smu_13_0_0_overdrive_table' and is usually due to 'struct smu_13_0_0_powerplay_table' being packed, which can lead to unaligned accesses [-Wunaligned-access]
struct smu_13_0_0_overdrive_table overdrive_table;
^
1 warning generated.


vim +194 drivers/gpu/drm/amd/amdgpu/../pm/inc/smu_v13_0_0_pptable.h

ce81151c7d9df8 Likun Gao 2022-04-06 173
ce81151c7d9df8 Likun Gao 2022-04-06 174 struct smu_13_0_0_powerplay_table
ce81151c7d9df8 Likun Gao 2022-04-06 175 {
ce81151c7d9df8 Likun Gao 2022-04-06 176 struct atom_common_table_header header; //For SMU13, header.format_revision = 15, header.content_revision = 0
ce81151c7d9df8 Likun Gao 2022-04-06 177 uint8_t table_revision; //For SMU13, table_revision = 2
ce81151c7d9df8 Likun Gao 2022-04-06 178 uint8_t padding;
ce81151c7d9df8 Likun Gao 2022-04-06 179 uint16_t table_size; //Driver portion table size. The offset to smc_pptable including header size
ce81151c7d9df8 Likun Gao 2022-04-06 180 uint32_t golden_pp_id; //PPGen use only: PP Table ID on the Golden Data Base
ce81151c7d9df8 Likun Gao 2022-04-06 181 uint32_t golden_revision; //PPGen use only: PP Table Revision on the Golden Data Base
ce81151c7d9df8 Likun Gao 2022-04-06 182 uint16_t format_id; //PPGen use only: PPTable for different ASICs. For SMU13 this should be 0x80
ce81151c7d9df8 Likun Gao 2022-04-06 183 uint32_t platform_caps; //POWERPLAYABLE::ulPlatformCaps
ce81151c7d9df8 Likun Gao 2022-04-06 184
ce81151c7d9df8 Likun Gao 2022-04-06 185 uint8_t thermal_controller_type; //one of SMU_13_0_0_PP_THERMALCONTROLLER
ce81151c7d9df8 Likun Gao 2022-04-06 186
ce81151c7d9df8 Likun Gao 2022-04-06 187 uint16_t small_power_limit1;
ce81151c7d9df8 Likun Gao 2022-04-06 188 uint16_t small_power_limit2;
ce81151c7d9df8 Likun Gao 2022-04-06 189 uint16_t boost_power_limit; //For Gemini Board, when the slave adapter is in BACO mode, the master adapter will use this boost power limit instead of the default power limit to boost the power limit.
ce81151c7d9df8 Likun Gao 2022-04-06 190 uint16_t software_shutdown_temp;
ce81151c7d9df8 Likun Gao 2022-04-06 191
ce81151c7d9df8 Likun Gao 2022-04-06 192 uint32_t reserve[45];
ce81151c7d9df8 Likun Gao 2022-04-06 193
ce81151c7d9df8 Likun Gao 2022-04-06 @194 struct smu_13_0_0_overdrive_table overdrive_table;
ce81151c7d9df8 Likun Gao 2022-04-06 195 uint8_t padding1;
ce81151c7d9df8 Likun Gao 2022-04-06 196 PPTable_t smc_pptable; //PPTable_t in driver_if.h
ce81151c7d9df8 Likun Gao 2022-04-06 197 } __attribute__((packed));
ce81151c7d9df8 Likun Gao 2022-04-06 198
ce81151c7d9df8 Likun Gao 2022-04-06 199

:::::: The code at line 194 was first introduced by commit
:::::: ce81151c7d9df872119941e46f3f34c295b08503 drm/amd/smu: add smu v13_0 header files

:::::: TO: Likun Gao <Likun.Gao@xxxxxxx>
:::::: CC: Alex Deucher <alexander.deucher@xxxxxxx>

--
0-DAY CI Kernel Test Service
https://01.org/lkp