EXPORT_SYMBOL_GPL(greybus_disabled);
static int greybus_match_one_id(struct greybus_device *gdev,
- const struct greybus_device_id *id)
+ const struct greybus_module_id *id)
{
struct greybus_descriptor *des = &gdev->descriptor;
return 1;
}
-static const struct greybus_device_id *greybus_match_id(
+static const struct greybus_module_id *greybus_match_id(
struct greybus_device *gdev,
- const struct greybus_device_id *id)
+ const struct greybus_module_id *id)
{
if (id == NULL)
return NULL;
{
struct greybus_driver *driver = to_greybus_driver(dev->driver);
struct greybus_device *gdev = to_greybus_device(dev);
- const struct greybus_device_id *id;
+ const struct greybus_module_id *id;
id = greybus_match_id(gdev, driver->id_table);
if (id)
{
struct greybus_driver *driver = to_greybus_driver(dev->driver);
struct greybus_device *gdev = to_greybus_device(dev);
- const struct greybus_device_id *id;
+ const struct greybus_module_id *id;
int retval;
/* match id */
static int new_device(struct greybus_device *gdev,
- const struct greybus_device_id *id)
+ const struct greybus_module_id *id)
{
int retval;
// FIXME - some lock?
};
-static const struct greybus_device_id id_table[] = {
+static const struct greybus_module_id id_table[] = {
{ GREYBUS_DEVICE(0x44, 0x44) }, /* make shit up */
{ }, /* terminating NULL entry */
};
}
int gb_gpio_probe(struct greybus_device *gdev,
- const struct greybus_device_id *id)
+ const struct greybus_module_id *id)
{
struct gb_gpio_device *gb_gpio;
struct gpio_chip *gpio;
const char *name;
int (*probe)(struct greybus_device *gdev,
- const struct greybus_device_id *id);
+ const struct greybus_module_id *id);
void (*disconnect)(struct greybus_device *gdev);
int (*suspend)(struct greybus_device *gdev, pm_message_t message);
int (*resume)(struct greybus_device *gdev);
- const struct greybus_device_id *id_table;
+ const struct greybus_module_id *id_table;
struct device_driver driver;
};
* we have static functions for this, not "dynamic" drivers like we really
* should in the end.
*/
-int gb_i2c_probe(struct greybus_device *gdev, const struct greybus_device_id *id);
+int gb_i2c_probe(struct greybus_device *gdev, const struct greybus_module_id *id);
void gb_i2c_disconnect(struct greybus_device *gdev);
-int gb_gpio_probe(struct greybus_device *gdev, const struct greybus_device_id *id);
+int gb_gpio_probe(struct greybus_device *gdev, const struct greybus_module_id *id);
void gb_gpio_disconnect(struct greybus_device *gdev);
-int gb_sdio_probe(struct greybus_device *gdev, const struct greybus_device_id *id);
+int gb_sdio_probe(struct greybus_device *gdev, const struct greybus_module_id *id);
void gb_sdio_disconnect(struct greybus_device *gdev);
-int gb_tty_probe(struct greybus_device *gdev, const struct greybus_device_id *id);
+int gb_tty_probe(struct greybus_device *gdev, const struct greybus_module_id *id);
void gb_tty_disconnect(struct greybus_device *gdev);
int gb_tty_init(void);
#include <linux/mod_devicetable.h>
-struct greybus_device_id {
+struct greybus_module_id {
__u16 match_flags;
__u16 wVendor;
__u16 wProduct;
struct greybus_device *gdev;
};
-static const struct greybus_device_id id_table[] = {
+static const struct greybus_module_id id_table[] = {
{ GREYBUS_DEVICE(0x42, 0x42) }, /* make shit up */
{ }, /* terminating NULL entry */
};
};
int gb_i2c_probe(struct greybus_device *gdev,
- const struct greybus_device_id *id)
+ const struct greybus_module_id *id)
{
struct gb_i2c_device *gb_i2c_dev;
struct i2c_adapter *adapter;
// FIXME - some lock?
};
-static const struct greybus_device_id id_table[] = {
+static const struct greybus_module_id id_table[] = {
{ GREYBUS_DEVICE(0x43, 0x43) }, /* make shit up */
{ }, /* terminating NULL entry */
};
};
int gb_sdio_probe(struct greybus_device *gdev,
- const struct greybus_device_id *id)
+ const struct greybus_module_id *id)
{
struct mmc_host *mmc;
struct gb_sdio_host *host;
struct mutex mutex;
};
-static const struct greybus_device_id id_table[] = {
+static const struct greybus_module_id id_table[] = {
{ GREYBUS_DEVICE(0x45, 0x45) }, /* make shit up */
{ }, /* terminating NULL entry */
};
int gb_tty_probe(struct greybus_device *gdev,
- const struct greybus_device_id *id)
+ const struct greybus_module_id *id)
{
struct gb_tty *gb_tty;
struct device *tty_dev;