fw_cfg: fix driver remove
authorMarc-André Lureau <marcandre.lureau@redhat.com>
Mon, 20 Nov 2017 09:55:15 +0000 (10:55 +0100)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Fri, 17 Aug 2018 19:01:11 +0000 (21:01 +0200)
commitde59521d508a32c6d9f3ae2bc4473658cd12df79
treecb1523c168412d8bf076e3b63bad9089d7b94908
parent13f12749af15149d0b10b30bf3472b62deded15a
fw_cfg: fix driver remove

commit 23f1b8d938c861ee0bbb786162f7ce0685f722ec upstream.

On driver remove(), all objects created during probe() should be
removed, but sysfs qemu_fw_cfg/rev file was left. Also reorder
functions to match probe() error cleanup code.

Cc: stable@vger.kernel.org
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
Signed-off-by: Sudip Mukherjee <sudipm.mukherjee@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/firmware/qemu_fw_cfg.c