mirror of
				https://git.proxmox.com/git/mirror_zfs.git
				synced 2025-10-26 18:05:04 +03:00 
			
		
		
		
	Make zfs_async_block_max_blocks handle zero correctly
Reviewed-by: Matt Ahrens <mahrens@delphix.com> Reviewed-by: Paul Dagnelie <pcd@delphix.com> Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov> Signed-off-by: TulsiJain <tulsi.jain@delphix.com> Closes #8829 Closes #8289
This commit is contained in:
		
							parent
							
								
									4f8eef29e0
								
							
						
					
					
						commit
						11ad06d1d8
					
				| @ -3025,8 +3025,10 @@ dsl_scan_async_block_should_pause(dsl_scan_t *scn) | |||||||
| 	if (zfs_recover) | 	if (zfs_recover) | ||||||
| 		return (B_FALSE); | 		return (B_FALSE); | ||||||
| 
 | 
 | ||||||
| 	if (scn->scn_visited_this_txg >= zfs_async_block_max_blocks) | 	if (zfs_async_block_max_blocks != 0 && | ||||||
|  | 	    scn->scn_visited_this_txg >= zfs_async_block_max_blocks) { | ||||||
| 		return (B_TRUE); | 		return (B_TRUE); | ||||||
|  | 	} | ||||||
| 
 | 
 | ||||||
| 	elapsed_nanosecs = gethrtime() - scn->scn_sync_start_time; | 	elapsed_nanosecs = gethrtime() - scn->scn_sync_start_time; | ||||||
| 	return (elapsed_nanosecs / NANOSEC > zfs_txg_timeout || | 	return (elapsed_nanosecs / NANOSEC > zfs_txg_timeout || | ||||||
|  | |||||||
		Loading…
	
		Reference in New Issue
	
	Block a user
	 TulsiJain
						TulsiJain