Skip to content

Commit

Permalink
mtip32xx: Remove dfs_parent after pci unregister
Browse files Browse the repository at this point in the history
commit af5ded8 upstream.

In module exit, dfs_parent and it's subtree were removed before
unregistering with pci. When debugfs entry for each device is attempted
to remove in pci_remove() context, they don't exist, as dfs_parent and
its children were already ripped apart.

Modified to first unregister with pci and then remove dfs_parent.

Signed-off-by: Asai Thambi S P <asamymuthupa@micron.com>
Signed-off-by: Jens Axboe <axboe@fb.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
  • Loading branch information
Asai Thambi S P authored and Greg Kroah-Hartman committed Jul 7, 2014
1 parent 9b7aca4 commit 86054ba
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions drivers/block/mtip32xx/mtip32xx.c
Original file line number Diff line number Diff line change
Expand Up @@ -4990,13 +4990,13 @@ static int __init mtip_init(void)
*/
static void __exit mtip_exit(void)
{
debugfs_remove_recursive(dfs_parent);

/* Release the allocated major block device number. */
unregister_blkdev(mtip_major, MTIP_DRV_NAME);

/* Unregister the PCI driver. */
pci_unregister_driver(&mtip_pci_driver);

debugfs_remove_recursive(dfs_parent);
}

MODULE_AUTHOR("Micron Technology, Inc");
Expand Down

0 comments on commit 86054ba

Please sign in to comment.