xref: /OK3568_Linux_fs/u-boot/drivers/power/io-domain/io-domain-uclass.c (revision 4882a59341e53eb6f0b4789bf948001014eff981)
1 // SPDX-License-Identifier:     GPL-2.0+
2 /*
3  * (C) Copyright 2018 Rockchip Electronics Co., Ltd
4  */
5 
6 #include <common.h>
7 #include <console.h>
8 #include <io-domain.h>
9 
io_domain_init(void)10 int io_domain_init(void)
11 {
12 	struct udevice *dev;
13 	struct uclass *uc;
14 	int ret;
15 
16 	ret = uclass_get(UCLASS_IO_DOMAIN, &uc);
17 	if (ret)
18 		return ret;
19 
20 	for (uclass_first_device(UCLASS_IO_DOMAIN, &dev);
21 	     dev;
22 	     uclass_next_device(&dev))
23 		;
24 
25 	printf("io-domain: OK\n");
26 
27 	return 0;
28 }
29 
30 UCLASS_DRIVER(io_domain) = {
31 	.id		= UCLASS_IO_DOMAIN,
32 	.name		= "io_domain",
33 };
34