staging: dgnc: remove pci_unregister_driver
authorSudip Mukherjee <sudipm.mukherjee@gmail.com>
Sat, 27 Feb 2016 12:03:33 +0000 (17:33 +0530)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sat, 12 Mar 2016 06:09:09 +0000 (22:09 -0800)
commite9961fc16f9f11979df616b749d36cf389082047
tree47a29eaec60f07d1395180ed9cf115d76a096b6b
parent757b816e40235e03e1d90c7ec06dad7a684282f3
staging: dgnc: remove pci_unregister_driver

If pci_register_driver() fails then dgnc_NumBoards can never be more
than zero. dgnc_NumBoards is incremented only at the end of a successful
probe. And moreover if the pci driver has failed to register then we
never need to unregister it. Lets just print the warning, perform the
cleanup and exit with the error code.

Signed-off-by: Sudip Mukherjee <sudip.mukherjee@codethink.co.uk>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/staging/dgnc/dgnc_driver.c