scsi: mpi3mr: Rework mrioc->bsg_device model to fix warnings
During driver unload, mrioc->bsg_device reference count becomes negative. Also, as reported in [1], the driver's bsg_device model had few more bugs. Fix all these up. [1] https://marc.info/?l=linux-scsi&m=165183971411991&w=2 Link: https://lore.kernel.org/r/20220526170157.58274-1-sumit.saxena@broadcom.com Fixes: 4268fa75 ("scsi: mpi3mr: Add bsg device support") Reported-by: NDan Carpenter <dan.carpenter@oracle.com> Tested-by: NTomas Henzl <thenzl@redhat.com> Signed-off-by: NSumit Saxena <sumit.saxena@broadcom.com> Signed-off-by: NMartin K. Petersen <martin.petersen@oracle.com>
Showing
想要评论请 注册 或 登录