accel/qaic: Add AIC200 support
[drm/drm-misc.git] / include / linux / greybus / module.h
blob3efe2133acfd2044931156bdf27b5c543f1999b2
1 /* SPDX-License-Identifier: GPL-2.0 */
2 /*
3 * Greybus Module code
5 * Copyright 2016 Google Inc.
6 * Copyright 2016 Linaro Ltd.
7 */
9 #ifndef __MODULE_H
10 #define __MODULE_H
12 #include <linux/types.h>
13 #include <linux/device.h>
15 struct gb_module {
16 struct device dev;
17 struct gb_host_device *hd;
19 struct list_head hd_node;
21 u8 module_id;
22 size_t num_interfaces;
24 bool disconnected;
26 struct gb_interface *interfaces[];
28 #define to_gb_module(d) container_of(d, struct gb_module, dev)
30 struct gb_module *gb_module_create(struct gb_host_device *hd, u8 module_id,
31 size_t num_interfaces);
32 int gb_module_add(struct gb_module *module);
33 void gb_module_del(struct gb_module *module);
34 void gb_module_put(struct gb_module *module);
36 #endif /* __MODULE_H */