]> git.baikalelectronics.ru Git - kernel.git/commit
xen/mce: fix up xen_late_init_mcelog() error handling
authorDan Carpenter <dan.carpenter@oracle.com>
Thu, 5 Mar 2015 11:24:17 +0000 (14:24 +0300)
committerDavid Vrabel <david.vrabel@citrix.com>
Mon, 16 Mar 2015 14:49:15 +0000 (14:49 +0000)
commitde2ad168188f6bee31eaf101aa6cfbe48a0e806d
tree7866d06e9560bee83343c2b08fd20fe47d87bfdb
parentfe35a52049dec5302166f9b402a7daa300031985
xen/mce: fix up xen_late_init_mcelog() error handling

Static checkers complain about the missing call to misc_deregister() if
bind_virq_for_mce() fails.

Also I reversed the tests so that we do error handling instead of
success handling.  That way we just have a series of function calls
instead of the more complicated nested if statements in the original
code.  Let's preserve the error codes as well.

Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Reviewed-by: Konrad Rzeszutek Wilk <konrad.wilk@oracle.com>
Signed-off-by: David Vrabel <david.vrabel@citrix.com>
drivers/xen/mcelog.c