Skip to contentSkip to conversation

drm/amdgpu: remove the DID of Vangogh from pciidlist

PATCH In review Perry Yuan 2 participants 7 messages Nov 1, 2022

Subsystems (2)
lore
Share & tools
lore

Perry Yuan

author
#0 lore raw

PATCH 1/2 drm/amdgpu: remove the DID of Vangogh from pciidlist

change the vangogh family to use IP discovery path to initialize IP list, this needs to remove the DID from the PCI ID list to allow the IP discovery path to set all the IP versions correctly.

---
 drivers/gpu/drm/amd/amdgpu/amdgpu_drv.c | 3 ---
 1 file changed, 3 deletions(-)
drivers/gpu/drm/amd/amdgpu/amdgpu_drv.c +0 -3
index 3c9fecdd6b2f..ac00e2b24a69 100644
@@ -1924,9 +1924,6 @@ static const struct pci_device_id pciidlist[] = {
 	{0x1002, 0x73AF, PCI_ANY_ID, PCI_ANY_ID, 0, 0, CHIP_SIENNA_CICHLID},
 	{0x1002, 0x73BF, PCI_ANY_ID, PCI_ANY_ID, 0, 0, CHIP_SIENNA_CICHLID},
 
-	/* Van Gogh */
-	{0x1002, 0x163F, PCI_ANY_ID, PCI_ANY_ID, 0, 0, CHIP_VANGOGH|AMD_IS_APU},
-
 	/* Yellow Carp */
 	{0x1002, 0x164D, PCI_ANY_ID, PCI_ANY_ID, 0, 0, CHIP_YELLOW_CARP|AMD_IS_APU},
 	{0x1002, 0x1681, PCI_ANY_ID, PCI_ANY_ID, 0, 0, CHIP_YELLOW_CARP|AMD_IS_APU},
Signature · 1 line
2.34.1
author
#1 lore raw

PATCH 2/2 drm/amdgpu: add Vangogh APU flag to IP discovery path

Add the missing apu flag for Vangogh when using IP discovery code path to initialize IPs

---
 drivers/gpu/drm/amd/amdgpu/amdgpu_discovery.c | 1 +
 1 file changed, 1 insertion(+)
drivers/gpu/drm/amd/amdgpu/amdgpu_discovery.c +1 -0
index 3993e6134914..52a92add12ea 100644
@@ -2161,6 +2161,7 @@ int amdgpu_discovery_set_ip_blocks(struct amdgpu_device *adev)
 		break;
 	case IP_VERSION(10, 3, 1):
 		adev->family = AMDGPU_FAMILY_VGH;
+		adev->apu_flags |= AMD_APU_IS_VANGOGH;
 		break;
 	case IP_VERSION(10, 3, 3):
 		adev->family = AMDGPU_FAMILY_YC;
Signature · 1 line
2.34.1
Reviewed-by on v1 2/2
#2 lore raw

Re: [PATCH 2/2] drm/amdgpu: add Vangogh APU flag to IP discovery path

Quoted 5 lines · Perry Yuan

Add the missing apu flag for Vangogh when using IP discovery code path to initialize IPs

Swap the order of the patches. With that, the series is:

Quoted 19 lines
---
 drivers/gpu/drm/amd/amdgpu/amdgpu_discovery.c | 1 +
 1 file changed, 1 insertion(+)
drivers/gpu/drm/amd/amdgpu/amdgpu_discovery.c +1 -1
index 3993e6134914..52a92add12ea 100644
@@ -2161,6 +2161,7 @@ int amdgpu_discovery_set_ip_blocks(struct amdgpu_device *adev)
                break;
        case IP_VERSION(10, 3, 1):
                adev->family = AMDGPU_FAMILY_VGH;
+               adev->apu_flags |= AMD_APU_IS_VANGOGH;
                break;
        case IP_VERSION(10, 3, 3):
                adev->family = AMDGPU_FAMILY_YC;
--

2.34.1

#3 lore raw

Re: [PATCH 2/2] drm/amdgpu: add Vangogh APU flag to IP discovery path

Quoted 10 lines · Alex Deucher
Quoted 5 lines · Perry Yuan

Add the missing apu flag for Vangogh when using IP discovery code path to initialize IPs

Swap the order of the patches. With that, the series is:

Actually, you also need to fix up check_seamless_boot_capability() in amdgpu_dm.c. Switch that to an IP version check.

Alex

Quoted 20 lines
Quoted 20 lines
---
 drivers/gpu/drm/amd/amdgpu/amdgpu_discovery.c | 1 +
 1 file changed, 1 insertion(+)
drivers/gpu/drm/amd/amdgpu/amdgpu_discovery.c +1 -1
index 3993e6134914..52a92add12ea 100644
@@ -2161,6 +2161,7 @@ int amdgpu_discovery_set_ip_blocks(struct amdgpu_device *adev)
                break;
        case IP_VERSION(10, 3, 1):
                adev->family = AMDGPU_FAMILY_VGH;
+               adev->apu_flags |= AMD_APU_IS_VANGOGH;
                break;
        case IP_VERSION(10, 3, 3):
                adev->family = AMDGPU_FAMILY_YC;
--

2.34.1

#4 lore raw

RE: [PATCH 2/2] drm/amdgpu: add Vangogh APU flag to IP discovery path

[AMD Official Use Only - General]

Hi Alex

Quoted 25 lines

-----Original Message-----
From: amd-gfx <[email protected]> On Behalf Of Alex Deucher
Sent: Tuesday, November 1, 2022 9:25 PM
To: Yuan, Perry <[email protected]>
Cc: Deucher, Alexander <[email protected]>; Huang, Ray <[email protected]>; Huang, Shimmer <[email protected]>; [email protected]
Subject: Re: [PATCH 2/2] drm/amdgpu: add Vangogh APU flag to IP discovery path

Caution: This message originated from an External Source. Use proper caution when opening attachments, clicking links, or responding.

Quoted 8 lines · Alex Deucher
Quoted 5 lines · Perry Yuan

Add the missing apu flag for Vangogh when using IP discovery code path to initialize IPs

Quoted 7 lines
Quoted 2 lines

Swap the order of the patches. With that, the series is:

Actually, you also need to fix up check_seamless_boot_capability() in amdgpu_dm.c. Switch that to an IP version check.

Alex

I am not sure if the IP versions only correctly match the GPUs.

How about using the apu flags like this ?

bool check_seamless_boot_capability(struct amdgpu_device *adev)

{
	if (adev->apu_flags & AMD_APU_IS_VANGOGH) {
		if (!adev->mman.keep_stolen_vga_memory)
			return true;
	}

	return false;
}

Perry.

Quoted 24 lines
Quoted 7 lines
Quoted 7 lines


---
 drivers/gpu/drm/amd/amdgpu/amdgpu_discovery.c | 1 +
 1 file changed, 1 insertion(+)
Quoted 6 lines

drivers/gpu/drm/amd/amdgpu/amdgpu_discovery.c int amdgpu_discovery_set_ip_blocks(struct

Quoted 6 lines
drivers/gpu/drm/amd/amdgpu/amdgpu_discovery.c +0 -0
index 3993e6134914..52a92add12ea 100644
@@ -2161,6 +2161,7 @@ int amdgpu_discovery_set_ip_blocks(struct

amdgpu_device *adev)

Quoted 10 lines
Quoted 10 lines
drivers/gpu/drm/amd/amdgpu/amdgpu_discovery.c +1 -1
                break;
        case IP_VERSION(10, 3, 1):
                adev->family = AMDGPU_FAMILY_VGH;
+               adev->apu_flags |= AMD_APU_IS_VANGOGH;
                break;
        case IP_VERSION(10, 3, 3):
                adev->family = AMDGPU_FAMILY_YC;
--

2.34.1

#5 lore raw

Re: [PATCH 2/2] drm/amdgpu: add Vangogh APU flag to IP discovery path

Quoted 33 lines · Perry

[AMD Official Use Only - General]

Hi Alex

Quoted 28 lines

-----Original Message-----
From: amd-gfx <[email protected]> On Behalf Of Alex Deucher
Sent: Tuesday, November 1, 2022 9:25 PM
To: Yuan, Perry <[email protected]>
Cc: Deucher, Alexander <[email protected]>; Huang, Ray <[email protected]>; Huang, Shimmer <[email protected]>; [email protected]
Subject: Re: [PATCH 2/2] drm/amdgpu: add Vangogh APU flag to IP discovery path

Caution: This message originated from an External Source. Use proper caution when opening attachments, clicking links, or responding.

Quoted 10 lines · Alex Deucher
Quoted 5 lines · Perry Yuan

Add the missing apu flag for Vangogh when using IP discovery code path to initialize IPs

Swap the order of the patches. With that, the series is:

Quoted 6 lines
Quoted 4 lines

Actually, you also need to fix up check_seamless_boot_capability() in amdgpu_dm.c. Switch that to an IP version check.

Alex

I am not sure if the IP versions only correctly match the GPUs.

It should match gfx IP_VERSION(10, 3, 1). You are using that to set the APU flag in this patch. The DCN version (3.0.1) is also unique to this chip and that would better match the fact that this is a DCN related function.

Alex

Quoted 39 lines

How about using the apu flags like this ?

bool check_seamless_boot_capability(struct amdgpu_device *adev)

{
        if (adev->apu_flags & AMD_APU_IS_VANGOGH) {
                if (!adev->mman.keep_stolen_vga_memory)
                        return true;
        }

        return false;
}

Perry.

Quoted 24 lines
Quoted 7 lines
Quoted 7 lines


---
 drivers/gpu/drm/amd/amdgpu/amdgpu_discovery.c | 1 +
 1 file changed, 1 insertion(+)
Quoted 6 lines

drivers/gpu/drm/amd/amdgpu/amdgpu_discovery.c int amdgpu_discovery_set_ip_blocks(struct

Quoted 6 lines
drivers/gpu/drm/amd/amdgpu/amdgpu_discovery.c +0 -0
index 3993e6134914..52a92add12ea 100644
@@ -2161,6 +2161,7 @@ int amdgpu_discovery_set_ip_blocks(struct

amdgpu_device *adev)

Quoted 10 lines
Quoted 10 lines
drivers/gpu/drm/amd/amdgpu/amdgpu_discovery.c +1 -1
                break;
        case IP_VERSION(10, 3, 1):
                adev->family = AMDGPU_FAMILY_VGH;
+               adev->apu_flags |= AMD_APU_IS_VANGOGH;
                break;
        case IP_VERSION(10, 3, 3):
                adev->family = AMDGPU_FAMILY_YC;
--

2.34.1

#6 lore raw

RE: [PATCH 2/2] drm/amdgpu: add Vangogh APU flag to IP discovery path

[AMD Official Use Only - General]

Hi Alex.

Quoted 54 lines

-----Original Message-----
From: Alex Deucher <[email protected]>
Sent: Tuesday, November 1, 2022 11:25 PM
To: Yuan, Perry <[email protected]>
Cc: Deucher, Alexander <[email protected]>; Huang, Ray <[email protected]>; Huang, Shimmer <[email protected]>; [email protected]
Subject: Re: [PATCH 2/2] drm/amdgpu: add Vangogh APU flag to IP discovery path

Caution: This message originated from an External Source. Use proper caution when opening attachments, clicking links, or responding.

Quoted 24 lines · Perry

[AMD Official Use Only - General]

Hi Alex

Quoted 19 lines

-----Original Message-----
From: amd-gfx <[email protected]> On Behalf Of Alex Deucher
Sent: Tuesday, November 1, 2022 9:25 PM
To: Yuan, Perry <[email protected]>
Cc: Deucher, Alexander <[email protected]>; Huang, Ray <[email protected]>; Huang, Shimmer <[email protected]>; [email protected]
Subject: Re: [PATCH 2/2] drm/amdgpu: add Vangogh APU flag to IP discovery path

Caution: This message originated from an External Source. Use proper caution when opening attachments, clicking links, or responding.

Quoted 2 lines · Alex Deucher

On Tue, Nov 1, 2022 at 1:16 AM Perry Yuan <[email protected]>

Quoted 14 lines · wrote:
Quoted 13 lines
Quoted 8 lines
Quoted 5 lines

Add the missing apu flag for Vangogh when using IP discovery code path to initialize IPs

Swap the order of the patches. With that, the series is:

Actually, you also need to fix up check_seamless_boot_capability() in amdgpu_dm.c. Switch that to an IP version check.

Alex

Quoted 7 lines
Quoted 1 line

I am not sure if the IP versions only correctly match the GPUs.

It should match gfx IP_VERSION(10, 3, 1). You are using that to set the APU flag in this patch. The DCN version (3.0.1) is also unique to this chip and that would better match the fact that this is a DCN related function.

Alex

Great, this will be better to match, I will make the change in V2.

Quoted 39 lines
Quoted 39 lines

How about using the apu flags like this ?

bool check_seamless_boot_capability(struct amdgpu_device *adev) {
        if (adev->apu_flags & AMD_APU_IS_VANGOGH) {
                if (!adev->mman.keep_stolen_vga_memory)
                        return true;
        }

        return false;
}

Perry.

Quoted 24 lines
Quoted 7 lines
Quoted 7 lines


---
 drivers/gpu/drm/amd/amdgpu/amdgpu_discovery.c | 1 +
 1 file changed, 1 insertion(+)
Quoted 6 lines

drivers/gpu/drm/amd/amdgpu/amdgpu_discovery.c int amdgpu_discovery_set_ip_blocks(struct

Quoted 6 lines
drivers/gpu/drm/amd/amdgpu/amdgpu_discovery.c +0 -0
index 3993e6134914..52a92add12ea 100644
@@ -2161,6 +2161,7 @@ int amdgpu_discovery_set_ip_blocks(struct

amdgpu_device *adev)

Quoted 10 lines
Quoted 10 lines
drivers/gpu/drm/amd/amdgpu/amdgpu_discovery.c +1 -1
                break;
        case IP_VERSION(10, 3, 1):
                adev->family = AMDGPU_FAMILY_VGH;
+               adev->apu_flags |= AMD_APU_IS_VANGOGH;
                break;
        case IP_VERSION(10, 3, 3):
                adev->family = AMDGPU_FAMILY_YC;
--

2.34.1