/* Sanity checks */
if (msg->len == 0 || msg->len > CEC_MAX_MSG_SIZE) {
- dprintk(1, "cec_transmit_msg: invalid length %d\n", msg->len);
+ dprintk(1, "%s: invalid length %d\n", __func__, msg->len);
return -EINVAL;
}
if (msg->timeout && msg->len == 1) {
- dprintk(1, "cec_transmit_msg: can't reply for poll msg\n");
+ dprintk(1, "%s: can't reply for poll msg\n", __func__);
return -EINVAL;
}
memset(msg->msg + msg->len, 0, sizeof(msg->msg) - msg->len);
if (msg->len == 1) {
if (cec_msg_destination(msg) == 0xf) {
- dprintk(1, "cec_transmit_msg: invalid poll message\n");
+ dprintk(1, "%s: invalid poll message\n", __func__);
return -EINVAL;
}
if (cec_has_log_addr(adap, cec_msg_destination(msg))) {
}
if (msg->len > 1 && !cec_msg_is_broadcast(msg) &&
cec_has_log_addr(adap, cec_msg_destination(msg))) {
- dprintk(1, "cec_transmit_msg: destination is the adapter itself\n");
+ dprintk(1, "%s: destination is the adapter itself\n", __func__);
return -EINVAL;
}
if (msg->len > 1 && adap->is_configured &&
!cec_has_log_addr(adap, cec_msg_initiator(msg))) {
- dprintk(1, "cec_transmit_msg: initiator has unknown logical address %d\n",
- cec_msg_initiator(msg));
+ dprintk(1, "%s: initiator has unknown logical address %d\n",
+ __func__, cec_msg_initiator(msg));
return -EINVAL;
}
if (!adap->is_configured && !adap->is_configuring &&
}
if (msg->timeout)
- dprintk(2, "cec_transmit_msg: %*ph (wait for 0x%02x%s)\n",
- msg->len, msg->msg, msg->reply, !block ? ", nb" : "");
+ dprintk(2, "%s: %*ph (wait for 0x%02x%s)\n",
+ __func__, msg->len, msg->msg, msg->reply, !block ? ", nb" : "");
else
- dprintk(2, "cec_transmit_msg: %*ph%s\n",
- msg->len, msg->msg, !block ? " (nb)" : "");
+ dprintk(2, "%s: %*ph%s\n",
+ __func__, msg->len, msg->msg, !block ? " (nb)" : "");
data->msg = *msg;
data->fh = fh;