Lines Matching refs:data
65 struct linkstate_reply_data *data) in linkstate_get_link_ext_state() argument
72 err = dev->ethtool_ops->get_link_ext_state(dev, &data->ethtool_link_ext_state_info); in linkstate_get_link_ext_state()
76 data->link_ext_state_provided = true; in linkstate_get_link_ext_state()
85 struct linkstate_reply_data *data = LINKSTATE_REPDATA(reply_base); in linkstate_prepare_data() local
92 data->link = __ethtool_get_link(dev); in linkstate_prepare_data()
97 data->sqi = ret; in linkstate_prepare_data()
102 data->sqi_max = ret; in linkstate_prepare_data()
105 ret = linkstate_get_link_ext_state(dev, data); in linkstate_prepare_data()
119 struct linkstate_reply_data *data = LINKSTATE_REPDATA(reply_base); in linkstate_reply_size() local
125 if (data->sqi != -EOPNOTSUPP) in linkstate_reply_size()
128 if (data->sqi_max != -EOPNOTSUPP) in linkstate_reply_size()
131 if (data->link_ext_state_provided) in linkstate_reply_size()
134 if (data->ethtool_link_ext_state_info.__link_ext_substate) in linkstate_reply_size()
144 struct linkstate_reply_data *data = LINKSTATE_REPDATA(reply_base); in linkstate_fill_reply() local
146 if (data->link >= 0 && in linkstate_fill_reply()
147 nla_put_u8(skb, ETHTOOL_A_LINKSTATE_LINK, !!data->link)) in linkstate_fill_reply()
150 if (data->sqi != -EOPNOTSUPP && in linkstate_fill_reply()
151 nla_put_u32(skb, ETHTOOL_A_LINKSTATE_SQI, data->sqi)) in linkstate_fill_reply()
154 if (data->sqi_max != -EOPNOTSUPP && in linkstate_fill_reply()
155 nla_put_u32(skb, ETHTOOL_A_LINKSTATE_SQI_MAX, data->sqi_max)) in linkstate_fill_reply()
158 if (data->link_ext_state_provided) { in linkstate_fill_reply()
160 data->ethtool_link_ext_state_info.link_ext_state)) in linkstate_fill_reply()
163 if (data->ethtool_link_ext_state_info.__link_ext_substate && in linkstate_fill_reply()
165 data->ethtool_link_ext_state_info.__link_ext_substate)) in linkstate_fill_reply()