Commit edb0e0b5 authored by Greg Kroah-Hartman's avatar Greg Kroah-Hartman

greybus: interface: rename greybus_interface_block_id to greybus_interface_id

This moves the id structure name to not have "block" in it, as that
doesn't make sense anymore with the renaming of the gb_interface
structure.
Reviewed-by: default avatarAlex Elder <elder@linaro.org>
Signed-off-by: default avatarGreg Kroah-Hartman <greg@kroah.com>
parent 4ab9b3c2
...@@ -35,7 +35,7 @@ static int greybus_module_match(struct device *dev, struct device_driver *drv) ...@@ -35,7 +35,7 @@ static int greybus_module_match(struct device *dev, struct device_driver *drv)
{ {
struct greybus_driver *driver = to_greybus_driver(drv); struct greybus_driver *driver = to_greybus_driver(drv);
struct gb_interface *intf = to_gb_interface(dev); struct gb_interface *intf = to_gb_interface(dev);
const struct greybus_interface_block_id *id; const struct greybus_interface_id *id;
id = gb_interface_match_id(intf, driver->id_table); id = gb_interface_match_id(intf, driver->id_table);
if (id) if (id)
...@@ -95,7 +95,7 @@ static int greybus_probe(struct device *dev) ...@@ -95,7 +95,7 @@ static int greybus_probe(struct device *dev)
{ {
struct greybus_driver *driver = to_greybus_driver(dev->driver); struct greybus_driver *driver = to_greybus_driver(dev->driver);
struct gb_interface *intf = to_gb_interface(dev); struct gb_interface *intf = to_gb_interface(dev);
const struct greybus_interface_block_id *id; const struct greybus_interface_id *id;
int retval; int retval;
/* match id */ /* match id */
......
...@@ -120,13 +120,13 @@ struct greybus_driver { ...@@ -120,13 +120,13 @@ struct greybus_driver {
const char *name; const char *name;
int (*probe)(struct gb_interface *intf, int (*probe)(struct gb_interface *intf,
const struct greybus_interface_block_id *id); const struct greybus_interface_id *id);
void (*disconnect)(struct gb_interface *intf); void (*disconnect)(struct gb_interface *intf);
int (*suspend)(struct gb_interface *intf, pm_message_t message); int (*suspend)(struct gb_interface *intf, pm_message_t message);
int (*resume)(struct gb_interface *intf); int (*resume)(struct gb_interface *intf);
const struct greybus_interface_block_id *id_table; const struct greybus_interface_id *id_table;
struct device_driver driver; struct device_driver driver;
}; };
......
...@@ -9,7 +9,7 @@ ...@@ -9,7 +9,7 @@
#include <linux/mod_devicetable.h> #include <linux/mod_devicetable.h>
struct greybus_interface_block_id { struct greybus_interface_id {
__u16 match_flags; __u16 match_flags;
__u16 vendor; __u16 vendor;
__u16 product; __u16 product;
...@@ -18,7 +18,7 @@ struct greybus_interface_block_id { ...@@ -18,7 +18,7 @@ struct greybus_interface_block_id {
kernel_ulong_t driver_info __aligned(sizeof(kernel_ulong_t)); kernel_ulong_t driver_info __aligned(sizeof(kernel_ulong_t));
}; };
/* Used to match the greybus_interface_block_id */ /* Used to match the greybus_interface_id */
#define GREYBUS_ID_MATCH_VENDOR BIT(0) #define GREYBUS_ID_MATCH_VENDOR BIT(0)
#define GREYBUS_ID_MATCH_PRODUCT BIT(1) #define GREYBUS_ID_MATCH_PRODUCT BIT(1)
#define GREYBUS_ID_MATCH_SERIAL BIT(2) #define GREYBUS_ID_MATCH_SERIAL BIT(2)
......
...@@ -41,7 +41,7 @@ ATTRIBUTE_GROUPS(interface); ...@@ -41,7 +41,7 @@ ATTRIBUTE_GROUPS(interface);
static DEFINE_SPINLOCK(gb_modules_lock); static DEFINE_SPINLOCK(gb_modules_lock);
static int gb_interface_match_one_id(struct gb_interface *intf, static int gb_interface_match_one_id(struct gb_interface *intf,
const struct greybus_interface_block_id *id) const struct greybus_interface_id *id)
{ {
if ((id->match_flags & GREYBUS_ID_MATCH_VENDOR) && if ((id->match_flags & GREYBUS_ID_MATCH_VENDOR) &&
(id->vendor != intf->vendor)) (id->vendor != intf->vendor))
...@@ -58,9 +58,9 @@ static int gb_interface_match_one_id(struct gb_interface *intf, ...@@ -58,9 +58,9 @@ static int gb_interface_match_one_id(struct gb_interface *intf,
return 1; return 1;
} }
const struct greybus_interface_block_id * const struct greybus_interface_id *
gb_interface_match_id(struct gb_interface *intf, gb_interface_match_id(struct gb_interface *intf,
const struct greybus_interface_block_id *id) const struct greybus_interface_id *id)
{ {
if (id == NULL) if (id == NULL)
return NULL; return NULL;
......
...@@ -47,9 +47,9 @@ static inline void * gb_interface__get_drvdata(struct gb_interface *intf) ...@@ -47,9 +47,9 @@ static inline void * gb_interface__get_drvdata(struct gb_interface *intf)
/* Greybus "private" definitions */ /* Greybus "private" definitions */
const struct greybus_interface_block_id * const struct greybus_interface_id *
gb_interface_match_id(struct gb_interface *intf, gb_interface_match_id(struct gb_interface *intf,
const struct greybus_interface_block_id *id); const struct greybus_interface_id *id);
struct gb_interface *gb_interface_find(struct greybus_host_device *hd, struct gb_interface *gb_interface_find(struct greybus_host_device *hd,
u8 module_id); u8 module_id);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment