drivers: ipmi: Drop device reference

Drop the reference to a device found via bus_find_device()

Cc: Corey Minyard <minyard@acm.org>
Cc: Arnd Bergmann <arnd@arndb.de>
Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Signed-off-by: Suzuki K Poulose <suzuki.poulose@arm.com>
Message-Id: <1559577023-558-3-git-send-email-suzuki.poulose@arm.com>
[Moved the put_device() to after the platform_device_unregister(), for
 better style.]
Signed-off-by: Corey Minyard <cminyard@mvista.com>
This commit is contained in:
Suzuki K Poulose 2019-06-03 16:49:28 +01:00 committed by Corey Minyard
parent 2cd0e54489
commit 3559c3270a

View File

@ -444,6 +444,7 @@ void ipmi_remove_platform_device_by_name(char *name)
struct platform_device *pdev = to_platform_device(dev);
platform_device_unregister(pdev);
put_device(dev);
}
}