uint8_t cmd_code = 0;
if (!buf || len < 0) {
- pr_err("diag: Invalid input in %s, buf: %p, len: %d\n",
+ pr_err("diag: Invalid input in %s, buf: %pK, len: %d\n",
__func__, buf, len);
return -EIO;
}
{
uint16_t rsp_count = 0, delayed_rsp_id = 0;
if (!buf || len <= 0 || !entry) {
- pr_err("diag: In %s, invalid input buf: %p, len: %d, entry: %p\n",
+ pr_err("diag: In %s, invalid input buf: %pK, len: %d, entry: %pK\n",
__func__, buf, len, entry);
return -EIO;
}
int peripheral_mask, status;
if (!buf || (len < sizeof(struct diag_ctrl_dci_status))) {
- pr_err("diag: In %s, invalid buf %p or length: %d\n",
+ pr_err("diag: In %s, invalid buf %pK or length: %d\n",
__func__, buf, len);
return;
}
mutex_unlock(&driver->dci_mutex);
return -ENOMEM;
}
- pr_debug("diag: head of dci log mask %p\n", head_log_mask_ptr);
+ pr_debug("diag: head of dci log mask %pK\n", head_log_mask_ptr);
count = 0; /* iterator for extracting log codes */
while (count < num_codes) {
while (log_mask_ptr && (offset < DCI_LOG_MASK_SIZE)) {
if (*log_mask_ptr == equip_id) {
found = 1;
- pr_debug("diag: find equip id = %x at %p\n",
+ pr_debug("diag: find equip id = %x at %pK\n",
equip_id, log_mask_ptr);
break;
} else {
mutex_unlock(&driver->dci_mutex);
return -ENOMEM;
}
- pr_debug("diag: head of dci event mask %p\n", event_mask_ptr);
+ pr_debug("diag: head of dci event mask %pK\n", event_mask_ptr);
count = 0; /* iterator for extracting log codes */
while (count < num_codes) {
if (read_len >= USER_SPACE_DATA) {
if (!buf || peripheral >= NUM_PERIPHERALS || len < 0 ||
!(driver->feature[PERIPHERAL_MODEM].rcvd_feature_mask)) {
DIAG_LOG(DIAG_DEBUG_DCI,
- "buf: 0x%p, p: %d, len: %d, f_mask: %d\n",
+ "buf: 0x%pK, p: %d, len: %d, f_mask: %d\n",
buf, peripheral, len,
driver->feature[peripheral].rcvd_feature_mask);
return -EINVAL;
-/* Copyright (c) 2011-2015, The Linux Foundation. All rights reserved.
+/* Copyright (c) 2011-2016, The Linux Foundation. All rights reserved.
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License version 2 and
bytes_written = scnprintf(buf+bytes_in_buffer, bytes_remaining,
"id: %d\n"
"name: %s\n"
- "hdl: %p\n"
+ "hdl: %pK\n"
"connected: %d\n"
"diag state: %d\n"
"enabled: %d\n"
bytes_written = scnprintf(buf+bytes_in_buffer,
bytes_remaining,
"name\t\t:\t%s\n"
- "hdl\t\t:\t%p\n"
+ "hdl\t\t:\t%pK\n"
"inited\t\t:\t%d\n"
"opened\t\t:\t%d\n"
"diag_state\t:\t%d\n"
bytes_written = scnprintf(buf+bytes_in_buffer,
bytes_remaining,
"name\t\t:\t%s\n"
- "hdl\t\t:\t%p\n"
+ "hdl\t\t:\t%pK\n"
"inited\t\t:\t%d\n"
"opened\t\t:\t%d\n"
"diag_state\t:\t%d\n"
"bridge index: %s\n"
"mempool: %s\n"
"read ch opened: %d\n"
- "read ch hdl: %p\n"
+ "read ch hdl: %pK\n"
"write ch opened: %d\n"
- "write ch hdl: %p\n"
+ "write ch hdl: %pK\n"
"read work pending: %d\n"
"read done work pending: %d\n"
"open work pending: %d\n"
"type: %d\n"
"inited: %d\n"
"ctxt: %d\n"
- "dev_ops: %p\n"
- "dci_read_buf: %p\n"
- "dci_read_ptr: %p\n"
+ "dev_ops: %pK\n"
+ "dci_read_buf: %pK\n"
+ "dci_read_ptr: %pK\n"
"dci_read_len: %d\n\n",
info->id,
info->name,
if (!driver->diagfwd_cntl[peripheral] ||
!driver->diagfwd_cntl[peripheral]->ch_open) {
- pr_err("diag: In %s, control channel is not open, p: %d, %p\n",
+ pr_err("diag: In %s, control channel is not open, p: %d, %pK\n",
__func__, peripheral, driver->diagfwd_cntl[peripheral]);
return;
}
if (!driver->diagfwd_cntl[peripheral] ||
!driver->diagfwd_cntl[peripheral]->ch_open) {
- pr_err("diag: In %s, control channel is not open, p: %d, %p\n",
+ pr_err("diag: In %s, control channel is not open, p: %d, %pK\n",
__func__, peripheral, driver->diagfwd_cntl[peripheral]);
return;
}
mask_info = (!info) ? &msg_mask : info->msg_mask;
if (!src_buf || !dest_buf || src_len <= 0 || dest_len <= 0 ||
!mask_info) {
- pr_err("diag: Invalid input in %s, src_buf: %p, src_len: %d, dest_buf: %p, dest_len: %d, mask_info: %p\n",
+ pr_err("diag: Invalid input in %s, src_buf: %pK, src_len: %d, dest_buf: %pK, dest_len: %d, mask_info: %pK\n",
__func__, src_buf, src_len, dest_buf, dest_len,
mask_info);
return -EINVAL;
struct diag_msg_build_mask_t rsp;
if (!src_buf || !dest_buf || src_len <= 0 || dest_len <= 0) {
- pr_err("diag: Invalid input in %s, src_buf: %p, src_len: %d, dest_buf: %p, dest_len: %d\n",
+ pr_err("diag: Invalid input in %s, src_buf: %pK, src_len: %d, dest_buf: %pK, dest_len: %d\n",
__func__, src_buf, src_len, dest_buf, dest_len);
return -EINVAL;
}
mask_info = (!info) ? &msg_mask : info->msg_mask;
if (!src_buf || !dest_buf || src_len <= 0 || dest_len <= 0 ||
!mask_info) {
- pr_err("diag: Invalid input in %s, src_buf: %p, src_len: %d, dest_buf: %p, dest_len: %d, mask_info: %p\n",
+ pr_err("diag: Invalid input in %s, src_buf: %pK, src_len: %d, dest_buf: %pK, dest_len: %d, mask_info: %pK\n",
__func__, src_buf, src_len, dest_buf, dest_len,
mask_info);
return -EINVAL;
mask_info = (!info) ? &msg_mask : info->msg_mask;
if (!src_buf || !dest_buf || src_len <= 0 || dest_len <= 0 ||
!mask_info) {
- pr_err("diag: Invalid input in %s, src_buf: %p, src_len: %d, dest_buf: %p, dest_len: %d, mask_info: %p\n",
+ pr_err("diag: Invalid input in %s, src_buf: %pK, src_len: %d, dest_buf: %pK, dest_len: %d, mask_info: %pK\n",
__func__, src_buf, src_len, dest_buf, dest_len,
mask_info);
return -EINVAL;
mask_info = (!info) ? &msg_mask : info->msg_mask;
if (!src_buf || !dest_buf || src_len <= 0 || dest_len <= 0 ||
!mask_info) {
- pr_err("diag: Invalid input in %s, src_buf: %p, src_len: %d, dest_buf: %p, dest_len: %d, mask_info: %p\n",
+ pr_err("diag: Invalid input in %s, src_buf: %pK, src_len: %d, dest_buf: %pK, dest_len: %d, mask_info: %pK\n",
__func__, src_buf, src_len, dest_buf, dest_len,
mask_info);
return -EINVAL;
struct diag_event_mask_config_t rsp;
if (!src_buf || !dest_buf || src_len <= 0 || dest_len <= 0) {
- pr_err("diag: Invalid input in %s, src_buf: %p, src_len: %d, dest_buf: %p, dest_len: %d\n",
+ pr_err("diag: Invalid input in %s, src_buf: %pK, src_len: %d, dest_buf: %pK, dest_len: %d\n",
__func__, src_buf, src_len, dest_buf, dest_len);
return -EINVAL;
}
mask_info = (!info) ? &event_mask : info->event_mask;
if (!src_buf || !dest_buf || src_len <= 0 || dest_len <= 0 ||
!mask_info) {
- pr_err("diag: Invalid input in %s, src_buf: %p, src_len: %d, dest_buf: %p, dest_len: %d, mask_info: %p\n",
+ pr_err("diag: Invalid input in %s, src_buf: %pK, src_len: %d, dest_buf: %pK, dest_len: %d, mask_info: %pK\n",
__func__, src_buf, src_len, dest_buf, dest_len,
mask_info);
return -EINVAL;
mask_info = (!info) ? &event_mask : info->event_mask;
if (!src_buf || !dest_buf || src_len <= 0 || dest_len <= 0 ||
!mask_info) {
- pr_err("diag: Invalid input in %s, src_buf: %p, src_len: %d, dest_buf: %p, dest_len: %d, mask_info: %p\n",
+ pr_err("diag: Invalid input in %s, src_buf: %pK, src_len: %d, dest_buf: %pK, dest_len: %d, mask_info: %pK\n",
__func__, src_buf, src_len, dest_buf, dest_len,
mask_info);
return -EINVAL;
mask_info = (!info) ? &log_mask : info->log_mask;
if (!src_buf || !dest_buf || src_len <= 0 || dest_len <= 0 ||
!mask_info) {
- pr_err("diag: Invalid input in %s, src_buf: %p, src_len: %d, dest_buf: %p, dest_len: %d, mask_info: %p\n",
+ pr_err("diag: Invalid input in %s, src_buf: %pK, src_len: %d, dest_buf: %pK, dest_len: %d, mask_info: %pK\n",
__func__, src_buf, src_len, dest_buf, dest_len,
mask_info);
return -EINVAL;
mask_info = (!info) ? &log_mask : info->log_mask;
if (!src_buf || !dest_buf || src_len <= 0 || dest_len <= 0 ||
!mask_info) {
- pr_err("diag: Invalid input in %s, src_buf: %p, src_len: %d, dest_buf: %p, dest_len: %d, mask_info: %p\n",
+ pr_err("diag: Invalid input in %s, src_buf: %pK, src_len: %d, dest_buf: %pK, dest_len: %d, mask_info: %pK\n",
__func__, src_buf, src_len, dest_buf, dest_len,
mask_info);
return -EINVAL;
mask_info = (!info) ? &log_mask : info->log_mask;
if (!src_buf || !dest_buf || src_len <= 0 || dest_len <= 0 ||
!mask_info) {
- pr_err("diag: Invalid input in %s, src_buf: %p, src_len: %d, dest_buf: %p, dest_len: %d, mask_info: %p\n",
+ pr_err("diag: Invalid input in %s, src_buf: %pK, src_len: %d, dest_buf: %pK, dest_len: %d, mask_info: %pK\n",
__func__, src_buf, src_len, dest_buf, dest_len,
mask_info);
return -EINVAL;
mask_info = (!info) ? &log_mask : info->log_mask;
if (!src_buf || !dest_buf || src_len <= 0 || dest_len <= 0 ||
!mask_info) {
- pr_err("diag: Invalid input in %s, src_buf: %p, src_len: %d, dest_buf: %p, dest_len: %d, mask_info: %p\n",
+ pr_err("diag: Invalid input in %s, src_buf: %pK, src_len: %d, dest_buf: %pK, dest_len: %d, mask_info: %pK\n",
__func__, src_buf, src_len, dest_buf, dest_len,
mask_info);
return -EINVAL;
-/* Copyright (c) 2014-2015, The Linux Foundation. All rights reserved.
+/* Copyright (c) 2014-2016, The Linux Foundation. All rights reserved.
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License version 2 and
if (ch->tbl[i].buf != buf)
continue;
found = 1;
- pr_err_ratelimited("diag: trying to write the same buffer buf: %p, ctxt: %d len: %d at i: %d back to the table, proc: %d, mode: %d\n",
+ pr_err_ratelimited("diag: trying to write the same buffer buf: %pK, ctxt: %d len: %d at i: %d back to the table, proc: %d, mode: %d\n",
buf, ctx, ch->tbl[i].len,
i, id, driver->logging_mode);
}
list_for_each_safe(start, temp, &usb_info->buf_tbl) {
entry = list_entry(start, struct diag_usb_buf_tbl_t, track);
if (entry->buf == buf) {
- DIAG_LOG(DIAG_DEBUG_MUX, "ref_count-- for %p\n", buf);
+ DIAG_LOG(DIAG_DEBUG_MUX, "ref_count-- for %pK\n", buf);
atomic_dec(&entry->ref_count);
/*
* Remove reference from the table if it is the
list_for_each_safe(start, temp, &usb_info->buf_tbl) {
entry = list_entry(start, struct diag_usb_buf_tbl_t, track);
if (entry->buf == buf) {
- DIAG_LOG(DIAG_DEBUG_MUX, "ref_count-- for %p\n", buf);
+ DIAG_LOG(DIAG_DEBUG_MUX, "ref_count-- for %pK\n", buf);
atomic_dec(&entry->ref_count);
return entry;
}
ch->write_cnt++;
entry = diag_usb_buf_tbl_get(ch, req->context);
if (!entry) {
- pr_err_ratelimited("diag: In %s, unable to find entry %p in the table\n",
+ pr_err_ratelimited("diag: In %s, unable to find entry %pK in the table\n",
__func__, req->context);
return;
}
struct diag_request *req = NULL;
if (!usb_info || !buf || len <= 0) {
- pr_err_ratelimited("diag: In %s, usb_info: %p buf: %p, len: %d\n",
+ pr_err_ratelimited("diag: In %s, usb_info: %pK buf: %pK, len: %d\n",
__func__, usb_info, buf, len);
return -EINVAL;
}
spin_lock_irqsave(&usb_info->write_lock, flags);
if (diag_usb_buf_tbl_add(usb_info, buf, len, ctxt)) {
- DIAG_LOG(DIAG_DEBUG_MUX, "ERR! unable to add buf %p to table\n",
+ DIAG_LOG(DIAG_DEBUG_MUX,
+ "ERR! unable to add buf %pK to table\n",
buf);
diagmem_free(driver, req, usb_info->mempool);
spin_unlock_irqrestore(&usb_info->write_lock, flags);
int bridge_index = proc - 1;
if (!buf || len < 0) {
- pr_err("diag: Invalid input in %s, buf: %p, len: %d\n",
+ pr_err("diag: Invalid input in %s, buf: %pK, len: %d\n",
__func__, buf, len);
return -EINVAL;
}
const uint32_t max_encoded_size = ((2 * len) + 3);
if (!buf || len <= 0) {
- pr_err("diag: In %s, invalid buf: %p len: %d\n",
+ pr_err("diag: In %s, invalid buf: %pK len: %d\n",
__func__, buf, len);
return -EIO;
}
const uint32_t max_pkt_size = sizeof(header) + len + 1;
if (!buf || len <= 0) {
- pr_err("diag: In %s, invalid buf: %p len: %d\n",
+ pr_err("diag: In %s, invalid buf: %pK len: %d\n",
__func__, buf, len);
return -EIO;
}
unsigned char *user_space_data = NULL;
if (!buf || len <= 0 || len > diag_mempools[mempool].itemsize) {
- pr_err_ratelimited("diag: In %s, invalid buf %p len: %d\n",
+ pr_err_ratelimited("diag: In %s, invalid buf %pK len: %d\n",
__func__, buf, len);
return -EBADMSG;
}
unsigned char *user_space_data = NULL;
if (!buf || len <= 0 || len > diag_mempools[mempool].itemsize) {
- pr_err_ratelimited("diag: In %s, invalid buf %p len: %d\n",
+ pr_err_ratelimited("diag: In %s, invalid buf %pK len: %d\n",
__func__, buf, len);
return -EBADMSG;
}
struct diag_md_session_t *info = NULL;
if (!buf || len <= 0 || len > CALLBACK_BUF_SIZE) {
- pr_err_ratelimited("diag: In %s, invalid buf %p len: %d\n",
+ pr_err_ratelimited("diag: In %s, invalid buf %pK len: %d\n",
__func__, buf, len);
return -EBADMSG;
}
uint8_t hdlc_disabled;
if (!buf || len <= 0 || len > USER_SPACE_DATA) {
- pr_err_ratelimited("diag: In %s, invalid buf %p len: %d\n",
+ pr_err_ratelimited("diag: In %s, invalid buf %pK len: %d\n",
__func__, buf, len);
return -EBADMSG;
}
uint8_t hdlc_disabled;
if (!buf || len <= 0 || len > DIAG_MAX_RSP_SIZE) {
- pr_err_ratelimited("diag: In %s, invalid buf %p len: %d\n",
+ pr_err_ratelimited("diag: In %s, invalid buf %pK len: %d\n",
__func__, buf, len);
return -EBADMSG;
}
-/* Copyright (c) 2008-2015, The Linux Foundation. All rights reserved.
+/* Copyright (c) 2008-2016, The Linux Foundation. All rights reserved.
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License version 2 and
uint32_t max_len = 0;
if (!buf || len == 0) {
- pr_err("diag: In %s, Invalid ptr %p and length %d\n",
+ pr_err("diag: In %s, Invalid ptr %pK and length %d\n",
__func__, buf, len);
return;
}
int i;
if (!buf || !dest_buf) {
- pr_err("diag: Invalid pointers buf: %p, dest_buf %p in %s\n",
+ pr_err("diag: Invalid pointers buf: %pK, dest_buf %pK in %s\n",
buf, dest_buf, __func__);
return -EIO;
}
struct diag_cmd_time_sync_query_rsp_t rsp;
if (!src_buf || !dest_buf || src_len <= 0 || dest_len <= 0) {
- pr_err("diag: Invalid input in %s, src_buf: %p, src_len: %d, dest_buf: %p, dest_len: %d",
+ pr_err("diag: Invalid input in %s, src_buf: %pK, src_len: %d, dest_buf: %pK, dest_len: %d",
__func__, src_buf, src_len, dest_buf, dest_len);
return -EINVAL;
}
int err = 0, write_len = 0;
if (!src_buf || !dest_buf || src_len <= 0 || dest_len <= 0) {
- pr_err("diag: Invalid input in %s, src_buf: %p, src_len: %d, dest_buf: %p, dest_len: %d",
+ pr_err("diag: Invalid input in %s, src_buf: %pK, src_len: %d, dest_buf: %pK, dest_len: %d",
__func__, src_buf, src_len, dest_buf, dest_len);
return -EINVAL;
}
return 0;
if (!src_buf || !dest_buf || src_len <= 0 || dest_len <= 0) {
- pr_err("diag: Invalid input in %s, src_buf: %p, src_len: %d, dest_buf: %p, dest_len: %d",
+ pr_err("diag: Invalid input in %s, src_buf: %pK, src_len: %d, dest_buf: %pK, dest_len: %d",
__func__, src_buf, src_len, dest_buf, dest_len);
return -EINVAL;
}
-/* Copyright (c) 2012-2015, The Linux Foundation. All rights reserved.
+/* Copyright (c) 2012-2016, The Linux Foundation. All rights reserved.
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License version 2 and
char wq_name[DIAG_BRIDGE_NAME_SZ + 10];
if (!ops) {
- pr_err("diag: Invalid pointers ops: %p ctxt: %d\n", ops, ctxt);
+ pr_err("diag: Invalid pointers ops: %pK ctxt: %d\n", ops, ctxt);
return -EINVAL;
}
-/* Copyright (c) 2012-2014, The Linux Foundation. All rights reserved.
+/* Copyright (c) 2012-2014, 2016 The Linux Foundation. All rights reserved.
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License version 2 and
return -EINVAL;
}
if (!buf || len <= 0) {
- pr_err_ratelimited("diag: In %s, ch %d, invalid buf %p len %d\n",
+ pr_err_ratelimited("diag: In %s, ch %d, invalid buf %pK len %d\n",
__func__, id, buf, len);
return -EINVAL;
}
-/* Copyright (c) 2014-2015, The Linux Foundation. All rights reserved.
+/* Copyright (c) 2014-2016, The Linux Foundation. All rights reserved.
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License version 2 and
item = kzalloc(sizeof(struct diag_mhi_buf_tbl_t), GFP_KERNEL);
if (!item) {
- pr_err_ratelimited("diag: In %s, unable to allocate new item for buf tbl, ch: %p, type: %d, buf: %p, len: %d\n",
- __func__, ch, ch->type, buf, len);
return -ENOMEM;
}
kmemleak_not_leak(item);
spin_unlock_irqrestore(&ch->lock, flags);
if (!found) {
- pr_err_ratelimited("diag: In %s, unable to find buffer, ch: %p, type: %d, buf: %p\n",
+ pr_err_ratelimited("diag: In %s, unable to find buffer, ch: %pK, type: %d, buf: %pK\n",
__func__, ch, ch->type, buf);
}
}
if (!buf)
break;
DIAG_LOG(DIAG_DEBUG_BRIDGE,
- "read from mhi port %d buf %p\n",
+ "read from mhi port %d buf %pK\n",
mhi_info->id, buf);
/*
* The read buffers can come after the MHI channels are closed.
goto fail;
DIAG_LOG(DIAG_DEBUG_BRIDGE,
- "queueing a read buf %p, ch: %s\n",
+ "queueing a read buf %pK, ch: %s\n",
buf, mhi_info->name);
spin_lock_irqsave(&read_ch->lock, flags);
err = mhi_queue_xfer(read_ch->hdl, buf, DIAG_MDM_BUF_SIZE,
}
if (!buf || len <= 0) {
- pr_err("diag: In %s, ch %d, invalid buf %p len %d\n",
+ pr_err("diag: In %s, ch %d, invalid buf %pK len %d\n",
__func__, id, buf, len);
return -EINVAL;
}
err = mhi_queue_xfer(ch->hdl, buf, len, mhi_flags);
spin_unlock_irqrestore(&ch->lock, flags);
if (err) {
- pr_err_ratelimited("diag: In %s, cannot write to MHI channel %p, len %d, err: %d\n",
+ pr_err_ratelimited("diag: In %s, cannot write to MHI channel %pK, len %d, err: %d\n",
__func__, diag_mhi[id].name, len, err);
mhi_buf_tbl_remove(&diag_mhi[id], TYPE_MHI_WRITE_CH, buf, len);
goto fail;
-/* Copyright (c) 2015, The Linux Foundation. All rights reserved.
+/* Copyright (c) 2015-2016, The Linux Foundation. All rights reserved.
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License version 2 and
temp_buf = fwd_info->buf_2;
write_buf = fwd_info->buf_2->data;
} else {
- pr_err("diag: In %s, no match for buffer %p, peripheral %d, type: %d\n",
+ pr_err("diag: In %s, no match for buffer %pK, peripheral %d, type: %d\n",
__func__, buf, fwd_info->peripheral,
fwd_info->type);
goto end;
fwd_info->buf_2->data_raw == buf) {
temp_buf = fwd_info->buf_2;
} else {
- pr_err("diag: In %s, no match for non encode buffer %p, peripheral %d, type: %d\n",
+ pr_err("diag: In %s, no match for non encode buffer %pK, peripheral %d, type: %d\n",
__func__, buf, fwd_info->peripheral,
fwd_info->type);
goto end;
fwd_info->buf_2->data_raw == buf) {
temp_buf = fwd_info->buf_2;
} else {
- pr_err("diag: In %s, no match for non encode buffer %p, peripheral %d, type: %d\n",
+ pr_err("diag: In %s, no match for non encode buffer %pK, peripheral %d, type: %d\n",
__func__, buf, fwd_info->peripheral,
fwd_info->type);
goto end;
if (!(fwd_info->p_ops && fwd_info->p_ops->read && fwd_info->ctxt))
goto fail_return;
- DIAG_LOG(DIAG_DEBUG_PERIPHERALS, "issued a read p: %d t: %d buf: %p\n",
+ DIAG_LOG(DIAG_DEBUG_PERIPHERALS, "issued a read p: %d t: %d buf: %pK\n",
fwd_info->peripheral, fwd_info->type, read_buf);
err = fwd_info->p_ops->read(fwd_info->ctxt, read_buf, read_len);
if (err)
smd_info = (struct diag_smd_info *)ctxt;
prev = smd_info->fwd_ctxt;
smd_info->fwd_ctxt = fwd_ctxt;
- DIAG_LOG(DIAG_DEBUG_PERIPHERALS, "%s prev: %p fwd_ctxt: %p\n",
+ DIAG_LOG(DIAG_DEBUG_PERIPHERALS, "%s prev: %pK fwd_ctxt: %pK\n",
smd_info->name, prev, smd_info->fwd_ctxt);
}
atomic_set(&smd_info->opened, 0);
atomic_set(&smd_info->diag_state, 0);
- DIAG_LOG(DIAG_DEBUG_PERIPHERALS, "%s initialized fwd_ctxt: %p\n",
+ DIAG_LOG(DIAG_DEBUG_PERIPHERALS, "%s initialized fwd_ctxt: %pK\n",
smd_info->name, smd_info->fwd_ctxt);
}
uint8_t avail = 0;
if (!smd_info || !buf || len <= 0) {
- pr_err_ratelimited("diag: In %s, invalid params, smd_info: %p, buf: %p, len: %d\n",
+ pr_err_ratelimited("diag: In %s, invalid params, smd_info: %pK, buf: %pK, len: %d\n",
__func__, smd_info, buf, len);
return -EINVAL;
}
smd_info = (struct diag_smd_info *)ctxt;
if (!smd_info || !buf || len <= 0) {
- pr_err_ratelimited("diag: In %s, invalid params, smd_info: %p, buf: %p, len: %d\n",
+ pr_err_ratelimited("diag: In %s, invalid params, smd_info: %pK, buf: %pK, len: %d\n",
__func__, smd_info, buf, len);
return -EINVAL;
}
if (!smd_info->hdl || !atomic_read(&smd_info->opened)) {
DIAG_LOG(DIAG_DEBUG_PERIPHERALS,
- "%s stopping read, hdl: %p, opened: %d\n",
+ "%s stopping read, hdl: %pK, opened: %d\n",
smd_info->name, smd_info->hdl,
atomic_read(&smd_info->opened));
goto fail_return;
-/* Copyright (c) 2015, The Linux Foundation. All rights reserved.
+/* Copyright (c) 2015-2016, The Linux Foundation. All rights reserved.
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License version 2 and
static void cntl_socket_data_ready(struct sock *sk_ptr)
{
if (!sk_ptr || !cntl_socket) {
- pr_err_ratelimited("diag: In %s, invalid ptrs. sk_ptr: %p cntl_socket: %p\n",
+ pr_err_ratelimited("diag: In %s, invalid ptrs. sk_ptr: %pK cntl_socket: %pK\n",
__func__, sk_ptr, cntl_socket);
return;
}