Lines Matching refs:field
453 #define sas_phy_show_simple(field, name, format_string, cast) \ argument
460 return snprintf(buf, 20, format_string, cast phy->field); \
463 #define sas_phy_simple_attr(field, name, format_string, type) \ argument
464 sas_phy_show_simple(field, name, format_string, (type)) \
467 #define sas_phy_show_protocol(field, name) \ argument
474 if (!phy->field) \
476 return get_sas_protocol_names(phy->field, buf); \
479 #define sas_phy_protocol_attr(field, name) \ argument
480 sas_phy_show_protocol(field, name) \
483 #define sas_phy_show_linkspeed(field) \ argument
485 show_sas_phy_##field(struct device *dev, \
490 return get_sas_linkspeed_names(phy->field, buf); \
494 #define sas_phy_store_linkspeed(field) \ argument
496 store_sas_phy_##field(struct device *dev, \
510 rates.field = value; \
516 #define sas_phy_linkspeed_rw_attr(field) \ argument
517 sas_phy_show_linkspeed(field) \
518 sas_phy_store_linkspeed(field) \
519 static DEVICE_ATTR(field, S_IRUGO, show_sas_phy_##field, \
520 store_sas_phy_##field)
522 #define sas_phy_linkspeed_attr(field) \ argument
523 sas_phy_show_linkspeed(field) \
524 static DEVICE_ATTR(field, S_IRUGO, show_sas_phy_##field, NULL)
527 #define sas_phy_show_linkerror(field) \ argument
529 show_sas_phy_##field(struct device *dev, \
540 return snprintf(buf, 20, "%u\n", phy->field); \
543 #define sas_phy_linkerror_attr(field) \ argument
544 sas_phy_show_linkerror(field) \
545 static DEVICE_ATTR(field, S_IRUGO, show_sas_phy_##field, NULL)
820 #define sas_port_show_simple(field, name, format_string, cast) \ argument
827 return snprintf(buf, 20, format_string, cast port->field); \
830 #define sas_port_simple_attr(field, name, format_string, type) \ argument
831 sas_port_show_simple(field, name, format_string, (type)) \
1167 #define sas_rphy_show_simple(field, name, format_string, cast) \ argument
1174 return snprintf(buf, 20, format_string, cast rphy->field); \
1177 #define sas_rphy_simple_attr(field, name, format_string, type) \ argument
1178 sas_rphy_show_simple(field, name, format_string, (type)) \
1182 #define sas_rphy_show_protocol(field, name) \ argument
1189 if (!rphy->field) \
1191 return get_sas_protocol_names(rphy->field, buf); \
1194 #define sas_rphy_protocol_attr(field, name) \ argument
1195 sas_rphy_show_protocol(field, name) \
1301 #define sas_end_dev_show_simple(field, name, format_string, cast) \ argument
1309 return snprintf(buf, 20, format_string, cast rdev->field); \
1312 #define sas_end_dev_simple_attr(field, name, format_string, type) \ argument
1313 sas_end_dev_show_simple(field, name, format_string, (type)) \
1330 #define sas_expander_show_simple(field, name, format_string, cast) \ argument
1338 return snprintf(buf, 20, format_string, cast edev->field); \
1341 #define sas_expander_simple_attr(field, name, format_string, type) \ argument
1342 sas_expander_show_simple(field, name, format_string, (type)) \
1725 #define SETUP_TEMPLATE(attrb, field, perm, test) \ argument
1726 i->private_##attrb[count] = dev_attr_##field; \
1732 #define SETUP_TEMPLATE_RW(attrb, field, perm, test, ro_test, ro_perm) \ argument
1733 i->private_##attrb[count] = dev_attr_##field; \
1743 #define SETUP_RPORT_ATTRIBUTE(field) \ argument
1744 SETUP_TEMPLATE(rphy_attrs, field, S_IRUGO, 1)
1746 #define SETUP_OPTIONAL_RPORT_ATTRIBUTE(field, func) \ argument
1747 SETUP_TEMPLATE(rphy_attrs, field, S_IRUGO, i->f->func)
1749 #define SETUP_PHY_ATTRIBUTE(field) \ argument
1750 SETUP_TEMPLATE(phy_attrs, field, S_IRUGO, 1)
1752 #define SETUP_PHY_ATTRIBUTE_RW(field) \ argument
1753 SETUP_TEMPLATE_RW(phy_attrs, field, S_IRUGO | S_IWUSR, 1, \
1756 #define SETUP_OPTIONAL_PHY_ATTRIBUTE_RW(field, func) \ argument
1757 SETUP_TEMPLATE_RW(phy_attrs, field, S_IRUGO | S_IWUSR, 1, \
1760 #define SETUP_PORT_ATTRIBUTE(field) \ argument
1761 SETUP_TEMPLATE(port_attrs, field, S_IRUGO, 1)
1763 #define SETUP_OPTIONAL_PHY_ATTRIBUTE(field, func) \ argument
1764 SETUP_TEMPLATE(phy_attrs, field, S_IRUGO, i->f->func)
1766 #define SETUP_PHY_ATTRIBUTE_WRONLY(field) \ argument
1767 SETUP_TEMPLATE(phy_attrs, field, S_IWUSR, 1)
1769 #define SETUP_OPTIONAL_PHY_ATTRIBUTE_WRONLY(field, func) \ argument
1770 SETUP_TEMPLATE(phy_attrs, field, S_IWUSR, i->f->func)
1772 #define SETUP_END_DEV_ATTRIBUTE(field) \ argument
1773 SETUP_TEMPLATE(end_dev_attrs, field, S_IRUGO, 1)
1775 #define SETUP_EXPANDER_ATTRIBUTE(field) \ argument
1776 SETUP_TEMPLATE(expander_attrs, expander_##field, S_IRUGO, 1)