xen: fix for V4.16-rc5
-----BEGIN PGP SIGNATURE----- Version: GnuPG v2 iQEcBAABAgAGBQJaotGdAAoJELDendYovxMvzPoIAJ/wdIyikhIl4gFRY3dNJUfk iPfqmzc5y6zqVMYOHXy4aM1WsNqSJjzHQPNQQ/EgPC6EwvqnbRKTA1Z+06t8idtx RsjmQaiXUo+Rdo0QnuFUEZYwrec74GasujsnLy/CJcJOK6bULyoCETDluU6cXUJ1 VcETKTselFPb19Hah6SNOkKn00J6ZYLddpF9RcYEpbln7cAzWKTvd0B/kNW24ToM OkH4m0qO0OzNHxLO31ZG2H/C8VukscQO7PTdcECenjkXnyztfkoLzCJswd7hGIDE JmQJgWKALZfPtwqFztC1bu7Y0N+aOxChggaXxKPlytmfs083EGFZ8H5SYZnhugs= =mXIM -----END PGP SIGNATURE----- Merge tag 'for-linus-4.16a-rc5-tag' of git://git.kernel.org/pub/scm/linux/kernel/git/xen/tip Pull xen fix from Juergen Gross: "Just one fix for the correct error handling after a failed device_register()" * tag 'for-linus-4.16a-rc5-tag' of git://git.kernel.org/pub/scm/linux/kernel/git/xen/tip: xen: xenbus: use put_device() instead of kfree()
This commit is contained in:
commit
39614481fb
|
@ -466,8 +466,11 @@ int xenbus_probe_node(struct xen_bus_type *bus,
|
||||||
|
|
||||||
/* Register with generic device framework. */
|
/* Register with generic device framework. */
|
||||||
err = device_register(&xendev->dev);
|
err = device_register(&xendev->dev);
|
||||||
if (err)
|
if (err) {
|
||||||
|
put_device(&xendev->dev);
|
||||||
|
xendev = NULL;
|
||||||
goto fail;
|
goto fail;
|
||||||
|
}
|
||||||
|
|
||||||
return 0;
|
return 0;
|
||||||
fail:
|
fail:
|
||||||
|
|
Loading…
Reference in New Issue