driver/vhost: Call metal_init in vhost_register_drivers
since libmetal come from OpenAMP need be initialized before working Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
This commit is contained in:
parent
f914bc8ef2
commit
1195ec03f7
1 changed files with 8 additions and 1 deletions
|
@ -371,13 +371,20 @@ out:
|
|||
|
||||
void vhost_register_drivers(void)
|
||||
{
|
||||
struct metal_init_params params = METAL_INIT_DEFAULTS;
|
||||
int ret;
|
||||
|
||||
ret = metal_init(¶ms);
|
||||
if (ret < 0)
|
||||
{
|
||||
vhosterr("metal_init failed, ret=%d\n", ret);
|
||||
}
|
||||
|
||||
#ifdef CONFIG_DRIVERS_VHOST_RNG
|
||||
ret = vhost_register_rng_driver();
|
||||
if (ret < 0)
|
||||
{
|
||||
vrterr("vhost_register_rng_driver failed, ret=%d\n", ret);
|
||||
vhosterr("vhost_register_rng_driver failed, ret=%d\n", ret);
|
||||
}
|
||||
#endif
|
||||
|
||||
|
|
Loading…
Reference in a new issue