mirror of
				https://github.com/torvalds/linux.git
				synced 2025-11-04 10:40:15 +02:00 
			
		
		
		
	intel_th: msu: Use the real device in case of IOMMU domain allocation
When allocating DMA buffers for the MSU, use the real device instead of GTH. Signed-off-by: Alexander Shishkin <alexander.shishkin@linux.intel.com>
This commit is contained in:
		
							parent
							
								
									a753bfcfdb
								
							
						
					
					
						commit
						d5c435df4a
					
				
					 1 changed files with 6 additions and 6 deletions
				
			
		| 
						 | 
				
			
			@ -709,17 +709,17 @@ static int msc_buffer_win_alloc(struct msc *msc, unsigned int nr_blocks)
 | 
			
		|||
	}
 | 
			
		||||
 | 
			
		||||
	for (i = 0; i < nr_blocks; i++) {
 | 
			
		||||
		win->block[i].bdesc = dma_alloc_coherent(msc_dev(msc), size,
 | 
			
		||||
							 &win->block[i].addr,
 | 
			
		||||
							 GFP_KERNEL);
 | 
			
		||||
		win->block[i].bdesc =
 | 
			
		||||
			dma_alloc_coherent(msc_dev(msc)->parent->parent, size,
 | 
			
		||||
					   &win->block[i].addr, GFP_KERNEL);
 | 
			
		||||
 | 
			
		||||
		if (!win->block[i].bdesc)
 | 
			
		||||
			goto err_nomem;
 | 
			
		||||
 | 
			
		||||
#ifdef CONFIG_X86
 | 
			
		||||
		/* Set the page as uncached */
 | 
			
		||||
		set_memory_uc((unsigned long)win->block[i].bdesc, 1);
 | 
			
		||||
#endif
 | 
			
		||||
 | 
			
		||||
		if (!win->block[i].bdesc)
 | 
			
		||||
			goto err_nomem;
 | 
			
		||||
	}
 | 
			
		||||
 | 
			
		||||
	win->msc = msc;
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Loading…
	
		Reference in a new issue