mirror of
				https://github.com/torvalds/linux.git
				synced 2025-11-04 10:40:15 +02:00 
			
		
		
		
	drm/amdgpu: update retry times for psp vmbx wait
Increase the retry loops and replace the constant number with macro. Signed-off-by: Tao Zhou <tao.zhou1@amd.com> Reviewed-by: Hawking Zhang <Hawking.Zhang@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
This commit is contained in:
		
							parent
							
								
									30a24318cc
								
							
						
					
					
						commit
						fc59889071
					
				
					 1 changed files with 4 additions and 1 deletions
				
			
		| 
						 | 
					@ -59,6 +59,9 @@ MODULE_FIRMWARE("amdgpu/psp_14_0_0_ta.bin");
 | 
				
			||||||
/* Read USB-PD from LFB */
 | 
					/* Read USB-PD from LFB */
 | 
				
			||||||
#define GFX_CMD_USB_PD_USE_LFB 0x480
 | 
					#define GFX_CMD_USB_PD_USE_LFB 0x480
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					/* Retry times for vmbx ready wait */
 | 
				
			||||||
 | 
					#define PSP_VMBX_POLLING_LIMIT 20000
 | 
				
			||||||
 | 
					
 | 
				
			||||||
/* VBIOS gfl defines */
 | 
					/* VBIOS gfl defines */
 | 
				
			||||||
#define MBOX_READY_MASK 0x80000000
 | 
					#define MBOX_READY_MASK 0x80000000
 | 
				
			||||||
#define MBOX_STATUS_MASK 0x0000FFFF
 | 
					#define MBOX_STATUS_MASK 0x0000FFFF
 | 
				
			||||||
| 
						 | 
					@ -138,7 +141,7 @@ static int psp_v13_0_wait_for_vmbx_ready(struct psp_context *psp)
 | 
				
			||||||
	struct amdgpu_device *adev = psp->adev;
 | 
						struct amdgpu_device *adev = psp->adev;
 | 
				
			||||||
	int retry_loop, ret;
 | 
						int retry_loop, ret;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
	for (retry_loop = 0; retry_loop < 70; retry_loop++) {
 | 
						for (retry_loop = 0; retry_loop < PSP_VMBX_POLLING_LIMIT; retry_loop++) {
 | 
				
			||||||
		/* Wait for bootloader to signify that is
 | 
							/* Wait for bootloader to signify that is
 | 
				
			||||||
		   ready having bit 31 of C2PMSG_33 set to 1 */
 | 
							   ready having bit 31 of C2PMSG_33 set to 1 */
 | 
				
			||||||
		ret = psp_wait_for(
 | 
							ret = psp_wait_for(
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
		Loading…
	
		Reference in a new issue