xref: /linux-6.15/drivers/base/hypervisor.c (revision 989d42e8)
1 // SPDX-License-Identifier: GPL-2.0
2 /*
3  * hypervisor.c - /sys/hypervisor subsystem.
4  *
5  * Copyright (C) IBM Corp. 2006
6  * Copyright (C) 2007 Greg Kroah-Hartman <[email protected]>
7  * Copyright (C) 2007 Novell Inc.
8  *
9  * This file is released under the GPLv2
10  */
11 
12 #include <linux/kobject.h>
13 #include <linux/device.h>
14 #include <linux/export.h>
15 #include "base.h"
16 
17 struct kobject *hypervisor_kobj;
18 EXPORT_SYMBOL_GPL(hypervisor_kobj);
19 
20 int __init hypervisor_init(void)
21 {
22 	hypervisor_kobj = kobject_create_and_add("hypervisor", NULL);
23 	if (!hypervisor_kobj)
24 		return -ENOMEM;
25 	return 0;
26 }
27