From: Johan Hovold Date: Wed, 25 Nov 2015 14:58:58 +0000 (+0100) Subject: greybus: interface: add interface_id attribute X-Git-Tag: v4.9-rc1~119^2~378^2~21^2~1015 X-Git-Url: https://git.kernel.dk/?a=commitdiff_plain;h=320421a80bdd0f7373dbba0bf01b594e12d57218;p=linux-block.git greybus: interface: add interface_id attribute Add interface_id attribute that user space needs to identify an interface. Signed-off-by: Johan Hovold Signed-off-by: Greg Kroah-Hartman --- diff --git a/drivers/staging/greybus/interface.c b/drivers/staging/greybus/interface.c index 4ed782e6c7b0..b5d9046ead44 100644 --- a/drivers/staging/greybus/interface.c +++ b/drivers/staging/greybus/interface.c @@ -20,12 +20,14 @@ static ssize_t field##_show(struct device *dev, \ } \ static DEVICE_ATTR_RO(field) +gb_interface_attr(interface_id, u); gb_interface_attr(vendor_id, x); gb_interface_attr(product_id, x); gb_interface_attr(vendor_string, s); gb_interface_attr(product_string, s); static struct attribute *interface_attrs[] = { + &dev_attr_interface_id.attr, &dev_attr_vendor_id.attr, &dev_attr_product_id.attr, &dev_attr_vendor_string.attr,