forked from rpms/kernel
		
	bsg: fix sysfs link remove warning (#787281)
This commit is contained in:
		
							parent
							
								
									bbb795413f
								
							
						
					
					
						commit
						adf844df81
					
				
							
								
								
									
										16
									
								
								bsg-fix-sysfs-link-remove-warning.patch
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										16
									
								
								bsg-fix-sysfs-link-remove-warning.patch
									
									
									
									
									
										Normal file
									
								
							| @ -0,0 +1,16 @@ | |||||||
|  | diff --git a/block/bsg.c b/block/bsg.c
 | ||||||
|  | index 4cf703f..ff64ae3 100644
 | ||||||
|  | --- a/block/bsg.c
 | ||||||
|  | +++ b/block/bsg.c
 | ||||||
|  | @@ -983,7 +983,8 @@ void bsg_unregister_queue(struct request_queue *q)
 | ||||||
|  |   | ||||||
|  |  	mutex_lock(&bsg_mutex); | ||||||
|  |  	idr_remove(&bsg_minor_idr, bcd->minor); | ||||||
|  | -	sysfs_remove_link(&q->kobj, "bsg");
 | ||||||
|  | +	if (q->kobj.sd)
 | ||||||
|  | +		sysfs_remove_link(&q->kobj, "bsg");
 | ||||||
|  |  	device_unregister(bcd->class_dev); | ||||||
|  |  	bcd->class_dev = NULL; | ||||||
|  |  	kref_put(&bcd->ref, bsg_kref_release_function); | ||||||
|  | -- 
 | ||||||
|  | 1.7.4.4 | ||||||
| @ -729,6 +729,8 @@ Patch12303: dmar-disable-when-ricoh-multifunction.patch | |||||||
| 
 | 
 | ||||||
| Patch13003: efi-dont-map-boot-services-on-32bit.patch | Patch13003: efi-dont-map-boot-services-on-32bit.patch | ||||||
| 
 | 
 | ||||||
|  | Patch14000: bsg-fix-sysfs-link-remove-warning.patch | ||||||
|  | 
 | ||||||
| Patch20000: utrace.patch | Patch20000: utrace.patch | ||||||
| 
 | 
 | ||||||
| # Flattened devicetree support | # Flattened devicetree support | ||||||
| @ -1431,6 +1433,8 @@ ApplyPatch dmar-disable-when-ricoh-multifunction.patch | |||||||
| 
 | 
 | ||||||
| ApplyPatch efi-dont-map-boot-services-on-32bit.patch | ApplyPatch efi-dont-map-boot-services-on-32bit.patch | ||||||
| 
 | 
 | ||||||
|  | ApplyPatch bsg-fix-sysfs-link-remove-warning.patch | ||||||
|  | 
 | ||||||
| # utrace. | # utrace. | ||||||
| ApplyPatch utrace.patch | ApplyPatch utrace.patch | ||||||
| 
 | 
 | ||||||
| @ -2322,6 +2326,9 @@ fi | |||||||
| #                 ||----w | | #                 ||----w | | ||||||
| #                 ||     || | #                 ||     || | ||||||
| %changelog | %changelog | ||||||
|  | * Thu Feb 09 2012 Dave Jones <davej@redhat.com> | ||||||
|  | - bsg: fix sysfs link remove warning (#787281) | ||||||
|  | 
 | ||||||
| * Thu Feb 09 2012 Josh Boyer <jwboyer@gmail.com> - 3.3.0-0.rc3.git0.2 | * Thu Feb 09 2012 Josh Boyer <jwboyer@gmail.com> - 3.3.0-0.rc3.git0.2 | ||||||
| - Disable debugging options. | - Disable debugging options. | ||||||
| 
 | 
 | ||||||
|  | |||||||
		Loading…
	
		Reference in New Issue
	
	Block a user