0
我所做的:
static const struct attribute const *attrs1= {
&foo_attribute.attr,
NULL,
};
static const struct attribute_group const attr_group = {
.attrs = attrs1,
};
但得到这些错误:
error: initializer element is not constant
error: (near initialization for 'attr_group.attrs')
发现this解决方案,但不知道如何解决它...
编辑: 该行触发错误:
.attrs = attrs1,
哪行触发错误? – elyashiv