/** * iwl_dhc_resp_status - return status of DHC response * @fw: firwmware image information * @pkt: response packet, must not be %NULL * * Returns: the status value of the DHC command or (u32)-1 if the * response was too short.
*/ staticinline u32 iwl_dhc_resp_status(conststruct iwl_fw *fw, struct iwl_rx_packet *pkt)
{ if (iwl_fw_lookup_notif_ver(fw, IWL_ALWAYS_LONG_GROUP,
DEBUG_HOST_COMMAND, 1) >= 2) { struct iwl_dhc_cmd_resp *resp = (void *)pkt->data;
if (iwl_rx_packet_payload_len(pkt) < sizeof(*resp)) return (u32)-1;
if (iwl_rx_packet_payload_len(pkt) < sizeof(*resp)) return (u32)-1;
return le32_to_cpu(resp->status);
}
}
/** * iwl_dhc_resp_data - return data pointer of DHC response * @fw: firwmware image information * @pkt: response packet, must not be %NULL * @len: where to store the length * * Returns: The data pointer, or an ERR_PTR() if the data was * not valid (too short).
*/ staticinlinevoid *iwl_dhc_resp_data(conststruct iwl_fw *fw, struct iwl_rx_packet *pkt, unsignedint *len)
{ if (iwl_fw_lookup_notif_ver(fw, IWL_ALWAYS_LONG_GROUP,
DEBUG_HOST_COMMAND, 1) >= 2) { struct iwl_dhc_cmd_resp *resp = (void *)pkt->data;
if (iwl_rx_packet_payload_len(pkt) < sizeof(*resp)) return ERR_PTR(-EINVAL);
Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.
Bemerkung:
Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.