• Hua Zhang's avatar
    drm/amd/powerplay: skip smu_i2c_eeprom_init/fini under sriov mode · a16be2fe
    Hua Zhang authored
    When smu_i2c_eeprom_init is called on the smu resuming process
    under sroiv mode, there will be a call trace:
    [  436.377690]  dump_stack+0x63/0x85
    [  436.377695]  kobject_init+0x77/0x90
    [  436.377704]  device_initialize+0x28/0x110
    [  436.377708]  device_register+0x12/0x20
    [  436.377756]  i2c_register_adapter+0xeb/0x400
    [  436.377763]  i2c_add_adapter+0x5a/0x80
    [  436.377951]  arcturus_i2c_eeprom_control_init+0x60/0x80 [amdgpu]
    [  436.378123]  smu_resume+0xcc/0x110 [amdgpu]
    [  436.378247]  amdgpu_device_gpu_recover+0xfb1/0xfc0 [amdgpu]
    [  436.378401]  amdgpu_job_timedout+0xf2/0x150 [amdgpu]
    [  436.378414]  drm_sched_job_timedout+0x70/0xc0 [amd_sched]
    [  436.378420]  ? drm_sched_job_timedout+0x70/0xc0 [amd_sched]
    [  436.378430]  process_one_work+0x1fd/0x3f0
    [  436.378438]  worker_thread+0x34/0x410
    [  436.378444]  kthread+0x121/0x140
    [  436.378451]  ? process_one_work+0x3f0/0x3f0
    [  436.378456]  ? kthread_create_worker_on_cpu+0x70/0x70
    [  436.378464]  ret_from_fork+0x35/0x40
    
    This is because smu_i2c_eeprom is not released on gpu recovering.
    Actually, smu_i2c_eeprom_init/fini are only needed under bare
    mental mode.
    Signed-off-by: default avatarHua Zhang <hua.zhang@amd.com>
    Reviewed-by: default avatarHawking Zhang <Hawking.Zhang@amd.com>
    Signed-off-by: default avatarAlex Deucher <alexander.deucher@amd.com>
    a16be2fe
amdgpu_smu.c 65.1 KB