On Mon, Mar 27, 2017 at 09:00:06AM +0200, Krzysztof Opasiak wrote:
> >+static ssize_t ncontrollers_show(struct device *dev, struct 
> >device_attribute *attr,
> >+                       char *out)
> >+{
> >+    char *s = out;
> >+
> >+    out += sprintf(out, "%d\n", vhci_num_controllers);
> >+    return out - s;
> >+}
> >+static DEVICE_ATTR_RO(ncontrollers);
> >+
> 
> Why you need a special RO attribute for this? Can't just cannot
> check content of directory using for example scandir() to learn what
> we have?
 
We can learn or somebody simply tells, I chose the latter. This makes
it easier as the changelog says?
--
To unsubscribe from this list: send the line "unsubscribe linux-usb" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to