misc: mei: unregister misc device in pci_remove function
authorTomas Winkler <tomas.winkler@intel.com>
Tue, 29 May 2012 13:39:11 +0000 (16:39 +0300)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 13 Jun 2012 20:52:14 +0000 (13:52 -0700)
commita44cab4aff7e72e7052521121fd8ceca51351534
tree2170a035f4bc242f75a523622c281e49b0d1dd7d
parentaa189ecdc0c7fad2166ba6d133df8bd214550f68
misc: mei: unregister misc device in pci_remove function

Since the misc device is registered only in the pci probe function
it has to be also unregistered in the counterpart pci remove function
and not in the module exit function.
In case of probe failure the driver was oopsing in module exit function.

Signed-off-by: Tomas Winkler <tomas.winkler@intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/misc/mei/main.c