Lines Matching refs:data
178 * The main "user" data structure.
236 * or change any data until the RCU period completes. So we
261 * timeout, and it is used to hold the temporary data for
377 /* The response had invalid data in it. */
404 /* The response had invalid data in it. */
413 /* The command had invalid data in it. */
419 /* Invalid data in an event. */
939 msg->msg.data = msg->msg_data;
1055 * release the sequence number so it can be reused. Some other data
1247 int ipmi_get_smi_info(int if_num, struct ipmi_smi_info *data)
1266 rv = intf->handlers->get_smi_info(intf->send_info, data);
1730 ipmb_checksum(unsigned char *data, int size)
1734 for (; size > 0; size--, data++)
1735 csum += *data;
1751 /* Format the IPMB header data. */
1752 smi_msg->data[0] = (IPMI_NETFN_APP_REQUEST << 2);
1753 smi_msg->data[1] = IPMI_SEND_MSG_CMD;
1754 smi_msg->data[2] = ipmb_addr->channel;
1756 smi_msg->data[3] = 0;
1757 smi_msg->data[i+3] = ipmb_addr->slave_addr;
1758 smi_msg->data[i+4] = (msg->netfn << 2) | (ipmb_addr->lun & 0x3);
1759 smi_msg->data[i+5] = ipmb_checksum(&smi_msg->data[i + 3], 2);
1760 smi_msg->data[i+6] = source_address;
1761 smi_msg->data[i+7] = (ipmb_seq << 2) | source_lun;
1762 smi_msg->data[i+8] = msg->cmd;
1764 /* Now tack on the data to the message. */
1766 memcpy(&smi_msg->data[i + 9], msg->data, msg->data_len);
1770 smi_msg->data[i+smi_msg->data_size]
1771 = ipmb_checksum(&smi_msg->data[i + 6], smi_msg->data_size - 6);
1789 /* Format the IPMB header data. */
1790 smi_msg->data[0] = (IPMI_NETFN_APP_REQUEST << 2);
1791 smi_msg->data[1] = IPMI_SEND_MSG_CMD;
1792 smi_msg->data[2] = lan_addr->channel;
1793 smi_msg->data[3] = lan_addr->session_handle;
1794 smi_msg->data[4] = lan_addr->remote_SWID;
1795 smi_msg->data[5] = (msg->netfn << 2) | (lan_addr->lun & 0x3);
1796 smi_msg->data[6] = ipmb_checksum(&smi_msg->data[4], 2);
1797 smi_msg->data[7] = lan_addr->local_SWID;
1798 smi_msg->data[8] = (ipmb_seq << 2) | source_lun;
1799 smi_msg->data[9] = msg->cmd;
1801 /* Now tack on the data to the message. */
1803 memcpy(&smi_msg->data[10], msg->data, msg->data_len);
1807 smi_msg->data[smi_msg->data_size]
1808 = ipmb_checksum(&smi_msg->data[7], smi_msg->data_size - 7);
1917 smi_msg->data[0] = (msg->netfn << 2) | (smi_addr->lun & 0x3);
1918 smi_msg->data[1] = msg->cmd;
1922 memcpy(&smi_msg->data[2], msg->data, msg->data_len);
2047 * Copy the message into the recv message data, so we
2050 memcpy(recv_msg->msg_data, smi_msg->data,
2052 recv_msg->msg.data = recv_msg->msg_data;
2165 * Copy the message into the recv message data, so we
2168 memcpy(recv_msg->msg_data, smi_msg->data,
2170 recv_msg->msg.data = recv_msg->msg_data;
2248 * responses can get the proper response data.
2273 pr_debug("Send: %*ph\n", smi_msg->data_size, smi_msg->data);
2389 msg->msg.data, msg->msg.data_len, &intf->bmc->fetch_id);
2393 intf->bmc->cc = msg->msg.data[0];
2397 * Make sure the id data is available before setting
2419 msg.data = NULL;
2468 /* dyn_id_set makes the id data available. */
2479 * bmc or intf, this code will get the other one. If the data has
2480 * been recently fetched, this will just use the cached data. Otherwise
2484 * this will always return good data;
2586 rv = 0; /* Ignore failures if we have previous data. */
2846 static int __find_bmc_guid(struct device *dev, const void *data)
2848 const guid_t *guid = data;
2884 static int __find_bmc_prod_dev_id(struct device *dev, const void *data)
2886 const struct prod_dev_id *cid = data;
3159 msg.data = NULL;
3185 if (msg->msg.data[0] != 0) {
3199 import_guid(&bmc->fetch_guid, msg->msg.data + 1);
3201 * Make sure the guid data is available before setting
3224 /* dyn_guid_set makes the guid data available. */
3234 unsigned char data[1];
3243 msg.data = data;
3245 data[0] = chan;
3272 if (msg->msg.data[0] != 0) {
3274 if (msg->msg.data[0] == IPMI_INVALID_COMMAND_ERR) {
3299 chans[ch].medium = msg->msg.data[2] & 0x7f;
3300 chans[ch].protocol = msg->msg.data[3] & 0x1f;
3547 msg->rsp[0] = msg->data[0] | 4;
3548 msg->rsp[1] = msg->data[1];
3695 recv_msg->msg.data = recv_msg->msg_data;
3746 msg->data[0] = (IPMI_NETFN_APP_REQUEST << 2);
3747 msg->data[1] = IPMI_SEND_MSG_CMD;
3748 msg->data[2] = msg->rsp[3];
3749 msg->data[3] = msg->rsp[6];
3750 msg->data[4] = ((netfn + 1) << 2) | (msg->rsp[7] & 0x3);
3751 msg->data[5] = ipmb_checksum(&msg->data[3], 2);
3752 msg->data[6] = intf->addrinfo[msg->rsp[3] & 0xf].address;
3754 msg->data[7] = (msg->rsp[7] & 0xfc) | (msg->rsp[4] & 0x3);
3755 msg->data[8] = msg->rsp[8]; /* cmd */
3756 msg->data[9] = IPMI_INVALID_CMD_COMPLETION_CODE;
3757 msg->data[10] = ipmb_checksum(&msg->data[6], 4);
3760 pr_debug("Invalid command: %*ph\n", msg->data_size, msg->data);
3784 /* Extract the source address from the data. */
3800 recv_msg->msg.data = recv_msg->msg_data;
3875 recv_msg->msg.data = recv_msg->msg_data;
3941 /* Extract the source address from the data. */
3960 recv_msg->msg.data = recv_msg->msg_data;
4067 recv_msg->msg.data = recv_msg->msg_data;
4100 recv_msg->msg.data = recv_msg->msg_data;
4229 recv_msg->msg.data = recv_msg->msg_data;
4250 && (msg->data[0] == (IPMI_NETFN_APP_REQUEST << 2))
4251 && (msg->data[1] == IPMI_SEND_MSG_CMD)
4298 (msg->data[0] >> 2) | 1, msg->data[1], msg->rsp_size);
4301 msg->rsp[0] = msg->data[0] | (1 << 2);
4302 msg->rsp[1] = msg->data[1];
4305 } else if (((msg->rsp[0] >> 2) != ((msg->data[0] >> 2) | 1))
4306 || (msg->rsp[1] != msg->data[1])) {
4313 (msg->data[0] >> 2) | 1, msg->data[1],
4317 msg->rsp[0] = msg->data[0] | (1 << 2);
4318 msg->rsp[1] = msg->data[1];
4337 chan = msg->data[2] & 0x0f;
4346 recv_msg->msg.data = recv_msg->msg_data;
4602 memcpy(smi_msg->data, recv_msg->msg.data, recv_msg->msg.data_len);
4606 pr_debug("Resend: %*ph\n", smi_msg->data_size, smi_msg->data);
4914 && (msg->msg.data[0] == IPMI_CC_NO_ERROR)) {
4916 intf->event_receiver = msg->msg.data[1];
4917 intf->event_receiver_lun = msg->msg.data[2] & 0x3;
4926 && (msg->msg.data[0] == IPMI_CC_NO_ERROR)) {
4931 intf->local_sel_device = (msg->msg.data[6] >> 2) & 1;
4932 intf->local_event_generator = (msg->msg.data[6] >> 5) & 1;
4939 unsigned char data[16];
4957 msg.data = data;
4959 data[0] = 0x41; /* Kernel generator ID, IPMI table 5-4 */
4960 data[1] = 0x03; /* This is for IPMI 1.0. */
4961 data[2] = 0x20; /* OS Critical Stop, IPMI table 36-3 */
4962 data[4] = 0x6f; /* Sensor specific, IPMI table 36-1 */
4963 data[5] = 0xa1; /* Runtime stop OEM bytes 2 & 3. */
4970 data[3] = str[0];
4971 data[6] = str[1];
4972 data[7] = str[2];
4988 * make sure data fetched before checking intf_num
5009 msg.data = NULL;
5018 msg.data = NULL;
5057 msg.data = data;
5066 data[0] = 0;
5067 data[1] = 0;
5068 data[2] = 0xf0; /* OEM event without timestamp. */
5069 data[3] = intf->addrinfo[0].address;
5070 data[4] = j++; /* sequence # */
5075 strncpy(data+5, p, 11);