Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 6496a5c9 authored by Vasiliy Kulikov's avatar Vasiliy Kulikov Committed by Chris Metcalf
Browse files

char: hvc: check for error case



hvc_alloc() may fail, if so exit from init() with error.

Signed-off-by: default avatarVasiliy Kulikov <segooon@gmail.com>
Signed-off-by: default avatarChris Metcalf <cmetcalf@tilera.com>
parent 77d23303
Loading
Loading
Loading
Loading
+3 −2
Original line number Diff line number Diff line
@@ -61,7 +61,8 @@ console_initcall(hvc_tile_console_init);

static int __init hvc_tile_init(void)
{
	hvc_alloc(0, 0, &hvc_tile_get_put_ops, 128);
	return 0;
	struct hvc_struct *s;
	s = hvc_alloc(0, 0, &hvc_tile_get_put_ops, 128);
	return IS_ERR(s) ? PTR_ERR(s) : 0;
}
device_initcall(hvc_tile_init);