drm fixes for 5.12-rc2
amdgpu: - S0ix fix - Handle new NV12 SKU - Misc power fixes - Display uninitialized value fix - PCIE debugfs register access fix nouveau: - regression fix for gk104 -----BEGIN PGP SIGNATURE----- iQIcBAABAgAGBQJgQZvpAAoJEAx081l5xIa+NA0P/0Z9+CfguQLitxwYQ0IztZfn tZGYqUlud7ba48fa3sNtNb2ex6YJuI4Simghmj0ZZOaBbXPTSFn/nty0nEA0h1O2 G7MkxAnd5NU+pjDzTBpmBvd4ZVl17fONRv3672yTdAxKvL97wUb2Zbgmqmes2nwk auA3O9uqYZp84WfqvJ6k+py32a9gdhrerug1Vg5ZRJm3EQeZJ8UgEZeUkVbkdgCn 1Qv2gbElJW0BxQXITakbML6BQ09C2EoWdBZJRueQg+/zeTPrGvcWLgIv/GyFQ2Eg 3q9OEhWtpx03KxNMF26rYiDNkVjR31hmqpZGjhHFbIbDzt4famHqZOQKMMO/ilBg emJezCu+igLEwTd+GGkUp73rgvCYP8cKQl0wLXkjUa+EpIa8pS2YX/P9bQUv/iCU ncKiV2aFoEpJI/MX7OobNtibyTlKIzLMsV6m5ahUG7EuNCdxr40rjoY88esSgBqP ddEd1pxp8Pi6rDvSO8CoKiO5rYY1tRlmH5AeNlikFM/Jlb2sAlh/tkO8OaqwZB0S GnPyhnO+6xFplB8A6cH+IChN3zWWBaQcduGqpEASoK1NrZR4mGXaa5d4PfH8jmuf 2L4WqvFgHuuW3xLGO+KmOewqhmyi5UjsTNo2qF3wxsJScuQe6l9+xFxeEkYz9dSB xG3VG+rEfEa1ONjCZMiQ =a2/q -----END PGP SIGNATURE----- Merge tag 'drm-fixes-2021-03-05' of git://anongit.freedesktop.org/drm/drm Pull drm fixes from Dave Airlie: "More may show up but this is what I have at this stage: just a single nouveau regression fix, and a bunch of amdgpu fixes. amdgpu: - S0ix fix - Handle new NV12 SKU - Misc power fixes - Display uninitialized value fix - PCIE debugfs register access fix nouveau: - regression fix for gk104" * tag 'drm-fixes-2021-03-05' of git://anongit.freedesktop.org/drm/drm: drm/amdgpu: fix parameter error of RREG32_PCIE() in amdgpu_regs_pcie drm/amd/display: fix the return of the uninitialized value in ret drm/amdgpu: enable BACO runpm by default on sienna cichlid and navy flounder drm/amd/pm: correct Arcturus mmTHM_BACO_CNTL register address drm/amdgpu/swsmu/vangogh: Only use RLCPowerNotify msg for disable drm/amdgpu/pm: make unsupported power profile messages debug drm/amdgpu:disable VCN for Navi12 SKU drm/amdgpu: Only check for S0ix if AMD_PMC is configured drm/nouveau/fifo/gk104-gp1xx: fix creation of sw class
This commit is contained in:
commit
280d542f6f
|
@ -903,10 +903,11 @@ void amdgpu_acpi_fini(struct amdgpu_device *adev)
|
|||
*/
|
||||
bool amdgpu_acpi_is_s0ix_supported(struct amdgpu_device *adev)
|
||||
{
|
||||
#if defined(CONFIG_AMD_PMC)
|
||||
if (acpi_gbl_FADT.flags & ACPI_FADT_LOW_POWER_S0) {
|
||||
if (adev->flags & AMD_IS_APU)
|
||||
return true;
|
||||
}
|
||||
|
||||
#endif
|
||||
return false;
|
||||
}
|
||||
|
|
|
@ -357,7 +357,7 @@ static ssize_t amdgpu_debugfs_regs_pcie_read(struct file *f, char __user *buf,
|
|||
while (size) {
|
||||
uint32_t value;
|
||||
|
||||
value = RREG32_PCIE(*pos >> 2);
|
||||
value = RREG32_PCIE(*pos);
|
||||
r = put_user(value, (uint32_t *)buf);
|
||||
if (r) {
|
||||
pm_runtime_mark_last_busy(adev_to_drm(adev)->dev);
|
||||
|
@ -424,7 +424,7 @@ static ssize_t amdgpu_debugfs_regs_pcie_write(struct file *f, const char __user
|
|||
return r;
|
||||
}
|
||||
|
||||
WREG32_PCIE(*pos >> 2, value);
|
||||
WREG32_PCIE(*pos, value);
|
||||
|
||||
result += 4;
|
||||
buf += 4;
|
||||
|
|
|
@ -173,8 +173,6 @@ int amdgpu_driver_load_kms(struct amdgpu_device *adev, unsigned long flags)
|
|||
switch (adev->asic_type) {
|
||||
case CHIP_VEGA20:
|
||||
case CHIP_ARCTURUS:
|
||||
case CHIP_SIENNA_CICHLID:
|
||||
case CHIP_NAVY_FLOUNDER:
|
||||
/* enable runpm if runpm=1 */
|
||||
if (amdgpu_runtime_pm > 0)
|
||||
adev->runpm = true;
|
||||
|
|
|
@ -558,7 +558,8 @@ static bool nv_is_headless_sku(struct pci_dev *pdev)
|
|||
{
|
||||
if ((pdev->device == 0x731E &&
|
||||
(pdev->revision == 0xC6 || pdev->revision == 0xC7)) ||
|
||||
(pdev->device == 0x7340 && pdev->revision == 0xC9))
|
||||
(pdev->device == 0x7340 && pdev->revision == 0xC9) ||
|
||||
(pdev->device == 0x7360 && pdev->revision == 0xC7))
|
||||
return true;
|
||||
return false;
|
||||
}
|
||||
|
@ -634,7 +635,8 @@ int nv_set_ip_blocks(struct amdgpu_device *adev)
|
|||
if (adev->firmware.load_type == AMDGPU_FW_LOAD_DIRECT &&
|
||||
!amdgpu_sriov_vf(adev))
|
||||
amdgpu_device_ip_block_add(adev, &smu_v11_0_ip_block);
|
||||
amdgpu_device_ip_block_add(adev, &vcn_v2_0_ip_block);
|
||||
if (!nv_is_headless_sku(adev->pdev))
|
||||
amdgpu_device_ip_block_add(adev, &vcn_v2_0_ip_block);
|
||||
if (!amdgpu_sriov_vf(adev))
|
||||
amdgpu_device_ip_block_add(adev, &jpeg_v2_0_ip_block);
|
||||
break;
|
||||
|
|
|
@ -530,7 +530,7 @@ bool dm_helpers_dp_write_dsc_enable(
|
|||
{
|
||||
uint8_t enable_dsc = enable ? 1 : 0;
|
||||
struct amdgpu_dm_connector *aconnector;
|
||||
uint8_t ret;
|
||||
uint8_t ret = 0;
|
||||
|
||||
if (!stream)
|
||||
return false;
|
||||
|
|
|
@ -1322,7 +1322,7 @@ static int arcturus_set_power_profile_mode(struct smu_context *smu,
|
|||
CMN2ASIC_MAPPING_WORKLOAD,
|
||||
profile_mode);
|
||||
if (workload_type < 0) {
|
||||
dev_err(smu->adev->dev, "Unsupported power profile mode %d on arcturus\n", profile_mode);
|
||||
dev_dbg(smu->adev->dev, "Unsupported power profile mode %d on arcturus\n", profile_mode);
|
||||
return -EINVAL;
|
||||
}
|
||||
|
||||
|
|
|
@ -78,6 +78,9 @@ MODULE_FIRMWARE("amdgpu/dimgrey_cavefish_smc.bin");
|
|||
#define PCIE_LC_SPEED_CNTL__LC_CURRENT_DATA_RATE_MASK 0xC000
|
||||
#define PCIE_LC_SPEED_CNTL__LC_CURRENT_DATA_RATE__SHIFT 0xE
|
||||
|
||||
#define mmTHM_BACO_CNTL_ARCT 0xA7
|
||||
#define mmTHM_BACO_CNTL_ARCT_BASE_IDX 0
|
||||
|
||||
static int link_width[] = {0, 1, 2, 4, 8, 12, 16};
|
||||
static int link_speed[] = {25, 50, 80, 160};
|
||||
|
||||
|
@ -1532,9 +1535,15 @@ int smu_v11_0_baco_set_state(struct smu_context *smu, enum smu_baco_state state)
|
|||
break;
|
||||
default:
|
||||
if (!ras || !ras->supported) {
|
||||
data = RREG32_SOC15(THM, 0, mmTHM_BACO_CNTL);
|
||||
data |= 0x80000000;
|
||||
WREG32_SOC15(THM, 0, mmTHM_BACO_CNTL, data);
|
||||
if (adev->asic_type == CHIP_ARCTURUS) {
|
||||
data = RREG32_SOC15(THM, 0, mmTHM_BACO_CNTL_ARCT);
|
||||
data |= 0x80000000;
|
||||
WREG32_SOC15(THM, 0, mmTHM_BACO_CNTL_ARCT, data);
|
||||
} else {
|
||||
data = RREG32_SOC15(THM, 0, mmTHM_BACO_CNTL);
|
||||
data |= 0x80000000;
|
||||
WREG32_SOC15(THM, 0, mmTHM_BACO_CNTL, data);
|
||||
}
|
||||
|
||||
ret = smu_cmn_send_smc_msg_with_param(smu, SMU_MSG_EnterBaco, 0, NULL);
|
||||
} else {
|
||||
|
|
|
@ -810,7 +810,7 @@ static int vangogh_set_power_profile_mode(struct smu_context *smu, long *input,
|
|||
CMN2ASIC_MAPPING_WORKLOAD,
|
||||
profile_mode);
|
||||
if (workload_type < 0) {
|
||||
dev_err_once(smu->adev->dev, "Unsupported power profile mode %d on VANGOGH\n",
|
||||
dev_dbg(smu->adev->dev, "Unsupported power profile mode %d on VANGOGH\n",
|
||||
profile_mode);
|
||||
return -EINVAL;
|
||||
}
|
||||
|
@ -1685,9 +1685,9 @@ static int vangogh_system_features_control(struct smu_context *smu, bool en)
|
|||
uint32_t feature_mask[2];
|
||||
int ret = 0;
|
||||
|
||||
if (adev->pm.fw_version >= 0x43f1700)
|
||||
if (adev->pm.fw_version >= 0x43f1700 && !en)
|
||||
ret = smu_cmn_send_smc_msg_with_param(smu, SMU_MSG_RlcPowerNotify,
|
||||
en ? RLC_STATUS_NORMAL : RLC_STATUS_OFF, NULL);
|
||||
RLC_STATUS_OFF, NULL);
|
||||
|
||||
bitmap_zero(feature->enabled, feature->feature_num);
|
||||
bitmap_zero(feature->supported, feature->feature_num);
|
||||
|
|
|
@ -844,7 +844,7 @@ static int renoir_set_power_profile_mode(struct smu_context *smu, long *input, u
|
|||
* TODO: If some case need switch to powersave/default power mode
|
||||
* then can consider enter WORKLOAD_COMPUTE/WORKLOAD_CUSTOM for power saving.
|
||||
*/
|
||||
dev_err_once(smu->adev->dev, "Unsupported power profile mode %d on RENOIR\n", profile_mode);
|
||||
dev_dbg(smu->adev->dev, "Unsupported power profile mode %d on RENOIR\n", profile_mode);
|
||||
return -EINVAL;
|
||||
}
|
||||
|
||||
|
|
|
@ -261,6 +261,9 @@ gk104_fifo_pbdma = {
|
|||
struct nvkm_engine *
|
||||
gk104_fifo_id_engine(struct nvkm_fifo *base, int engi)
|
||||
{
|
||||
if (engi == GK104_FIFO_ENGN_SW)
|
||||
return nvkm_device_engine(base->engine.subdev.device, NVKM_ENGINE_SW, 0);
|
||||
|
||||
return gk104_fifo(base)->engine[engi].engine;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue