mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-11 15:11:48 -04:00
Merge "msm: cvp: Re-classification of traces for CVP_DBG"
This commit is contained in:
commit
172d9b116d
15 changed files with 255 additions and 230 deletions
|
|
@ -37,7 +37,7 @@ static int cvp_open(struct inode *inode, struct file *filp)
|
|||
struct msm_cvp_core, cdev);
|
||||
struct msm_cvp_inst *inst;
|
||||
|
||||
dprintk(CVP_DBG, "%s: Enter\n", __func__);
|
||||
dprintk(CVP_SESS, "%s: Enter\n", __func__);
|
||||
|
||||
inst = msm_cvp_open(core->id, MSM_CVP_USER);
|
||||
if (!inst) {
|
||||
|
|
@ -209,7 +209,7 @@ static ssize_t thermal_level_store(struct device *dev,
|
|||
"Invalid thermal level value: %s\n", buf);
|
||||
return -EINVAL;
|
||||
}
|
||||
dprintk(CVP_DBG, "Thermal level old %d new %d\n",
|
||||
dprintk(CVP_PWR, "Thermal level old %d new %d\n",
|
||||
cvp_driver->thermal_level, val);
|
||||
|
||||
if (val == cvp_driver->thermal_level)
|
||||
|
|
@ -375,7 +375,7 @@ static int msm_probe_cvp_device(struct platform_device *pdev)
|
|||
if (rc != -EPROBE_DEFER)
|
||||
dprintk(CVP_ERR, "Failed to create HFI device\n");
|
||||
else
|
||||
dprintk(CVP_DBG, "msm_cvp: request probe defer\n");
|
||||
dprintk(CVP_CORE, "msm_cvp: request probe defer\n");
|
||||
goto err_hfi_initialize;
|
||||
}
|
||||
|
||||
|
|
@ -388,7 +388,7 @@ static int msm_probe_cvp_device(struct platform_device *pdev)
|
|||
|
||||
cvp_driver->sku_version = core->resources.sku_version;
|
||||
|
||||
dprintk(CVP_DBG, "populating sub devices\n");
|
||||
dprintk(CVP_CORE, "populating sub devices\n");
|
||||
/*
|
||||
* Trigger probe for each sub-device i.e. qcom,msm-cvp,context-bank.
|
||||
* When msm_cvp_probe is called for each sub-device, parse the
|
||||
|
|
|
|||
|
|
@ -441,14 +441,14 @@ static int __dsp_suspend(struct iris_hfi_device *device, bool force, u32 flags)
|
|||
|
||||
/* don't suspend if cvp session is not paused */
|
||||
if (!(temp->flags & SESSION_PAUSE)) {
|
||||
dprintk(CVP_DBG,
|
||||
dprintk(CVP_DSP,
|
||||
"%s: cvp session %x not paused\n",
|
||||
__func__, hash32_ptr(temp));
|
||||
return -EBUSY;
|
||||
}
|
||||
}
|
||||
|
||||
dprintk(CVP_DBG, "%s: suspend dsp\n", __func__);
|
||||
dprintk(CVP_DSP, "%s: suspend dsp\n", __func__);
|
||||
rc = cvp_dsp_suspend(flags);
|
||||
if (rc) {
|
||||
dprintk(CVP_ERR, "%s: dsp suspend failed with error %d\n",
|
||||
|
|
@ -456,7 +456,7 @@ static int __dsp_suspend(struct iris_hfi_device *device, bool force, u32 flags)
|
|||
return -EINVAL;
|
||||
}
|
||||
|
||||
dprintk(CVP_DBG, "%s: dsp suspended\n", __func__);
|
||||
dprintk(CVP_DSP, "%s: dsp suspended\n", __func__);
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
|
@ -467,7 +467,7 @@ static int __dsp_resume(struct iris_hfi_device *device, u32 flags)
|
|||
if (msm_cvp_dsp_disable)
|
||||
return 0;
|
||||
|
||||
dprintk(CVP_DBG, "%s: resume dsp\n", __func__);
|
||||
dprintk(CVP_DSP, "%s: resume dsp\n", __func__);
|
||||
rc = cvp_dsp_resume(flags);
|
||||
if (rc) {
|
||||
dprintk(CVP_ERR,
|
||||
|
|
@ -476,7 +476,7 @@ static int __dsp_resume(struct iris_hfi_device *device, u32 flags)
|
|||
return rc;
|
||||
}
|
||||
|
||||
dprintk(CVP_DBG, "%s: dsp resumed\n", __func__);
|
||||
dprintk(CVP_DSP, "%s: dsp resumed\n", __func__);
|
||||
return rc;
|
||||
}
|
||||
|
||||
|
|
@ -487,7 +487,7 @@ static int __dsp_shutdown(struct iris_hfi_device *device, u32 flags)
|
|||
if (msm_cvp_dsp_disable)
|
||||
return 0;
|
||||
|
||||
dprintk(CVP_DBG, "%s: shutdown dsp\n", __func__);
|
||||
dprintk(CVP_DSP, "%s: shutdown dsp\n", __func__);
|
||||
rc = cvp_dsp_shutdown(flags);
|
||||
if (rc) {
|
||||
dprintk(CVP_ERR,
|
||||
|
|
@ -496,7 +496,7 @@ static int __dsp_shutdown(struct iris_hfi_device *device, u32 flags)
|
|||
WARN_ON(1);
|
||||
}
|
||||
|
||||
dprintk(CVP_DBG, "%s: dsp shutdown successful\n", __func__);
|
||||
dprintk(CVP_DSP, "%s: dsp shutdown successful\n", __func__);
|
||||
return rc;
|
||||
}
|
||||
|
||||
|
|
@ -519,7 +519,7 @@ static int __acquire_regulator(struct regulator_info *rinfo,
|
|||
rinfo->name);
|
||||
} else {
|
||||
|
||||
dprintk(CVP_DBG,
|
||||
dprintk(CVP_PWR,
|
||||
"Acquire regulator control from HW: %s\n",
|
||||
rinfo->name);
|
||||
|
||||
|
|
@ -547,7 +547,7 @@ static int __hand_off_regulator(struct regulator_info *rinfo)
|
|||
"Failed to hand off regulator control: %s\n",
|
||||
rinfo->name);
|
||||
} else {
|
||||
dprintk(CVP_DBG,
|
||||
dprintk(CVP_PWR,
|
||||
"Hand off regulator control to HW: %s\n",
|
||||
rinfo->name);
|
||||
}
|
||||
|
|
@ -727,7 +727,7 @@ static int __read_queue(struct cvp_iface_q_info *qinfo, u8 *packet,
|
|||
queue->qhdr_rx_req = 0;
|
||||
} else {
|
||||
spin_unlock(&qinfo->hfi_lock);
|
||||
dprintk(CVP_DBG,
|
||||
dprintk(CVP_HFI,
|
||||
"%s queue is empty, rx_req = %u, tx_req = %u, read_idx = %u\n",
|
||||
receive_request ? "message" : "debug",
|
||||
queue->qhdr_rx_req, queue->qhdr_tx_req,
|
||||
|
|
@ -820,7 +820,7 @@ static int __smem_alloc(struct iris_hfi_device *dev, struct cvp_mem_addr *mem,
|
|||
goto fail_smem_alloc;
|
||||
}
|
||||
|
||||
dprintk(CVP_DBG, "%s: ptr = %pK, size = %d\n", __func__,
|
||||
dprintk(CVP_MEM, "%s: ptr = %pK, size = %d\n", __func__,
|
||||
alloc->kvaddr, size);
|
||||
|
||||
mem->mem_size = alloc->size;
|
||||
|
|
@ -863,7 +863,7 @@ static void __write_register(struct iris_hfi_device *device,
|
|||
}
|
||||
|
||||
base_addr = device->cvp_hal_data->register_base;
|
||||
dprintk(CVP_DBG, "Base addr: %pK, written to: %#x, Value: %#x...\n",
|
||||
dprintk(CVP_REG, "Base addr: %pK, written to: %#x, Value: %#x...\n",
|
||||
base_addr, hwiosymaddr, value);
|
||||
base_addr += hwiosymaddr;
|
||||
writel_relaxed(value, base_addr);
|
||||
|
|
@ -901,7 +901,7 @@ static int __read_register(struct iris_hfi_device *device, u32 reg)
|
|||
* register.
|
||||
*/
|
||||
rmb();
|
||||
dprintk(CVP_DBG, "Base addr: %pK, read from: %#x, value: %#x...\n",
|
||||
dprintk(CVP_REG, "Base addr: %pK, read from: %#x, value: %#x...\n",
|
||||
base_addr, reg, rc);
|
||||
|
||||
return rc;
|
||||
|
|
@ -922,7 +922,7 @@ static void __set_registers(struct iris_hfi_device *device)
|
|||
for (i = 0; i < reg_set->count; i++) {
|
||||
__write_register(device, reg_set->reg_tbl[i].reg,
|
||||
reg_set->reg_tbl[i].value);
|
||||
dprintk(CVP_DBG, "write_reg offset=%x, val=%x\n",
|
||||
dprintk(CVP_REG, "write_reg offset=%x, val=%x\n",
|
||||
reg_set->reg_tbl[i].reg,
|
||||
reg_set->reg_tbl[i].value);
|
||||
}
|
||||
|
|
@ -977,7 +977,7 @@ static int __vote_buses(struct iris_hfi_device *device,
|
|||
struct cvp_bus_vote_data *new_data = NULL;
|
||||
|
||||
if (!num_data) {
|
||||
dprintk(CVP_DBG, "No vote data available\n");
|
||||
dprintk(CVP_PWR, "No vote data available\n");
|
||||
goto no_data_count;
|
||||
} else if (!data) {
|
||||
dprintk(CVP_ERR, "Invalid voting data\n");
|
||||
|
|
@ -1090,7 +1090,7 @@ static int __tzbsp_set_cvp_state(enum tzbsp_subsys_state state)
|
|||
int rc = 0;
|
||||
|
||||
rc = qcom_scm_set_remote_state(state, TZBSP_CVP_PAS_ID);
|
||||
dprintk(CVP_DBG, "Set state %d, resp %d\n", state, rc);
|
||||
dprintk(CVP_CORE, "Set state %d, resp %d\n", state, rc);
|
||||
|
||||
if (rc) {
|
||||
dprintk(CVP_ERR, "Failed qcom_scm_set_remote_state %d\n", rc);
|
||||
|
|
@ -1143,7 +1143,7 @@ static int iris_hfi_resume(void *dev)
|
|||
return -EINVAL;
|
||||
}
|
||||
|
||||
dprintk(CVP_DBG, "Resuming Iris\n");
|
||||
dprintk(CVP_CORE, "Resuming Iris\n");
|
||||
|
||||
mutex_lock(&device->lock);
|
||||
rc = __resume(device);
|
||||
|
|
@ -1165,7 +1165,7 @@ static int iris_hfi_suspend(void *dev)
|
|||
return -ENOTSUPP;
|
||||
}
|
||||
|
||||
dprintk(CVP_DBG, "Suspending Iris\n");
|
||||
dprintk(CVP_CORE, "Suspending Iris\n");
|
||||
mutex_lock(&device->lock);
|
||||
rc = __power_collapse(device, true);
|
||||
if (rc) {
|
||||
|
|
@ -1253,7 +1253,7 @@ static int __set_clocks(struct iris_hfi_device *device, u32 freq)
|
|||
return rc;
|
||||
}
|
||||
|
||||
dprintk(CVP_DBG, "Scaling clock %s to %u\n",
|
||||
dprintk(CVP_PWR, "Scaling clock %s to %u\n",
|
||||
cl->name, freq);
|
||||
}
|
||||
}
|
||||
|
|
@ -1297,7 +1297,7 @@ static int __scale_clocks(struct iris_hfi_device *device)
|
|||
rate = device->clk_freq ? device->clk_freq :
|
||||
allowed_clks_tbl[0].clock_rate;
|
||||
|
||||
dprintk(CVP_DBG, "%s: scale clock rate %d\n", __func__, rate);
|
||||
dprintk(CVP_PWR, "%s: scale clock rate %d\n", __func__, rate);
|
||||
rc = __set_clocks(device, rate);
|
||||
return rc;
|
||||
}
|
||||
|
|
@ -1350,7 +1350,7 @@ static int __iface_cmdq_write_relaxed(struct iris_hfi_device *device,
|
|||
&iris_hfi_pm_work,
|
||||
msecs_to_jiffies(
|
||||
device->res->msm_cvp_pwr_collapse_delay))) {
|
||||
dprintk(CVP_DBG,
|
||||
dprintk(CVP_PWR,
|
||||
"PM work already scheduled\n");
|
||||
}
|
||||
}
|
||||
|
|
@ -1393,7 +1393,7 @@ static int __iface_msgq_read(struct iris_hfi_device *device, void *pkt)
|
|||
__strict_check(device);
|
||||
|
||||
if (!__core_in_valid_state(device)) {
|
||||
dprintk(CVP_DBG, "%s - fw not in init state\n", __func__);
|
||||
dprintk(CVP_WARN, "%s - fw not in init state\n", __func__);
|
||||
rc = -EINVAL;
|
||||
goto read_error_null;
|
||||
}
|
||||
|
|
@ -1526,7 +1526,7 @@ static int __interface_dsp_queues_init(struct iris_hfi_device *dev)
|
|||
dprintk(CVP_ERR, "%s: failed dma mapping\n", __func__);
|
||||
goto fail_dma_map;
|
||||
}
|
||||
dprintk(CVP_DBG,
|
||||
dprintk(CVP_DSP,
|
||||
"%s: kvaddr %pK dma_handle %#llx iova %#llx size %zd\n",
|
||||
__func__, kvaddr, dma_handle, iova, q_size);
|
||||
|
||||
|
|
@ -1975,7 +1975,7 @@ static int iris_hfi_core_init(void *device)
|
|||
|
||||
dev = device;
|
||||
|
||||
dprintk(CVP_DBG, "Core initializing\n");
|
||||
dprintk(CVP_CORE, "Core initializing\n");
|
||||
|
||||
mutex_lock(&dev->lock);
|
||||
|
||||
|
|
@ -1999,7 +1999,7 @@ static int iris_hfi_core_init(void *device)
|
|||
__set_state(dev, IRIS_STATE_INIT);
|
||||
dev->reg_dumped = false;
|
||||
|
||||
dprintk(CVP_DBG, "Dev_Virt: %pa, Reg_Virt: %pK\n",
|
||||
dprintk(CVP_CORE, "Dev_Virt: %pa, Reg_Virt: %pK\n",
|
||||
&dev->cvp_hal_data->firmware_base,
|
||||
dev->cvp_hal_data->register_base);
|
||||
|
||||
|
|
@ -2051,7 +2051,7 @@ static int iris_hfi_core_init(void *device)
|
|||
|
||||
cvp_dsp_send_hfi_queue();
|
||||
|
||||
dprintk(CVP_DBG, "Core inited successfully\n");
|
||||
dprintk(CVP_CORE, "Core inited successfully\n");
|
||||
|
||||
return 0;
|
||||
err_core_init:
|
||||
|
|
@ -2094,7 +2094,7 @@ static int iris_hfi_core_release(void *dev)
|
|||
session->device = NULL;
|
||||
}
|
||||
|
||||
dprintk(CVP_DBG, "Core released successfully\n");
|
||||
dprintk(CVP_CORE, "Core released successfully\n");
|
||||
mutex_unlock(&device->lock);
|
||||
|
||||
return rc;
|
||||
|
|
@ -2115,7 +2115,7 @@ static void __core_clear_interrupt(struct iris_hfi_device *device)
|
|||
if (intr_status & mask) {
|
||||
device->intr_status |= intr_status;
|
||||
device->reg_count++;
|
||||
dprintk(CVP_DBG,
|
||||
dprintk(CVP_CORE,
|
||||
"INTERRUPT for device: %pK: times: %d status: %d\n",
|
||||
device, device->reg_count, intr_status);
|
||||
} else {
|
||||
|
|
@ -2172,7 +2172,7 @@ static void __session_clean(struct cvp_hal_session *session)
|
|||
return;
|
||||
}
|
||||
device = session->device;
|
||||
dprintk(CVP_DBG, "deleted the session: %pK\n", session);
|
||||
dprintk(CVP_SESS, "deleted the session: %pK\n", session);
|
||||
/*
|
||||
* session might have been removed from the device list in
|
||||
* core_release, so check and remove if it is in the list
|
||||
|
|
@ -2237,7 +2237,7 @@ static int iris_hfi_session_init(void *device, void *session_id,
|
|||
|
||||
s->session_id = session_id;
|
||||
s->device = dev;
|
||||
dprintk(CVP_DBG,
|
||||
dprintk(CVP_SESS,
|
||||
"%s: inst %pK, session %pK\n", __func__, session_id, s);
|
||||
|
||||
list_add_tail(&s->list, &dev->sess_head);
|
||||
|
|
@ -2560,7 +2560,7 @@ static void iris_hfi_pm_handler(struct work_struct *work)
|
|||
return;
|
||||
}
|
||||
|
||||
dprintk(CVP_PROF,
|
||||
dprintk(CVP_PWR,
|
||||
"Entering %s\n", __func__);
|
||||
/*
|
||||
* It is ok to check this variable outside the lock since
|
||||
|
|
@ -2582,12 +2582,12 @@ static void iris_hfi_pm_handler(struct work_struct *work)
|
|||
device->skip_pc_count = 0;
|
||||
/* Cancel pending delayed works if any */
|
||||
cancel_delayed_work(&iris_hfi_pm_work);
|
||||
dprintk(CVP_PROF, "%s: power collapse successful!\n",
|
||||
dprintk(CVP_PWR, "%s: power collapse successful!\n",
|
||||
__func__);
|
||||
break;
|
||||
case -EBUSY:
|
||||
device->skip_pc_count = 0;
|
||||
dprintk(CVP_DBG, "%s: retry PC as cvp is busy\n", __func__);
|
||||
dprintk(CVP_PWR, "%s: retry PC as cvp is busy\n", __func__);
|
||||
queue_delayed_work(device->iris_pm_workq,
|
||||
&iris_hfi_pm_work, msecs_to_jiffies(
|
||||
device->res->msm_cvp_pwr_collapse_delay));
|
||||
|
|
@ -2619,7 +2619,7 @@ static int __power_collapse(struct iris_hfi_device *device, bool force)
|
|||
return -EINVAL;
|
||||
}
|
||||
if (!device->power_enabled) {
|
||||
dprintk(CVP_DBG, "%s: Power already disabled\n",
|
||||
dprintk(CVP_PWR, "%s: Power already disabled\n",
|
||||
__func__);
|
||||
goto exit;
|
||||
}
|
||||
|
|
@ -2839,10 +2839,10 @@ static void process_system_msg(struct msm_cvp_cb_info *info,
|
|||
__process_sys_error(device);
|
||||
break;
|
||||
case HAL_SYS_RELEASE_RESOURCE_DONE:
|
||||
dprintk(CVP_DBG, "Received SYS_RELEASE_RESOURCE\n");
|
||||
dprintk(CVP_CORE, "Received SYS_RELEASE_RESOURCE\n");
|
||||
break;
|
||||
case HAL_SYS_INIT_DONE:
|
||||
dprintk(CVP_DBG, "Received SYS_INIT_DONE\n");
|
||||
dprintk(CVP_CORE, "Received SYS_INIT_DONE\n");
|
||||
sys_init_done.capabilities =
|
||||
device->sys_init_capabilities;
|
||||
cvp_hfi_process_sys_init_done_prop_read(
|
||||
|
|
@ -2914,7 +2914,7 @@ static void print_msg_hdr(void *hdr)
|
|||
{
|
||||
struct cvp_hfi_msg_session_hdr *new_hdr =
|
||||
(struct cvp_hfi_msg_session_hdr *)hdr;
|
||||
dprintk(CVP_DBG, "HFI MSG received: %x %x %x %x %x %x %x\n",
|
||||
dprintk(CVP_HFI, "HFI MSG received: %x %x %x %x %x %x %x\n",
|
||||
new_hdr->size, new_hdr->packet_type,
|
||||
new_hdr->session_id,
|
||||
new_hdr->client_data.transaction_id,
|
||||
|
|
@ -3067,7 +3067,7 @@ static void iris_hfi_core_work_handler(struct work_struct *work)
|
|||
|
||||
|
||||
if (!__core_in_valid_state(device)) {
|
||||
dprintk(CVP_DBG, "%s - Core not in init state\n", __func__);
|
||||
dprintk(CVP_WARN, "%s - Core not in init state\n", __func__);
|
||||
goto err_no_work;
|
||||
}
|
||||
|
||||
|
|
@ -3084,7 +3084,7 @@ static void iris_hfi_core_work_handler(struct work_struct *work)
|
|||
|
||||
__core_clear_interrupt(device);
|
||||
num_responses = __response_handler(device);
|
||||
dprintk(CVP_DBG, "%s:: cvp_driver_debug num_responses = %d ",
|
||||
dprintk(CVP_HFI, "%s:: cvp_driver_debug num_responses = %d ",
|
||||
__func__, num_responses);
|
||||
|
||||
err_no_work:
|
||||
|
|
@ -3108,7 +3108,7 @@ err_no_work:
|
|||
_INVALID_STATE_, (i + 1), num_responses);
|
||||
break;
|
||||
}
|
||||
dprintk(CVP_DBG, "Processing response %d of %d, type %d\n",
|
||||
dprintk(CVP_HFI, "Processing response %d of %d, type %d\n",
|
||||
(i + 1), num_responses, r->response_type);
|
||||
device->callback(r->response_type, rsp);
|
||||
}
|
||||
|
|
@ -3215,7 +3215,7 @@ static inline int __init_clocks(struct iris_hfi_device *device)
|
|||
|
||||
iris_hfi_for_each_clock(device, cl) {
|
||||
|
||||
dprintk(CVP_DBG, "%s: scalable? %d, count %d\n",
|
||||
dprintk(CVP_PWR, "%s: scalable? %d, count %d\n",
|
||||
cl->name, cl->has_scaling, cl->count);
|
||||
}
|
||||
|
||||
|
|
@ -3253,7 +3253,7 @@ static int __handle_reset_clk(struct msm_cvp_platform_resources *res,
|
|||
|
||||
rst_info = rst_set->reset_tbl[reset_index];
|
||||
rst = rst_info.rst;
|
||||
dprintk(CVP_DBG, "reset_clk: name %s reset_state %d rst %pK ps=%d\n",
|
||||
dprintk(CVP_PWR, "reset_clk: name %s reset_state %d rst %pK ps=%d\n",
|
||||
rst_set->reset_tbl[reset_index].name, state, rst, pwr_state);
|
||||
|
||||
switch (state) {
|
||||
|
|
@ -3313,7 +3313,7 @@ static inline void __disable_unprepare_clks(struct iris_hfi_device *device)
|
|||
}
|
||||
|
||||
iris_hfi_for_each_clock_reverse(device, cl) {
|
||||
dprintk(CVP_DBG, "Clock: %s disable and unprepare\n",
|
||||
dprintk(CVP_PWR, "Clock: %s disable and unprepare\n",
|
||||
cl->name);
|
||||
clk_disable_unprepare(cl->clk);
|
||||
}
|
||||
|
|
@ -3387,7 +3387,7 @@ static inline int __prepare_enable_clks(struct iris_hfi_device *device)
|
|||
}
|
||||
|
||||
c++;
|
||||
dprintk(CVP_DBG, "Clock: %s prepared and enabled\n", cl->name);
|
||||
dprintk(CVP_PWR, "Clock: %s prepared and enabled\n", cl->name);
|
||||
}
|
||||
|
||||
return rc;
|
||||
|
|
@ -3504,7 +3504,7 @@ static void __deinit_subcaches(struct iris_hfi_device *device)
|
|||
|
||||
iris_hfi_for_each_subcache_reverse(device, sinfo) {
|
||||
if (sinfo->subcache) {
|
||||
dprintk(CVP_DBG, "deinit_subcaches: %s\n",
|
||||
dprintk(CVP_CORE, "deinit_subcaches: %s\n",
|
||||
sinfo->name);
|
||||
llcc_slice_putd(sinfo->subcache);
|
||||
sinfo->subcache = NULL;
|
||||
|
|
@ -3547,7 +3547,7 @@ static int __init_subcaches(struct iris_hfi_device *device)
|
|||
sinfo->subcache = NULL;
|
||||
goto err_subcache_get;
|
||||
}
|
||||
dprintk(CVP_DBG, "init_subcaches: %s\n",
|
||||
dprintk(CVP_CORE, "init_subcaches: %s\n",
|
||||
sinfo->name);
|
||||
}
|
||||
|
||||
|
|
@ -3629,7 +3629,7 @@ static int __disable_regulator(struct regulator_info *rinfo,
|
|||
{
|
||||
int rc = 0;
|
||||
|
||||
dprintk(CVP_DBG, "Disabling regulator %s\n", rinfo->name);
|
||||
dprintk(CVP_PWR, "Disabling regulator %s\n", rinfo->name);
|
||||
|
||||
/*
|
||||
* This call is needed. Driver needs to acquire the control back
|
||||
|
|
@ -3672,7 +3672,7 @@ static int __enable_hw_power_collapse(struct iris_hfi_device *device)
|
|||
int rc = 0;
|
||||
|
||||
if (!msm_cvp_fw_low_power_mode) {
|
||||
dprintk(CVP_DBG, "Not enabling hardware power collapse\n");
|
||||
dprintk(CVP_PWR, "Not enabling hardware power collapse\n");
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
|
@ -3689,7 +3689,7 @@ static int __enable_regulators(struct iris_hfi_device *device)
|
|||
int rc = 0, c = 0;
|
||||
struct regulator_info *rinfo;
|
||||
|
||||
dprintk(CVP_DBG, "Enabling regulators\n");
|
||||
dprintk(CVP_PWR, "Enabling regulators\n");
|
||||
|
||||
iris_hfi_for_each_regulator(device, rinfo) {
|
||||
rc = regulator_enable(rinfo->regulator);
|
||||
|
|
@ -3699,7 +3699,7 @@ static int __enable_regulators(struct iris_hfi_device *device)
|
|||
goto err_reg_enable_failed;
|
||||
}
|
||||
|
||||
dprintk(CVP_DBG, "Enabled regulator %s\n", rinfo->name);
|
||||
dprintk(CVP_PWR, "Enabled regulator %s\n", rinfo->name);
|
||||
c++;
|
||||
}
|
||||
|
||||
|
|
@ -3716,7 +3716,7 @@ static int __disable_regulators(struct iris_hfi_device *device)
|
|||
{
|
||||
struct regulator_info *rinfo;
|
||||
|
||||
dprintk(CVP_DBG, "Disabling regulators\n");
|
||||
dprintk(CVP_PWR, "Disabling regulators\n");
|
||||
|
||||
iris_hfi_for_each_regulator_reverse(device, rinfo) {
|
||||
__disable_regulator(rinfo, device);
|
||||
|
|
@ -3747,11 +3747,11 @@ static int __enable_subcaches(struct iris_hfi_device *device)
|
|||
goto err_activate_fail;
|
||||
}
|
||||
sinfo->isactive = true;
|
||||
dprintk(CVP_DBG, "Activated subcache %s\n", sinfo->name);
|
||||
dprintk(CVP_CORE, "Activated subcache %s\n", sinfo->name);
|
||||
c++;
|
||||
}
|
||||
|
||||
dprintk(CVP_DBG, "Activated %d Subcaches to CVP\n", c);
|
||||
dprintk(CVP_CORE, "Activated %d Subcaches to CVP\n", c);
|
||||
|
||||
return 0;
|
||||
|
||||
|
|
@ -3772,7 +3772,7 @@ static int __set_subcaches(struct iris_hfi_device *device)
|
|||
struct cvp_resource_hdr rhdr;
|
||||
|
||||
if (device->res->sys_cache_res_set || msm_cvp_syscache_disable) {
|
||||
dprintk(CVP_DBG, "Subcaches already set or disabled\n");
|
||||
dprintk(CVP_CORE, "Subcaches already set or disabled\n");
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
|
@ -3791,7 +3791,7 @@ static int __set_subcaches(struct iris_hfi_device *device)
|
|||
|
||||
/* Set resource to CVP for activated subcaches */
|
||||
if (c) {
|
||||
dprintk(CVP_DBG, "Setting %d Subcaches\n", c);
|
||||
dprintk(CVP_CORE, "Setting %d Subcaches\n", c);
|
||||
|
||||
rhdr.resource_handle = sc_res_info; /* cookie */
|
||||
rhdr.resource_id = CVP_RESOURCE_SYSCACHE;
|
||||
|
|
@ -3809,7 +3809,7 @@ static int __set_subcaches(struct iris_hfi_device *device)
|
|||
sinfo->isset = true;
|
||||
}
|
||||
|
||||
dprintk(CVP_DBG, "Set Subcaches done to CVP\n");
|
||||
dprintk(CVP_CORE, "Set Subcaches done to CVP\n");
|
||||
device->res->sys_cache_res_set = true;
|
||||
}
|
||||
|
||||
|
|
@ -3851,7 +3851,7 @@ static int __release_subcaches(struct iris_hfi_device *device)
|
|||
}
|
||||
|
||||
if (c > 0) {
|
||||
dprintk(CVP_DBG, "Releasing %d subcaches\n", c);
|
||||
dprintk(CVP_CORE, "Releasing %d subcaches\n", c);
|
||||
rhdr.resource_handle = sc_res_info; /* cookie */
|
||||
rhdr.resource_id = CVP_RESOURCE_SYSCACHE;
|
||||
|
||||
|
|
@ -3877,7 +3877,7 @@ static int __disable_subcaches(struct iris_hfi_device *device)
|
|||
/* De-activate subcaches */
|
||||
iris_hfi_for_each_subcache_reverse(device, sinfo) {
|
||||
if (sinfo->isactive) {
|
||||
dprintk(CVP_DBG, "De-activate subcache %s\n",
|
||||
dprintk(CVP_CORE, "De-activate subcache %s\n",
|
||||
sinfo->name);
|
||||
rc = llcc_slice_deactivate(sinfo->subcache);
|
||||
if (rc) {
|
||||
|
|
@ -3902,7 +3902,7 @@ static void interrupt_init_iris2(struct iris_hfi_device *device)
|
|||
/* Write 0 to unmask CPU and WD interrupts */
|
||||
mask_val &= ~(CVP_FATAL_INTR_BMSK | CVP_WRAPPER_INTR_MASK_A2HCPU_BMSK);
|
||||
__write_register(device, CVP_WRAPPER_INTR_MASK, mask_val);
|
||||
dprintk(CVP_DBG, "Init irq: reg: %x, mask value %x\n",
|
||||
dprintk(CVP_REG, "Init irq: reg: %x, mask value %x\n",
|
||||
CVP_WRAPPER_INTR_MASK, mask_val);
|
||||
}
|
||||
|
||||
|
|
@ -3995,16 +3995,16 @@ static int __iris_power_on(struct iris_hfi_device *device)
|
|||
/*Do not access registers before this point!*/
|
||||
device->power_enabled = true;
|
||||
|
||||
dprintk(CVP_DBG, "Done with scaling\n");
|
||||
dprintk(CVP_PWR, "Done with scaling\n");
|
||||
/*
|
||||
* Re-program all of the registers that get reset as a result of
|
||||
* regulator_disable() and _enable()
|
||||
*/
|
||||
__set_registers(device);
|
||||
|
||||
dprintk(CVP_DBG, "Done with register set\n");
|
||||
dprintk(CVP_CORE, "Done with register set\n");
|
||||
call_iris_op(device, interrupt_init, device);
|
||||
dprintk(CVP_DBG, "Done with interrupt enabling\n");
|
||||
dprintk(CVP_CORE, "Done with interrupt enabling\n");
|
||||
device->intr_status = 0;
|
||||
enable_irq(device->cvp_hal_data->irq);
|
||||
|
||||
|
|
@ -4054,11 +4054,11 @@ static inline int __suspend(struct iris_hfi_device *device)
|
|||
dprintk(CVP_ERR, "Invalid params: %pK\n", device);
|
||||
return -EINVAL;
|
||||
} else if (!device->power_enabled) {
|
||||
dprintk(CVP_DBG, "Power already disabled\n");
|
||||
dprintk(CVP_PWR, "Power already disabled\n");
|
||||
return 0;
|
||||
}
|
||||
|
||||
dprintk(CVP_PROF, "Entering suspend\n");
|
||||
dprintk(CVP_PWR, "Entering suspend\n");
|
||||
|
||||
if (device->res->pm_qos_latency_us &&
|
||||
pm_qos_request_active(&device->qos))
|
||||
|
|
@ -4073,7 +4073,7 @@ static inline int __suspend(struct iris_hfi_device *device)
|
|||
__disable_subcaches(device);
|
||||
|
||||
call_iris_op(device, power_off, device);
|
||||
dprintk(CVP_PROF, "Iris power off\n");
|
||||
dprintk(CVP_PWR, "Iris power off\n");
|
||||
return rc;
|
||||
|
||||
err_tzbsp_suspend:
|
||||
|
|
@ -4107,7 +4107,7 @@ static void power_off_iris2(struct iris_hfi_device *device)
|
|||
usleep_range(50, 100);
|
||||
count++;
|
||||
}
|
||||
dprintk(CVP_DBG,
|
||||
dprintk(CVP_PWR,
|
||||
"Noc: lpi_status %x noc_status %x (count %d)\n",
|
||||
lpi_status, reg_status, count);
|
||||
if (count == max_count) {
|
||||
|
|
@ -4142,7 +4142,7 @@ static void power_off_iris2(struct iris_hfi_device *device)
|
|||
usleep_range(50, 100);
|
||||
count++;
|
||||
}
|
||||
dprintk(CVP_DBG,
|
||||
dprintk(CVP_PWR,
|
||||
"DBLP Release: lpi_status %d(count %d)\n",
|
||||
lpi_status, count);
|
||||
if (count == max_count) {
|
||||
|
|
@ -4179,11 +4179,11 @@ static inline int __resume(struct iris_hfi_device *device)
|
|||
} else if (device->power_enabled) {
|
||||
goto exit;
|
||||
} else if (!__core_in_valid_state(device)) {
|
||||
dprintk(CVP_DBG, "iris_hfi_device in deinit state.");
|
||||
dprintk(CVP_PWR, "iris_hfi_device in deinit state.");
|
||||
return -EINVAL;
|
||||
}
|
||||
|
||||
dprintk(CVP_PROF, "Resuming from power collapse\n");
|
||||
dprintk(CVP_PWR, "Resuming from power collapse\n");
|
||||
rc = __iris_power_on(device);
|
||||
if (rc) {
|
||||
dprintk(CVP_ERR, "Failed to power on cvp\n");
|
||||
|
|
@ -4223,7 +4223,7 @@ static inline int __resume(struct iris_hfi_device *device)
|
|||
|
||||
__dsp_resume(device, flags);
|
||||
|
||||
dprintk(CVP_PROF, "Resumed from power collapse\n");
|
||||
dprintk(CVP_PWR, "Resumed from power collapse\n");
|
||||
exit:
|
||||
/* Don't reset skip_pc_count for SYS_PC_PREP cmd */
|
||||
if (device->last_packet_type != HFI_CMD_SYS_PC_PREP)
|
||||
|
|
@ -4343,7 +4343,7 @@ static int iris_hfi_get_fw_info(void *dev, struct cvp_hal_fw_info *fw_info)
|
|||
fw_info->version[CVP_VERSION_LENGTH - 1] = '\0';
|
||||
|
||||
fail_version_string:
|
||||
dprintk(CVP_DBG, "F/W version retrieved : %s\n", fw_info->version);
|
||||
dprintk(CVP_CORE, "F/W version retrieved : %s\n", fw_info->version);
|
||||
fw_info->base_addr = device->cvp_hal_data->firmware_base;
|
||||
fw_info->register_base = device->res->register_base;
|
||||
fw_info->register_size = device->cvp_hal_data->register_size;
|
||||
|
|
@ -4355,7 +4355,7 @@ fail_version_string:
|
|||
|
||||
static int iris_hfi_get_core_capabilities(void *dev)
|
||||
{
|
||||
dprintk(CVP_DBG, "%s not supported yet!\n", __func__);
|
||||
dprintk(CVP_CORE, "%s not supported yet!\n", __func__);
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -79,7 +79,7 @@ int cvp_create_pkt_cmd_sys_coverage_config(
|
|||
pkt->num_properties = 1;
|
||||
pkt->rg_property_data[0] = HFI_PROPERTY_SYS_CONFIG_COVERAGE;
|
||||
pkt->rg_property_data[1] = mode;
|
||||
dprintk(CVP_DBG, "Firmware coverage mode %d\n",
|
||||
dprintk(CVP_PKT, "Firmware coverage mode %d\n",
|
||||
pkt->rg_property_data[1]);
|
||||
return 0;
|
||||
}
|
||||
|
|
@ -99,7 +99,7 @@ int cvp_create_pkt_cmd_sys_set_idle_indicator(
|
|||
pkt->num_properties = 1;
|
||||
pkt->rg_property_data[0] = HFI_PROPERTY_SYS_IDLE_INDICATOR;
|
||||
pkt->rg_property_data[1] = mode;
|
||||
dprintk(CVP_DBG, "Firmware idle indicator mode %d\n",
|
||||
dprintk(CVP_PKT, "Firmware idle indicator mode %d\n",
|
||||
pkt->rg_property_data[1]);
|
||||
return 0;
|
||||
}
|
||||
|
|
@ -148,7 +148,7 @@ int cvp_create_pkt_cmd_sys_set_resource(
|
|||
|
||||
for (i = 0; i < hfi_sc_info->num_entries; i++) {
|
||||
hfi_sc[i] = res_sc[i];
|
||||
dprintk(CVP_DBG, "entry hfi#%d, sc_id %d, size %d\n",
|
||||
dprintk(CVP_PKT, "entry hfi#%d, sc_id %d, size %d\n",
|
||||
i, hfi_sc[i].sc_id, hfi_sc[i].size);
|
||||
}
|
||||
break;
|
||||
|
|
@ -189,7 +189,7 @@ int cvp_create_pkt_cmd_sys_release_resource(
|
|||
rc = -ENOTSUPP;
|
||||
}
|
||||
|
||||
dprintk(CVP_DBG,
|
||||
dprintk(CVP_PKT,
|
||||
"rel_res: pkt_type 0x%x res_type 0x%x prepared\n",
|
||||
pkt->packet_type, pkt->resource_type);
|
||||
|
||||
|
|
@ -449,7 +449,7 @@ static struct cvp_hfi_packetization_ops hfi_default = {
|
|||
struct cvp_hfi_packetization_ops *cvp_hfi_get_pkt_ops_handle(
|
||||
enum hfi_packetization_type type)
|
||||
{
|
||||
dprintk(CVP_DBG, "%s selected\n",
|
||||
dprintk(CVP_HFI, "%s selected\n",
|
||||
type == HFI_PACKETIZATION_4XX ?
|
||||
"4xx packetization" : "Unknown hfi");
|
||||
|
||||
|
|
|
|||
|
|
@ -121,7 +121,7 @@ static int hfi_process_event_notify(u32 device_id,
|
|||
struct cvp_hfi_msg_event_notify_packet *pkt =
|
||||
(struct cvp_hfi_msg_event_notify_packet *)hdr;
|
||||
|
||||
dprintk(CVP_DBG, "Received: EVENT_NOTIFY\n");
|
||||
dprintk(CVP_HFI, "Received: EVENT_NOTIFY\n");
|
||||
|
||||
if (pkt->size < sizeof(struct cvp_hfi_msg_event_notify_packet)) {
|
||||
dprintk(CVP_ERR, "Invalid Params\n");
|
||||
|
|
@ -156,14 +156,14 @@ static int hfi_process_sys_init_done(u32 device_id,
|
|||
struct msm_cvp_cb_cmd_done cmd_done = {0};
|
||||
enum cvp_status status = CVP_ERR_NONE;
|
||||
|
||||
dprintk(CVP_DBG, "RECEIVED: SYS_INIT_DONE\n");
|
||||
dprintk(CVP_CORE, "RECEIVED: SYS_INIT_DONE\n");
|
||||
if (sizeof(struct cvp_hfi_msg_sys_init_done_packet) > pkt->size) {
|
||||
dprintk(CVP_ERR, "%s: bad_pkt_size: %d\n", __func__,
|
||||
pkt->size);
|
||||
return -E2BIG;
|
||||
}
|
||||
if (!pkt->num_properties) {
|
||||
dprintk(CVP_DBG,
|
||||
dprintk(CVP_CORE,
|
||||
"hal_process_sys_init_done: no_properties\n");
|
||||
goto err_no_prop;
|
||||
}
|
||||
|
|
@ -218,7 +218,7 @@ enum cvp_status cvp_hfi_process_sys_init_done_prop_read(
|
|||
|
||||
data_ptr = (u8 *) &pkt->rg_property_data[0];
|
||||
num_properties = pkt->num_properties;
|
||||
dprintk(CVP_DBG,
|
||||
dprintk(CVP_HFI,
|
||||
"%s: data_start %pK, num_properties %#x\n",
|
||||
__func__, data_ptr, num_properties);
|
||||
|
||||
|
|
@ -234,7 +234,7 @@ static int hfi_process_session_init_done(u32 device_id,
|
|||
struct msm_cvp_cb_cmd_done cmd_done = {0};
|
||||
struct cvp_hal_session_init_done session_init_done = { {0} };
|
||||
|
||||
dprintk(CVP_DBG, "RECEIVED: SESSION_INIT_DONE[%x]\n", pkt->session_id);
|
||||
dprintk(CVP_SESS, "RECEIVED: SESSION_INIT_DONE[%x]\n", pkt->session_id);
|
||||
|
||||
if (sizeof(struct cvp_hfi_msg_sys_session_init_done_packet)
|
||||
> pkt->size) {
|
||||
|
|
@ -261,7 +261,7 @@ static int hfi_process_session_end_done(u32 device_id,
|
|||
(struct cvp_hfi_msg_sys_session_end_done_packet *)hdr;
|
||||
struct msm_cvp_cb_cmd_done cmd_done = {0};
|
||||
|
||||
dprintk(CVP_DBG, "RECEIVED: SESSION_END_DONE[%#x]\n", pkt->session_id);
|
||||
dprintk(CVP_SESS, "RECEIVED: SESSION_END_DONE[%#x]\n", pkt->session_id);
|
||||
|
||||
if (!pkt || pkt->size !=
|
||||
sizeof(struct cvp_hfi_msg_sys_session_end_done_packet)) {
|
||||
|
|
@ -287,7 +287,7 @@ static int hfi_process_session_abort_done(u32 device_id,
|
|||
(struct cvp_hfi_msg_sys_session_abort_done_packet *)hdr;
|
||||
struct msm_cvp_cb_cmd_done cmd_done = {0};
|
||||
|
||||
dprintk(CVP_DBG, "RECEIVED: SESSION_ABORT_DONE[%#x]\n",
|
||||
dprintk(CVP_SESS, "RECEIVED: SESSION_ABORT_DONE[%#x]\n",
|
||||
pkt->session_id);
|
||||
|
||||
if (!pkt || pkt->size !=
|
||||
|
|
@ -320,7 +320,7 @@ static int hfi_process_session_set_buf_done(u32 device_id,
|
|||
pkt ? pkt->size : 0);
|
||||
return -E2BIG;
|
||||
}
|
||||
dprintk(CVP_DBG, "RECEIVED:CVP_SET_BUFFER_DONE[%#x]\n",
|
||||
dprintk(CVP_SESS, "RECEIVED:CVP_SET_BUFFER_DONE[%#x]\n",
|
||||
pkt->session_id);
|
||||
|
||||
cmd_done.device_id = device_id;
|
||||
|
|
@ -341,7 +341,7 @@ static int hfi_process_session_flush_done(u32 device_id,
|
|||
(struct cvp_hfi_msg_sys_session_flush_done_packet *)hdr;
|
||||
struct msm_cvp_cb_cmd_done cmd_done = {0};
|
||||
|
||||
dprintk(CVP_DBG, "RECEIVED: SESSION_FLUSH_DONE[%#x]\n",
|
||||
dprintk(CVP_SESS, "RECEIVED: SESSION_FLUSH_DONE[%#x]\n",
|
||||
pkt->session_id);
|
||||
|
||||
if (!pkt || pkt->size <
|
||||
|
|
@ -374,7 +374,7 @@ static int hfi_process_session_rel_buf_done(u32 device_id,
|
|||
pkt ? pkt->size : 0);
|
||||
return -E2BIG;
|
||||
}
|
||||
dprintk(CVP_DBG, "RECEIVED:CVP_RELEASE_BUFFER_DONE[%#x]\n",
|
||||
dprintk(CVP_SESS, "RECEIVED:CVP_RELEASE_BUFFER_DONE[%#x]\n",
|
||||
pkt->session_id);
|
||||
|
||||
cmd_done.device_id = device_id;
|
||||
|
|
@ -412,7 +412,7 @@ static int hfi_process_session_cvp_operation_config(u32 device_id,
|
|||
cmd_done.status = hfi_map_err_status(error_type);
|
||||
cmd_done.size = 0;
|
||||
|
||||
dprintk(CVP_DBG,
|
||||
dprintk(CVP_HFI,
|
||||
"%s: device_id=%d status=%d, sessionid=%pK config=%x\n",
|
||||
__func__, device_id, cmd_done.status,
|
||||
cmd_done.session_id, pkt->op_conf_id);
|
||||
|
|
@ -516,7 +516,7 @@ static int hfi_process_session_cvp_msg(u32 device_id,
|
|||
|
||||
memcpy(&sess_msg->pkt, pkt, get_msg_size());
|
||||
|
||||
dprintk(CVP_DBG,
|
||||
dprintk(CVP_HFI,
|
||||
"%s: Received msg %x cmd_done.status=%d sessionid=%x\n",
|
||||
__func__, pkt->packet_type,
|
||||
hfi_map_err_status(get_msg_errorcode(pkt)), session_id);
|
||||
|
|
@ -570,7 +570,7 @@ static void hfi_process_sys_get_prop_image_version(
|
|||
cvp_driver->fw_version[i] = ' ';
|
||||
}
|
||||
cvp_driver->fw_version[i] = '\0';
|
||||
dprintk(CVP_DBG, "F/W version: %s\n", cvp_driver->fw_version);
|
||||
dprintk(CVP_HFI, "F/W version: %s\n", cvp_driver->fw_version);
|
||||
}
|
||||
|
||||
static int hfi_process_sys_property_info(u32 device_id,
|
||||
|
|
@ -600,7 +600,7 @@ static int hfi_process_sys_property_info(u32 device_id,
|
|||
};
|
||||
return 0;
|
||||
default:
|
||||
dprintk(CVP_DBG,
|
||||
dprintk(CVP_WARN,
|
||||
"%s: unknown_prop_id: %x\n",
|
||||
__func__, pkt->rg_property_data[0]);
|
||||
return -ENOTSUPP;
|
||||
|
|
@ -621,7 +621,7 @@ int cvp_hfi_process_msg_packet(u32 device_id, void *hdr,
|
|||
return -EINVAL;
|
||||
}
|
||||
|
||||
dprintk(CVP_DBG, "Received HFI MSG with type %#x\n", msg_hdr->packet);
|
||||
dprintk(CVP_HFI, "Received HFI MSG with type %#x\n", msg_hdr->packet);
|
||||
switch (msg_hdr->packet) {
|
||||
case HFI_MSG_EVENT_NOTIFY:
|
||||
pkt_func = (pkt_func_def)hfi_process_event_notify;
|
||||
|
|
@ -664,7 +664,7 @@ int cvp_hfi_process_msg_packet(u32 device_id, void *hdr,
|
|||
pkt_func = (pkt_func_def)hfi_process_session_cvp_msg;
|
||||
break;
|
||||
default:
|
||||
dprintk(CVP_DBG, "Use default msg handler: %#x\n",
|
||||
dprintk(CVP_HFI, "Use default msg handler: %#x\n",
|
||||
msg_hdr->packet);
|
||||
pkt_func = (pkt_func_def)hfi_process_session_cvp_msg;
|
||||
break;
|
||||
|
|
|
|||
|
|
@ -31,7 +31,7 @@ static int msm_cvp_get_session_info(struct msm_cvp_inst *inst,
|
|||
|
||||
s->cur_cmd_type = CVP_KMD_GET_SESSION_INFO;
|
||||
session->session_id = hash32_ptr(inst->session);
|
||||
dprintk(CVP_DBG, "%s: id 0x%x\n", __func__, session->session_id);
|
||||
dprintk(CVP_SESS, "%s: id 0x%x\n", __func__, session->session_id);
|
||||
|
||||
s->cur_cmd_type = 0;
|
||||
cvp_put_inst(s);
|
||||
|
|
@ -291,7 +291,7 @@ static int cvp_fence_dme(struct msm_cvp_inst *inst,
|
|||
u32 hfi_err = HFI_ERR_NONE;
|
||||
struct cvp_hfi_msg_session_hdr *hdr;
|
||||
|
||||
dprintk(CVP_DBG, "%s %s\n", current->comm, __func__);
|
||||
dprintk(CVP_SYNX, "%s %s\n", current->comm, __func__);
|
||||
|
||||
hdev = inst->core->device;
|
||||
sq = &inst->session_queue_fence;
|
||||
|
|
@ -321,7 +321,7 @@ static int cvp_fence_dme(struct msm_cvp_inst *inst,
|
|||
goto exit;
|
||||
}
|
||||
if (hfi_err == HFI_ERR_SESSION_FLUSHED) {
|
||||
dprintk(CVP_DBG, "%s %s: cvp_wait_process_message flushed\n",
|
||||
dprintk(CVP_SYNX, "%s %s: cvp_wait_process_message flushed\n",
|
||||
current->comm, __func__);
|
||||
synx_state = SYNX_STATE_SIGNALED_CANCEL;
|
||||
} else if (hfi_err == HFI_ERR_SESSION_STREAM_CORRUPT) {
|
||||
|
|
@ -353,7 +353,7 @@ static int cvp_fence_proc(struct msm_cvp_inst *inst,
|
|||
u32 hfi_err = HFI_ERR_NONE;
|
||||
struct cvp_hfi_msg_session_hdr *hdr;
|
||||
|
||||
dprintk(CVP_DBG, "%s %s\n", current->comm, __func__);
|
||||
dprintk(CVP_SYNX, "%s %s\n", current->comm, __func__);
|
||||
|
||||
hdev = inst->core->device;
|
||||
sq = &inst->session_queue_fence;
|
||||
|
|
@ -383,7 +383,7 @@ static int cvp_fence_proc(struct msm_cvp_inst *inst,
|
|||
goto exit;
|
||||
}
|
||||
if (hfi_err == HFI_ERR_SESSION_FLUSHED) {
|
||||
dprintk(CVP_DBG, "%s %s: cvp_wait_process_message flushed\n",
|
||||
dprintk(CVP_SYNX, "%s %s: cvp_wait_process_message flushed\n",
|
||||
current->comm, __func__);
|
||||
synx_state = SYNX_STATE_SIGNALED_CANCEL;
|
||||
} else if (hfi_err != HFI_ERR_NONE) {
|
||||
|
|
@ -435,7 +435,7 @@ static int cvp_fence_thread(void *data)
|
|||
u32 *synx;
|
||||
u64 ktid;
|
||||
|
||||
dprintk(CVP_DBG, "Enter %s\n", current->comm);
|
||||
dprintk(CVP_SYNX, "Enter %s\n", current->comm);
|
||||
|
||||
inst = (struct msm_cvp_inst *)data;
|
||||
if (!inst || !inst->core || !inst->core->device) {
|
||||
|
|
@ -447,7 +447,7 @@ static int cvp_fence_thread(void *data)
|
|||
q = &inst->fence_cmd_queue;
|
||||
|
||||
wait:
|
||||
dprintk(CVP_DBG, "%s starts wait\n", current->comm);
|
||||
dprintk(CVP_SYNX, "%s starts wait\n", current->comm);
|
||||
|
||||
f = NULL;
|
||||
wait_event_interruptible(q->wq, cvp_fence_wait(q, &f, &state));
|
||||
|
|
@ -461,7 +461,7 @@ wait:
|
|||
synx = (u32 *)f->synx;
|
||||
|
||||
ktid = pkt->client_data.kdata & (FENCE_BIT - 1);
|
||||
dprintk(CVP_DBG, "%s starts working on frame %llu frameID %llu\n",
|
||||
dprintk(CVP_SYNX, "%s starts working on frame %llu frameID %llu\n",
|
||||
current->comm, ktid, f->frame_id);
|
||||
|
||||
switch (f->type) {
|
||||
|
|
@ -484,7 +484,7 @@ wait:
|
|||
list_del_init(&f->list);
|
||||
mutex_unlock(&q->lock);
|
||||
|
||||
dprintk(CVP_DBG, "%s is done with frame %llu frameID %llu\n",
|
||||
dprintk(CVP_SYNX, "%s is done with frame %llu frameID %llu\n",
|
||||
current->comm, ktid, f->frame_id);
|
||||
|
||||
cvp_free_fence_data(f);
|
||||
|
|
@ -492,7 +492,7 @@ wait:
|
|||
goto wait;
|
||||
|
||||
exit:
|
||||
dprintk(CVP_DBG, "%s exit\n", current->comm);
|
||||
dprintk(CVP_SYNX, "%s exit\n", current->comm);
|
||||
cvp_put_inst(inst);
|
||||
do_exit(rc);
|
||||
}
|
||||
|
|
@ -529,7 +529,7 @@ static int msm_cvp_session_process_hfi_fence(struct msm_cvp_inst *inst,
|
|||
mutex_unlock(&q->lock);
|
||||
|
||||
if (mode == OP_DRAINING) {
|
||||
dprintk(CVP_DBG, "%s: flush in progress\n", __func__);
|
||||
dprintk(CVP_SYNX, "%s: flush in progress\n", __func__);
|
||||
rc = -EBUSY;
|
||||
goto exit;
|
||||
}
|
||||
|
|
@ -585,7 +585,7 @@ static int msm_cvp_session_process_hfi_fence(struct msm_cvp_inst *inst,
|
|||
}
|
||||
|
||||
|
||||
dprintk(CVP_DBG, "%s: frameID %llu\n", __func__, f->frame_id);
|
||||
dprintk(CVP_SYNX, "%s: frameID %llu\n", __func__, f->frame_id);
|
||||
|
||||
memcpy(f->pkt, pkt, pkt->size);
|
||||
|
||||
|
|
@ -760,7 +760,7 @@ static int adjust_bw_freqs(void)
|
|||
min_bw = max_bw/10;
|
||||
|
||||
aggregate_power_update(core, &nrt_pwr, &rt_pwr, cvp_max_rate);
|
||||
dprintk(CVP_DBG, "PwrUpdate nrt %u %u rt %u %u\n",
|
||||
dprintk(CVP_PROF, "PwrUpdate nrt %u %u rt %u %u\n",
|
||||
nrt_pwr.core_sum, nrt_pwr.op_core_sum,
|
||||
rt_pwr.core_sum, rt_pwr.op_core_sum);
|
||||
|
||||
|
|
@ -873,7 +873,7 @@ static int msm_cvp_register_buffer(struct msm_cvp_inst *inst,
|
|||
goto exit;
|
||||
}
|
||||
hdev = inst->core->device;
|
||||
print_client_buffer(CVP_DBG, "register", inst, buf);
|
||||
print_client_buffer(CVP_HFI, "register", inst, buf);
|
||||
|
||||
rc = msm_cvp_map_buf_dsp(inst, buf);
|
||||
exit:
|
||||
|
|
@ -901,7 +901,7 @@ static int msm_cvp_unregister_buffer(struct msm_cvp_inst *inst,
|
|||
return -ECONNRESET;
|
||||
|
||||
inst->cur_cmd_type = CVP_KMD_UNREGISTER_BUFFER;
|
||||
print_client_buffer(CVP_DBG, "unregister", inst, buf);
|
||||
print_client_buffer(CVP_HFI, "unregister", inst, buf);
|
||||
|
||||
rc = msm_cvp_unmap_buf_dsp(inst, buf);
|
||||
inst->cur_cmd_type = 0;
|
||||
|
|
@ -1269,7 +1269,7 @@ static int cvp_drain_fence_cmd_queue_partial(struct msm_cvp_inst *inst)
|
|||
mutex_unlock(&q->lock);
|
||||
wait_time = count * CVP_MAX_WAIT_TIME * 1000;
|
||||
|
||||
dprintk(CVP_DBG, "%s: wait %d us for %d fence command\n",
|
||||
dprintk(CVP_SYNX, "%s: wait %d us for %d fence command\n",
|
||||
__func__, wait_time, count);
|
||||
|
||||
count = 0;
|
||||
|
|
@ -1313,16 +1313,16 @@ static int cvp_drain_fence_sched_list(struct msm_cvp_inst *inst)
|
|||
mutex_lock(&q->lock);
|
||||
list_for_each_entry(f, &q->sched_list, list) {
|
||||
ktid = f->pkt->client_data.kdata & (FENCE_BIT - 1);
|
||||
dprintk(CVP_DBG, "%s: frame %llu is in sched_list\n",
|
||||
dprintk(CVP_SYNX, "%s: frame %llu is in sched_list\n",
|
||||
__func__, ktid);
|
||||
dprintk(CVP_DBG, "%s: frameID %llu is in sched_list\n",
|
||||
dprintk(CVP_SYNX, "%s: frameID %llu is in sched_list\n",
|
||||
__func__, f->frame_id);
|
||||
++count;
|
||||
}
|
||||
mutex_unlock(&q->lock);
|
||||
wait_time = count * CVP_MAX_WAIT_TIME * 1000;
|
||||
|
||||
dprintk(CVP_DBG, "%s: wait %d us for %d fence command\n",
|
||||
dprintk(CVP_SYNX, "%s: wait %d us for %d fence command\n",
|
||||
__func__, wait_time, count);
|
||||
|
||||
count = 0;
|
||||
|
|
@ -1375,9 +1375,9 @@ static int cvp_flush_all(struct msm_cvp_inst *inst)
|
|||
list_for_each_entry_safe(f, d, &q->wait_list, list) {
|
||||
ktid = f->pkt->client_data.kdata & (FENCE_BIT - 1);
|
||||
|
||||
dprintk(CVP_DBG, "%s: flush frame %llu from wait_list\n",
|
||||
dprintk(CVP_SESS, "%s: flush frame %llu from wait_list\n",
|
||||
__func__, ktid);
|
||||
dprintk(CVP_DBG, "%s: flush frameID %llu from wait_list\n",
|
||||
dprintk(CVP_SESS, "%s: flush frameID %llu from wait_list\n",
|
||||
__func__, f->frame_id);
|
||||
|
||||
list_del_init(&f->list);
|
||||
|
|
@ -1390,16 +1390,16 @@ static int cvp_flush_all(struct msm_cvp_inst *inst)
|
|||
list_for_each_entry(f, &q->sched_list, list) {
|
||||
ktid = f->pkt->client_data.kdata & (FENCE_BIT - 1);
|
||||
|
||||
dprintk(CVP_DBG, "%s: flush frame %llu from sched_list\n",
|
||||
dprintk(CVP_SESS, "%s: flush frame %llu from sched_list\n",
|
||||
__func__, ktid);
|
||||
dprintk(CVP_DBG, "%s: flush frameID %llu from sched_list\n",
|
||||
dprintk(CVP_SESS, "%s: flush frameID %llu from sched_list\n",
|
||||
__func__, f->frame_id);
|
||||
cvp_cancel_synx(inst, CVP_INPUT_SYNX, f);
|
||||
}
|
||||
|
||||
mutex_unlock(&q->lock);
|
||||
|
||||
dprintk(CVP_DBG, "%s: send flush to fw\n", __func__);
|
||||
dprintk(CVP_SESS, "%s: send flush to fw\n", __func__);
|
||||
|
||||
/* Send flush to FW */
|
||||
rc = call_hfi_op(hdev, session_flush, (void *)inst->session);
|
||||
|
|
@ -1415,7 +1415,7 @@ static int cvp_flush_all(struct msm_cvp_inst *inst)
|
|||
dprintk(CVP_WARN, "%s: wait for signal failed, rc %d\n",
|
||||
__func__, rc);
|
||||
|
||||
dprintk(CVP_DBG, "%s: received flush from fw\n", __func__);
|
||||
dprintk(CVP_SESS, "%s: received flush from fw\n", __func__);
|
||||
|
||||
exit:
|
||||
rc = cvp_drain_fence_sched_list(inst);
|
||||
|
|
@ -1491,9 +1491,9 @@ static int cvp_flush_frame(struct msm_cvp_inst *inst, u64 frame_id)
|
|||
|
||||
ktid = f->pkt->client_data.kdata & (FENCE_BIT - 1);
|
||||
|
||||
dprintk(CVP_DBG, "%s: flush frame %llu from wait_list\n",
|
||||
dprintk(CVP_SESS, "%s: flush frame %llu from wait_list\n",
|
||||
__func__, ktid);
|
||||
dprintk(CVP_DBG, "%s: flush frameID %llu from wait_list\n",
|
||||
dprintk(CVP_SESS, "%s: flush frameID %llu from wait_list\n",
|
||||
__func__, f->frame_id);
|
||||
|
||||
list_del_init(&f->list);
|
||||
|
|
@ -1509,9 +1509,9 @@ static int cvp_flush_frame(struct msm_cvp_inst *inst, u64 frame_id)
|
|||
|
||||
ktid = f->pkt->client_data.kdata & (FENCE_BIT - 1);
|
||||
|
||||
dprintk(CVP_DBG, "%s: flush frame %llu from sched_list\n",
|
||||
dprintk(CVP_SESS, "%s: flush frame %llu from sched_list\n",
|
||||
__func__, ktid);
|
||||
dprintk(CVP_DBG, "%s: flush frameID %llu from sched_list\n",
|
||||
dprintk(CVP_SESS, "%s: flush frameID %llu from sched_list\n",
|
||||
__func__, f->frame_id);
|
||||
cvp_cancel_synx(inst, CVP_INPUT_SYNX, f);
|
||||
}
|
||||
|
|
@ -1537,7 +1537,7 @@ int msm_cvp_handle_syscall(struct msm_cvp_inst *inst, struct cvp_kmd_arg *arg)
|
|||
dprintk(CVP_ERR, "%s: invalid args\n", __func__);
|
||||
return -EINVAL;
|
||||
}
|
||||
dprintk(CVP_DBG, "%s: arg->type = %x", __func__, arg->type);
|
||||
dprintk(CVP_HFI, "%s: arg->type = %x", __func__, arg->type);
|
||||
|
||||
if (arg->type != CVP_KMD_SESSION_CONTROL &&
|
||||
arg->type != CVP_KMD_SET_SYS_PROPERTY &&
|
||||
|
|
@ -1619,7 +1619,7 @@ int msm_cvp_handle_syscall(struct msm_cvp_inst *inst, struct cvp_kmd_arg *arg)
|
|||
rc = cvp_flush_frame(inst, arg->data.frame_id);
|
||||
break;
|
||||
default:
|
||||
dprintk(CVP_DBG, "%s: unknown arg type %#x\n",
|
||||
dprintk(CVP_HFI, "%s: unknown arg type %#x\n",
|
||||
__func__, arg->type);
|
||||
rc = -ENOTSUPP;
|
||||
break;
|
||||
|
|
@ -1637,7 +1637,7 @@ int msm_cvp_session_deinit(struct msm_cvp_inst *inst)
|
|||
dprintk(CVP_ERR, "%s: invalid params\n", __func__);
|
||||
return -EINVAL;
|
||||
}
|
||||
dprintk(CVP_DBG, "%s: inst %pK (%#x)\n", __func__,
|
||||
dprintk(CVP_SESS, "%s: inst %pK (%#x)\n", __func__,
|
||||
inst, hash32_ptr(inst->session));
|
||||
|
||||
session = (struct cvp_hal_session *)inst->session;
|
||||
|
|
@ -1661,7 +1661,7 @@ int msm_cvp_session_init(struct msm_cvp_inst *inst)
|
|||
return -EINVAL;
|
||||
}
|
||||
|
||||
dprintk(CVP_DBG, "%s: inst %pK (%#x)\n", __func__,
|
||||
dprintk(CVP_SESS, "%s: inst %pK (%#x)\n", __func__,
|
||||
inst, hash32_ptr(inst->session));
|
||||
|
||||
/* set default frequency */
|
||||
|
|
|
|||
|
|
@ -126,7 +126,7 @@ int msm_cvp_map_buf_dsp(struct msm_cvp_inst *inst, struct cvp_kmd_buffer *buf)
|
|||
|
||||
smem->dma_buf = dma_buf;
|
||||
smem->bitmap_index = MAX_DMABUF_NUMS;
|
||||
dprintk(CVP_ERR, "%s: dma_buf = %llx\n", __func__, dma_buf);
|
||||
dprintk(CVP_DSP, "%s: dma_buf = %llx\n", __func__, dma_buf);
|
||||
rc = msm_cvp_map_smem(inst, smem);
|
||||
if (rc) {
|
||||
print_client_buffer(CVP_ERR, "map failed", inst, buf);
|
||||
|
|
@ -234,7 +234,7 @@ void msm_cvp_cache_operations(struct msm_cvp_smem *smem, u32 type,
|
|||
enum smem_cache_ops cache_op;
|
||||
|
||||
if (!msm_cvp_cacheop_enabled) {
|
||||
dprintk(CVP_DBG, "%s: cache operation not enabled\n", __func__);
|
||||
dprintk(CVP_MEM, "%s: cache operation not enabled\n", __func__);
|
||||
return;
|
||||
}
|
||||
|
||||
|
|
@ -280,7 +280,7 @@ static struct msm_cvp_smem *msm_cvp_session_find_smem(struct msm_cvp_inst *inst,
|
|||
*/
|
||||
msm_cvp_smem_put_dma_buf(smem->dma_buf);
|
||||
mutex_unlock(&inst->dma_cache.lock);
|
||||
print_smem(CVP_DBG, "found", inst, smem);
|
||||
print_smem(CVP_MEM, "found", inst, smem);
|
||||
return smem;
|
||||
}
|
||||
|
||||
|
|
@ -408,7 +408,7 @@ static u32 msm_cvp_map_user_persist_buf(struct msm_cvp_inst *inst,
|
|||
list_add_tail(&pbuf->list, &inst->persistbufs.list);
|
||||
mutex_unlock(&inst->persistbufs.lock);
|
||||
|
||||
print_internal_buffer(CVP_DBG, "map persist", inst, pbuf);
|
||||
print_internal_buffer(CVP_MEM, "map persist", inst, pbuf);
|
||||
|
||||
iova = smem->device_addr + buf->offset;
|
||||
|
||||
|
|
@ -448,7 +448,7 @@ u32 msm_cvp_map_frame_buf(struct msm_cvp_inst *inst,
|
|||
frame->bufs[nr].size = buf->size;
|
||||
frame->bufs[nr].offset = buf->offset;
|
||||
|
||||
print_internal_buffer(CVP_DBG, "map cpu", inst, &frame->bufs[nr]);
|
||||
print_internal_buffer(CVP_MEM, "map cpu", inst, &frame->bufs[nr]);
|
||||
|
||||
frame->nr++;
|
||||
|
||||
|
|
@ -501,7 +501,7 @@ void msm_cvp_unmap_frame(struct msm_cvp_inst *inst, u64 ktid)
|
|||
}
|
||||
|
||||
ktid &= (FENCE_BIT - 1);
|
||||
dprintk(CVP_DBG, "%s: unmap frame %llu\n", __func__, ktid);
|
||||
dprintk(CVP_MEM, "%s: unmap frame %llu\n", __func__, ktid);
|
||||
|
||||
found = false;
|
||||
mutex_lock(&inst->frames.lock);
|
||||
|
|
@ -544,7 +544,7 @@ int msm_cvp_unmap_user_persist(struct msm_cvp_inst *inst,
|
|||
list_del(&pbuf->list);
|
||||
smem = pbuf->smem;
|
||||
|
||||
dprintk(CVP_DBG, "unmap persist: %x %d %d %#x",
|
||||
dprintk(CVP_MEM, "unmap persist: %x %d %d %#x",
|
||||
hash32_ptr(inst->session), pbuf->fd,
|
||||
pbuf->size, smem->device_addr);
|
||||
|
||||
|
|
@ -698,7 +698,7 @@ int msm_cvp_map_frame(struct msm_cvp_inst *inst,
|
|||
mutex_lock(&inst->frames.lock);
|
||||
list_add_tail(&frame->list, &inst->frames.list);
|
||||
mutex_unlock(&inst->frames.lock);
|
||||
dprintk(CVP_DBG, "%s: map frame %llu\n", __func__, ktid);
|
||||
dprintk(CVP_MEM, "%s: map frame %llu\n", __func__, ktid);
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
|
@ -724,7 +724,7 @@ int msm_cvp_session_deinit_buffers(struct msm_cvp_inst *inst)
|
|||
for (i = 0; i < inst->dma_cache.nr; i++) {
|
||||
smem = inst->dma_cache.entries[i];
|
||||
if (atomic_read(&smem->refcount) == 0) {
|
||||
print_smem(CVP_DBG, "free", inst, smem);
|
||||
print_smem(CVP_MEM, "free", inst, smem);
|
||||
} else {
|
||||
print_smem(CVP_WARN, "in use", inst, smem);
|
||||
}
|
||||
|
|
@ -738,7 +738,7 @@ int msm_cvp_session_deinit_buffers(struct msm_cvp_inst *inst)
|
|||
mutex_lock(&inst->cvpdspbufs.lock);
|
||||
list_for_each_entry_safe(cbuf, dummy, &inst->cvpdspbufs.list,
|
||||
list) {
|
||||
print_internal_buffer(CVP_DBG, "remove dspbufs", inst, cbuf);
|
||||
print_internal_buffer(CVP_MEM, "remove dspbufs", inst, cbuf);
|
||||
rc = cvp_dsp_deregister_buffer(hash32_ptr(session),
|
||||
cbuf->fd, cbuf->smem->dma_buf->size, cbuf->size,
|
||||
cbuf->offset, cbuf->index,
|
||||
|
|
@ -874,7 +874,7 @@ int cvp_release_arp_buffers(struct msm_cvp_inst *inst)
|
|||
return -EINVAL;
|
||||
}
|
||||
|
||||
dprintk(CVP_DBG, "release persist buffer!\n");
|
||||
dprintk(CVP_MEM, "release persist buffer!\n");
|
||||
|
||||
mutex_lock(&inst->persistbufs.lock);
|
||||
/* Workaround for FW: release buffer means release all */
|
||||
|
|
@ -907,14 +907,14 @@ int cvp_release_arp_buffers(struct msm_cvp_inst *inst)
|
|||
list_del(&buf->list);
|
||||
|
||||
if (buf->ownership == DRIVER) {
|
||||
dprintk(CVP_DBG,
|
||||
dprintk(CVP_MEM,
|
||||
"%s: %x : fd %d %s size %d",
|
||||
"free arp", hash32_ptr(inst->session), buf->fd,
|
||||
smem->dma_buf->name, buf->size);
|
||||
msm_cvp_smem_free(smem);
|
||||
kmem_cache_free(cvp_driver->smem_cache, smem);
|
||||
} else if (buf->ownership == CLIENT) {
|
||||
dprintk(CVP_DBG,
|
||||
dprintk(CVP_MEM,
|
||||
"%s: %x : fd %d %s size %d",
|
||||
"unmap persist", hash32_ptr(inst->session),
|
||||
buf->fd, smem->dma_buf->name, buf->size);
|
||||
|
|
|
|||
|
|
@ -125,7 +125,7 @@ static void handle_sys_init_done(enum hal_command_response cmd, void *data)
|
|||
memcpy(core->capabilities, sys_init_msg->capabilities,
|
||||
sys_init_msg->codec_count * sizeof(struct msm_cvp_capability));
|
||||
|
||||
dprintk(CVP_DBG,
|
||||
dprintk(CVP_CORE,
|
||||
"%s: max_inst_count %d, max_secure_inst_count %d\n",
|
||||
__func__, core->resources.max_inst_count,
|
||||
core->resources.max_secure_inst_count);
|
||||
|
|
@ -236,7 +236,7 @@ static void cvp_handle_session_cmd_done(enum hal_command_response cmd,
|
|||
dprintk(CVP_ERR, "HFI MSG error %d cmd response %d\n",
|
||||
response->status, cmd);
|
||||
|
||||
dprintk(CVP_DBG, "%s: inst=%pK\n", __func__, inst);
|
||||
dprintk(CVP_SESS, "%s: inst=%pK\n", __func__, inst);
|
||||
|
||||
if (IS_HAL_SESSION_CMD(cmd)) {
|
||||
dprintk(CVP_INFO, "%s: calling completion for index = %d",
|
||||
|
|
@ -310,7 +310,7 @@ static void handle_session_release_buf_done(enum hal_command_response cmd,
|
|||
list_for_each_safe(ptr, next, &inst->persistbufs.list) {
|
||||
buf = list_entry(ptr, struct cvp_internal_buf, list);
|
||||
if (address == buf->smem->device_addr + buf->offset) {
|
||||
dprintk(CVP_DBG, "releasing persist: %#x\n",
|
||||
dprintk(CVP_SESS, "releasing persist: %#x\n",
|
||||
buf->smem->device_addr);
|
||||
buf_found = true;
|
||||
}
|
||||
|
|
@ -353,12 +353,12 @@ void change_cvp_inst_state(struct msm_cvp_inst *inst, enum instance_state state)
|
|||
}
|
||||
mutex_lock(&inst->lock);
|
||||
if (inst->state == MSM_CVP_CORE_INVALID) {
|
||||
dprintk(CVP_DBG,
|
||||
dprintk(CVP_SESS,
|
||||
"Inst: %pK is in bad state can't change state to %d\n",
|
||||
inst, state);
|
||||
goto exit;
|
||||
}
|
||||
dprintk(CVP_DBG, "Moved inst: %pK from state: %d to state: %d\n",
|
||||
dprintk(CVP_SESS, "Moved inst: %pK from state: %d to state: %d\n",
|
||||
inst, inst->state, state);
|
||||
inst->state = state;
|
||||
exit:
|
||||
|
|
@ -420,7 +420,7 @@ static int wait_for_state(struct msm_cvp_inst *inst,
|
|||
inst, inst->state);
|
||||
goto err_same_state;
|
||||
}
|
||||
dprintk(CVP_DBG, "Waiting for hal_cmd: %d\n", hal_cmd);
|
||||
dprintk(CVP_SESS, "Waiting for hal_cmd: %d\n", hal_cmd);
|
||||
rc = wait_for_sess_signal_receipt(inst, hal_cmd);
|
||||
if (!rc)
|
||||
change_cvp_inst_state(inst, desired_state);
|
||||
|
|
@ -481,7 +481,7 @@ static void handle_session_init_done(enum hal_command_response cmd, void *data)
|
|||
return;
|
||||
}
|
||||
|
||||
dprintk(CVP_DBG, "%s: cvp session %#x\n", __func__,
|
||||
dprintk(CVP_SESS, "%s: cvp session %#x\n", __func__,
|
||||
hash32_ptr(inst->session));
|
||||
|
||||
signal_session_msg_receipt(cmd, inst);
|
||||
|
|
@ -681,7 +681,7 @@ static void handle_sys_error(enum hal_command_response cmd, void *data)
|
|||
MSM_CVP_ERROR(true);
|
||||
}
|
||||
|
||||
dprintk(CVP_DBG, "Calling core_release\n");
|
||||
dprintk(CVP_CORE, "Calling core_release\n");
|
||||
rc = call_hfi_op(hdev, core_release, hdev->hfi_device_data);
|
||||
if (rc) {
|
||||
dprintk(CVP_ERR, "core_release failed\n");
|
||||
|
|
@ -704,14 +704,14 @@ void msm_cvp_comm_session_clean(struct msm_cvp_inst *inst)
|
|||
return;
|
||||
}
|
||||
if (!inst->session) {
|
||||
dprintk(CVP_DBG, "%s: inst %pK session already cleaned\n",
|
||||
dprintk(CVP_SESS, "%s: inst %pK session already cleaned\n",
|
||||
__func__, inst);
|
||||
return;
|
||||
}
|
||||
|
||||
hdev = inst->core->device;
|
||||
mutex_lock(&inst->lock);
|
||||
dprintk(CVP_DBG, "%s: inst %pK\n", __func__, inst);
|
||||
dprintk(CVP_SESS, "%s: inst %pK\n", __func__, inst);
|
||||
rc = call_hfi_op(hdev, session_clean,
|
||||
(void *)inst->session);
|
||||
if (rc) {
|
||||
|
|
@ -748,7 +748,7 @@ static void handle_session_close(enum hal_command_response cmd, void *data)
|
|||
|
||||
void cvp_handle_cmd_response(enum hal_command_response cmd, void *data)
|
||||
{
|
||||
dprintk(CVP_DBG, "Command response = %d\n", cmd);
|
||||
dprintk(CVP_HFI, "Command response = %d\n", cmd);
|
||||
switch (cmd) {
|
||||
case HAL_SYS_INIT_DONE:
|
||||
handle_sys_init_done(cmd, data);
|
||||
|
|
@ -808,7 +808,7 @@ void cvp_handle_cmd_response(enum hal_command_response cmd, void *data)
|
|||
cvp_handle_session_cmd_done(cmd, data);
|
||||
break;
|
||||
default:
|
||||
dprintk(CVP_DBG, "response unhandled: %d\n", cmd);
|
||||
dprintk(CVP_HFI, "response unhandled: %d\n", cmd);
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
|
@ -851,7 +851,7 @@ static bool is_thermal_permissible(struct msm_cvp_core *core)
|
|||
return true;
|
||||
|
||||
if (msm_cvp_thermal_mitigation_disabled) {
|
||||
dprintk(CVP_DBG,
|
||||
dprintk(CVP_CORE,
|
||||
"Thermal mitigation not enabled. debugfs %d\n",
|
||||
msm_cvp_thermal_mitigation_disabled);
|
||||
return true;
|
||||
|
|
@ -861,7 +861,7 @@ static bool is_thermal_permissible(struct msm_cvp_core *core)
|
|||
freq = core->curr_freq;
|
||||
|
||||
is_turbo = is_core_turbo(core, freq);
|
||||
dprintk(CVP_DBG,
|
||||
dprintk(CVP_CORE,
|
||||
"Core freq %ld Thermal level %d Turbo mode %d\n",
|
||||
freq, tl, is_turbo);
|
||||
|
||||
|
|
@ -980,7 +980,7 @@ int msm_cvp_comm_check_core_init(struct msm_cvp_core *core)
|
|||
core->id, core->state);
|
||||
goto exit;
|
||||
}
|
||||
dprintk(CVP_DBG, "Waiting for SYS_INIT_DONE\n");
|
||||
dprintk(CVP_CORE, "Waiting for SYS_INIT_DONE\n");
|
||||
rc = wait_for_completion_timeout(
|
||||
&core->completions[SYS_MSG_INDEX(HAL_SYS_INIT_DONE)],
|
||||
msecs_to_jiffies(core->resources.msm_cvp_hw_rsp_timeout));
|
||||
|
|
@ -996,7 +996,7 @@ int msm_cvp_comm_check_core_init(struct msm_cvp_core *core)
|
|||
core->state = CVP_CORE_INIT_DONE;
|
||||
rc = 0;
|
||||
}
|
||||
dprintk(CVP_DBG, "SYS_INIT_DONE!!!\n");
|
||||
dprintk(CVP_CORE, "SYS_INIT_DONE!!!\n");
|
||||
exit:
|
||||
mutex_unlock(&core->lock);
|
||||
return rc;
|
||||
|
|
@ -1029,7 +1029,7 @@ static int msm_comm_init_core(struct msm_cvp_inst *inst)
|
|||
hdev = core->device;
|
||||
mutex_lock(&core->lock);
|
||||
if (core->state >= CVP_CORE_INIT) {
|
||||
dprintk(CVP_DBG, "CVP core: %d is already in state: %d\n",
|
||||
dprintk(CVP_CORE, "CVP core: %d is already in state: %d\n",
|
||||
core->id, core->state);
|
||||
goto core_already_inited;
|
||||
}
|
||||
|
|
@ -1048,7 +1048,7 @@ static int msm_comm_init_core(struct msm_cvp_inst *inst)
|
|||
"%s: capabilities memory is expected to be freed\n",
|
||||
__func__);
|
||||
}
|
||||
dprintk(CVP_DBG, "%s: core %pK\n", __func__, core);
|
||||
dprintk(CVP_CORE, "%s: core %pK\n", __func__, core);
|
||||
rc = call_hfi_op(hdev, core_init, hdev->hfi_device_data);
|
||||
if (rc) {
|
||||
dprintk(CVP_ERR, "Failed to init core, id = %d\n",
|
||||
|
|
@ -1106,7 +1106,7 @@ int msm_cvp_deinit_core(struct msm_cvp_inst *inst)
|
|||
msecs_to_jiffies(core->state == CVP_CORE_INIT_DONE ?
|
||||
core->resources.msm_cvp_firmware_unload_delay : 0));
|
||||
|
||||
dprintk(CVP_DBG, "firmware unload delayed by %u ms\n",
|
||||
dprintk(CVP_CORE, "firmware unload delayed by %u ms\n",
|
||||
core->state == CVP_CORE_INIT_DONE ?
|
||||
core->resources.msm_cvp_firmware_unload_delay : 0);
|
||||
}
|
||||
|
|
@ -1122,7 +1122,7 @@ static int msm_comm_session_init_done(int flipped_state,
|
|||
{
|
||||
int rc;
|
||||
|
||||
dprintk(CVP_DBG, "inst %pK: waiting for session init done\n", inst);
|
||||
dprintk(CVP_SESS, "inst %pK: waiting for session init done\n", inst);
|
||||
rc = wait_for_state(inst, flipped_state, MSM_CVP_OPEN_DONE,
|
||||
HAL_SESSION_INIT_DONE);
|
||||
if (rc) {
|
||||
|
|
@ -1152,7 +1152,7 @@ static int msm_comm_session_init(int flipped_state,
|
|||
goto exit;
|
||||
}
|
||||
|
||||
dprintk(CVP_DBG, "%s: inst %pK\n", __func__, inst);
|
||||
dprintk(CVP_SESS, "%s: inst %pK\n", __func__, inst);
|
||||
rc = call_hfi_op(hdev, session_init, hdev->hfi_device_data,
|
||||
inst, &inst->session);
|
||||
|
||||
|
|
@ -1186,7 +1186,7 @@ static int msm_comm_session_close(int flipped_state,
|
|||
goto exit;
|
||||
}
|
||||
hdev = inst->core->device;
|
||||
dprintk(CVP_DBG, "%s: inst %pK\n", __func__, inst);
|
||||
dprintk(CVP_SESS, "%s: inst %pK\n", __func__, inst);
|
||||
rc = call_hfi_op(hdev, session_end, (void *) inst->session);
|
||||
if (rc) {
|
||||
dprintk(CVP_ERR,
|
||||
|
|
@ -1252,7 +1252,7 @@ int msm_cvp_comm_try_state(struct msm_cvp_inst *inst, int state)
|
|||
dprintk(CVP_ERR, "%s: invalid params %pK", __func__, inst);
|
||||
return -EINVAL;
|
||||
}
|
||||
dprintk(CVP_DBG,
|
||||
dprintk(CVP_SESS,
|
||||
"Trying to move inst: %pK (%#x) from: %#x to %#x\n",
|
||||
inst, hash32_ptr(inst->session), inst->state, state);
|
||||
|
||||
|
|
@ -1265,7 +1265,7 @@ int msm_cvp_comm_try_state(struct msm_cvp_inst *inst, int state)
|
|||
}
|
||||
|
||||
flipped_state = get_flipped_state(inst->state, state);
|
||||
dprintk(CVP_DBG,
|
||||
dprintk(CVP_SESS,
|
||||
"inst: %pK (%#x) flipped_state = %#x %x\n",
|
||||
inst, hash32_ptr(inst->session), flipped_state, state);
|
||||
switch (flipped_state) {
|
||||
|
|
@ -1516,7 +1516,7 @@ void msm_cvp_fw_unload_handler(struct work_struct *work)
|
|||
if (list_empty(&core->instances) &&
|
||||
core->state != CVP_CORE_UNINIT) {
|
||||
if (core->state > CVP_CORE_INIT) {
|
||||
dprintk(CVP_DBG, "Calling cvp_hal_core_release\n");
|
||||
dprintk(CVP_CORE, "Calling cvp_hal_core_release\n");
|
||||
rc = call_hfi_op(hdev, core_release,
|
||||
hdev->hfi_device_data);
|
||||
if (rc) {
|
||||
|
|
@ -1552,7 +1552,7 @@ static int set_internal_buf_on_fw(struct msm_cvp_inst *inst,
|
|||
iova = handle->device_addr;
|
||||
size = handle->size;
|
||||
|
||||
dprintk(CVP_DBG, "%s: allocated ARP buffer : %x\n", __func__, iova);
|
||||
dprintk(CVP_SESS, "%s: allocated ARP buffer : %x\n", __func__, iova);
|
||||
|
||||
rc = call_hfi_op(hdev, session_set_buffers,
|
||||
(void *) inst->session, iova, size);
|
||||
|
|
|
|||
|
|
@ -154,7 +154,7 @@ void *msm_cvp_open(int core_id, int session_type)
|
|||
}
|
||||
|
||||
if (!core->resources.auto_pil && session_type == MSM_CVP_BOOT) {
|
||||
dprintk(CVP_DBG, "Auto PIL disabled, bypass CVP init at boot");
|
||||
dprintk(CVP_SESS, "Auto PIL disabled, bypass CVP init at boot");
|
||||
goto err_invalid_core;
|
||||
}
|
||||
|
||||
|
|
@ -178,7 +178,7 @@ void *msm_cvp_open(int core_id, int session_type)
|
|||
goto err_invalid_core;
|
||||
}
|
||||
|
||||
pr_info(CVP_DBG_TAG "Opening cvp instance: %pK\n", "info", inst);
|
||||
pr_info(CVP_DBG_TAG "Opening cvp instance: %pK\n", "sess", inst);
|
||||
mutex_init(&inst->sync_lock);
|
||||
mutex_init(&inst->lock);
|
||||
spin_lock_init(&inst->event_handler.lock);
|
||||
|
|
@ -293,7 +293,7 @@ int msm_cvp_destroy(struct msm_cvp_inst *inst)
|
|||
synx_uninitialize(inst->synx_session_id);
|
||||
|
||||
pr_info(CVP_DBG_TAG "Closed cvp instance: %pK session_id = %d\n",
|
||||
"info", inst, hash32_ptr(inst->session));
|
||||
"sess", inst, hash32_ptr(inst->session));
|
||||
if (inst->cur_cmd_type)
|
||||
dprintk(CVP_ERR, "deleted instance has pending cmd %d\n",
|
||||
inst->cur_cmd_type);
|
||||
|
|
|
|||
|
|
@ -382,7 +382,7 @@ static int inst_info_open(struct inode *inode, struct file *file)
|
|||
static int publish_unreleased_reference(struct msm_cvp_inst *inst,
|
||||
char **dbuf, char *end)
|
||||
{
|
||||
dprintk(CVP_DBG, "%s deprecated function\n", __func__);
|
||||
dprintk(CVP_SESS, "%s deprecated function\n", __func__);
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -23,13 +23,22 @@
|
|||
*/
|
||||
|
||||
enum cvp_msg_prio {
|
||||
CVP_ERR = 0x0001,
|
||||
CVP_WARN = 0x0002,
|
||||
CVP_INFO = 0x0004,
|
||||
CVP_DBG = 0x0008,
|
||||
CVP_PROF = 0x0010,
|
||||
CVP_PKT = 0x0020,
|
||||
CVP_FW = 0x1000,
|
||||
CVP_ERR = 0x000001,
|
||||
CVP_WARN = 0x000002,
|
||||
CVP_INFO = 0x000004,
|
||||
CVP_PROF = 0x000010,
|
||||
CVP_PKT = 0x000020,
|
||||
CVP_MEM = 0x000040,
|
||||
CVP_SYNX = 0x000080,
|
||||
CVP_CORE = 0x000100,
|
||||
CVP_REG = 0x000200,
|
||||
CVP_PWR = 0x000400,
|
||||
CVP_DSP = 0x000800,
|
||||
CVP_FW = 0x001000,
|
||||
CVP_SESS = 0x002000,
|
||||
CVP_HFI = 0x004000,
|
||||
CVP_DBG = CVP_MEM | CVP_SYNX | CVP_CORE | CVP_REG |
|
||||
CVP_PWR | CVP_DSP | CVP_SESS | CVP_HFI,
|
||||
};
|
||||
|
||||
enum cvp_msg_out {
|
||||
|
|
@ -95,8 +104,24 @@ static inline char *get_debug_level_str(int level)
|
|||
return "prof";
|
||||
case CVP_PKT:
|
||||
return "pkt";
|
||||
case CVP_MEM:
|
||||
return "mem";
|
||||
case CVP_SYNX:
|
||||
return "synx";
|
||||
case CVP_CORE:
|
||||
return "core";
|
||||
case CVP_REG:
|
||||
return "reg";
|
||||
case CVP_PWR:
|
||||
return "pwr";
|
||||
case CVP_DSP:
|
||||
return "dsp";
|
||||
case CVP_FW:
|
||||
return "fw";
|
||||
case CVP_SESS:
|
||||
return "sess";
|
||||
case CVP_HFI:
|
||||
return "hfi";
|
||||
default:
|
||||
return "???";
|
||||
}
|
||||
|
|
|
|||
|
|
@ -32,7 +32,7 @@ static int cvp_dsp_send_cmd(struct cvp_dsp_cmd_msg *cmd, uint32_t len)
|
|||
int rc = 0;
|
||||
struct cvp_dsp_apps *me = &gfa_cv;
|
||||
|
||||
dprintk(CVP_DBG, "%s: cmd = %d\n", __func__, cmd->type);
|
||||
dprintk(CVP_DSP, "%s: cmd = %d\n", __func__, cmd->type);
|
||||
|
||||
if (IS_ERR_OR_NULL(me->chan)) {
|
||||
dprintk(CVP_ERR, "%s: DSP GLink is not ready\n", __func__);
|
||||
|
|
@ -55,7 +55,7 @@ static int cvp_dsp_send_cmd_sync(struct cvp_dsp_cmd_msg *cmd, uint32_t len)
|
|||
int rc = 0;
|
||||
struct cvp_dsp_apps *me = &gfa_cv;
|
||||
|
||||
dprintk(CVP_DBG, "%s: cmd = %d\n", __func__, cmd->type);
|
||||
dprintk(CVP_DSP, "%s: cmd = %d\n", __func__, cmd->type);
|
||||
|
||||
rc = cvp_dsp_send_cmd(cmd, len);
|
||||
if (rc) {
|
||||
|
|
@ -92,7 +92,7 @@ static int cvp_dsp_send_cmd_hfi_queue(phys_addr_t *phys_addr,
|
|||
return -EINVAL;
|
||||
}
|
||||
|
||||
dprintk(CVP_DBG,
|
||||
dprintk(CVP_DSP,
|
||||
"%s: address of buffer, PA=0x%pK size_buff=%d ddr_type=%d\n",
|
||||
__func__, phys_addr, size_in_bytes, cmd.ddr_type);
|
||||
|
||||
|
|
@ -190,7 +190,7 @@ static int cvp_dsp_rpmsg_callback(struct rpmsg_device *rpdev,
|
|||
struct cvp_dsp_rsp_msg *rsp = (struct cvp_dsp_rsp_msg *)data;
|
||||
struct cvp_dsp_apps *me = &gfa_cv;
|
||||
|
||||
dprintk(CVP_DBG, "%s: type = 0x%x ret = 0x%x\n",
|
||||
dprintk(CVP_DSP, "%s: type = 0x%x ret = 0x%x\n",
|
||||
__func__, rsp->type, rsp->ret);
|
||||
|
||||
if (rsp->type >= CVP_DSP_MAX_CMD) {
|
||||
|
|
@ -306,11 +306,11 @@ int cvp_dsp_register_buffer(uint32_t session_id, uint32_t buff_fd,
|
|||
cmd.buff_index = buff_index;
|
||||
cmd.buff_fd_iova = buff_fd_iova;
|
||||
|
||||
dprintk(CVP_DBG,
|
||||
dprintk(CVP_DSP,
|
||||
"%s: type=0x%x, buff_fd_iova=0x%x buff_index=0x%x\n",
|
||||
__func__, cmd.type, buff_fd_iova,
|
||||
cmd.buff_index);
|
||||
dprintk(CVP_DBG, "%s: buff_size=0x%x session_id=0x%x\n",
|
||||
dprintk(CVP_DSP, "%s: buff_size=0x%x session_id=0x%x\n",
|
||||
__func__, cmd.buff_size, cmd.session_id);
|
||||
|
||||
mutex_lock(&me->lock);
|
||||
|
|
@ -344,11 +344,11 @@ int cvp_dsp_deregister_buffer(uint32_t session_id, uint32_t buff_fd,
|
|||
cmd.buff_index = buff_index;
|
||||
cmd.buff_fd_iova = buff_fd_iova;
|
||||
|
||||
dprintk(CVP_DBG,
|
||||
dprintk(CVP_DSP,
|
||||
"%s: type=0x%x, buff_fd_iova=0x%x buff_index=0x%x\n",
|
||||
__func__, cmd.type, buff_fd_iova,
|
||||
cmd.buff_index);
|
||||
dprintk(CVP_DBG, "%s: buff_size=0x%x session_id=0x%x\n",
|
||||
dprintk(CVP_DSP, "%s: buff_size=0x%x session_id=0x%x\n",
|
||||
__func__, cmd.buff_size, cmd.session_id);
|
||||
|
||||
mutex_lock(&me->lock);
|
||||
|
|
@ -399,7 +399,7 @@ void cvp_dsp_send_hfi_queue(void)
|
|||
return;
|
||||
}
|
||||
|
||||
dprintk(CVP_DBG, "Entering %s\n", __func__);
|
||||
dprintk(CVP_DSP, "Entering %s\n", __func__);
|
||||
|
||||
mutex_lock(&device->lock);
|
||||
mutex_lock(&me->lock);
|
||||
|
|
@ -408,7 +408,7 @@ void cvp_dsp_send_hfi_queue(void)
|
|||
size = device->dsp_iface_q_table.mem_data.size;
|
||||
|
||||
if (!addr || !size) {
|
||||
dprintk(CVP_DBG, "%s: HFI queue is not ready\n", __func__);
|
||||
dprintk(CVP_DSP, "%s: HFI queue is not ready\n", __func__);
|
||||
goto exit;
|
||||
}
|
||||
|
||||
|
|
@ -431,7 +431,7 @@ void cvp_dsp_send_hfi_queue(void)
|
|||
goto exit;
|
||||
}
|
||||
|
||||
dprintk(CVP_DBG, "%s: dsp initialized\n", __func__);
|
||||
dprintk(CVP_DSP, "%s: dsp initialized\n", __func__);
|
||||
me->state = DSP_READY;
|
||||
|
||||
exit:
|
||||
|
|
|
|||
|
|
@ -227,7 +227,7 @@ static void print_hfi_short(struct cvp_kmd_arg __user *up)
|
|||
get_user(words[4], &pkt->pkt_data[1]))
|
||||
dprintk(CVP_ERR, "Failed to print ioctl cmd\n");
|
||||
|
||||
dprintk(CVP_DBG, "IOCTL cmd type %#x, offset %d, num %d, pkt %d %#x\n",
|
||||
dprintk(CVP_HFI, "IOCTL cmd type %#x, offset %d, num %d, pkt %d %#x\n",
|
||||
words[0], words[1], words[2], words[3], words[4]);
|
||||
}
|
||||
|
||||
|
|
@ -370,7 +370,7 @@ static int convert_from_user(struct cvp_kmd_arg *kp,
|
|||
kp->type, pkt_hdr.size, pkt_hdr.packet_type);
|
||||
return -EFAULT;
|
||||
}
|
||||
dprintk(CVP_DBG, "system call cmd pkt: %d 0x%x\n",
|
||||
dprintk(CVP_HFI, "system call cmd pkt: %d 0x%x\n",
|
||||
pkt_hdr.size, pkt_hdr.packet_type);
|
||||
|
||||
pkt_idx = get_pkt_index(&pkt_hdr);
|
||||
|
|
@ -532,7 +532,7 @@ static int convert_to_user(struct cvp_kmd_arg *kp, unsigned long arg)
|
|||
if (_get_pkt_hdr_from_user(up, &pkt_hdr))
|
||||
return -EFAULT;
|
||||
|
||||
dprintk(CVP_DBG, "Send user cmd pkt: %d %d\n",
|
||||
dprintk(CVP_HFI, "Send user cmd pkt: %d %d\n",
|
||||
pkt_hdr.size, pkt_hdr.packet_type);
|
||||
rc = _copy_pkt_to_user(kp, up, (pkt_hdr.size >> 2));
|
||||
break;
|
||||
|
|
@ -542,7 +542,7 @@ static int convert_to_user(struct cvp_kmd_arg *kp, unsigned long arg)
|
|||
if (_get_fence_pkt_hdr_from_user(up, &pkt_hdr))
|
||||
return -EFAULT;
|
||||
|
||||
dprintk(CVP_DBG, "Send user cmd pkt: %d %d\n",
|
||||
dprintk(CVP_HFI, "Send user cmd pkt: %d %d\n",
|
||||
pkt_hdr.size, pkt_hdr.packet_type);
|
||||
|
||||
rc = _copy_fence_pkt_to_user(kp, up);
|
||||
|
|
|
|||
|
|
@ -127,7 +127,7 @@ static int msm_cvp_load_reg_table(struct msm_cvp_platform_resources *res)
|
|||
* qcom,reg-presets is an optional property. It likely won't be
|
||||
* present if we don't have any register settings to program
|
||||
*/
|
||||
dprintk(CVP_DBG, "qcom,reg-presets not found\n");
|
||||
dprintk(CVP_CORE, "qcom,reg-presets not found\n");
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
|
@ -137,7 +137,7 @@ static int msm_cvp_load_reg_table(struct msm_cvp_platform_resources *res)
|
|||
reg_set->count /= sizeof(*reg_set->reg_tbl) / sizeof(u32);
|
||||
|
||||
if (!reg_set->count) {
|
||||
dprintk(CVP_DBG, "no elements in reg set\n");
|
||||
dprintk(CVP_CORE, "no elements in reg set\n");
|
||||
return rc;
|
||||
}
|
||||
|
||||
|
|
@ -156,7 +156,7 @@ static int msm_cvp_load_reg_table(struct msm_cvp_platform_resources *res)
|
|||
return -EINVAL;
|
||||
}
|
||||
for (i = 0; i < reg_set->count; i++) {
|
||||
dprintk(CVP_DBG,
|
||||
dprintk(CVP_CORE,
|
||||
"reg = %x, value = %x\n",
|
||||
reg_set->reg_tbl[i].reg,
|
||||
reg_set->reg_tbl[i].value
|
||||
|
|
@ -176,7 +176,7 @@ static int msm_cvp_load_qdss_table(struct msm_cvp_platform_resources *res)
|
|||
* qcom,qdss-presets is an optional property. It likely won't be
|
||||
* present if we don't have any register settings to program
|
||||
*/
|
||||
dprintk(CVP_DBG, "qcom,qdss-presets not found\n");
|
||||
dprintk(CVP_CORE, "qcom,qdss-presets not found\n");
|
||||
return rc;
|
||||
}
|
||||
|
||||
|
|
@ -186,7 +186,7 @@ static int msm_cvp_load_qdss_table(struct msm_cvp_platform_resources *res)
|
|||
qdss_addr_set->count /= sizeof(*qdss_addr_set->addr_tbl) / sizeof(u32);
|
||||
|
||||
if (!qdss_addr_set->count) {
|
||||
dprintk(CVP_DBG, "no elements in qdss reg set\n");
|
||||
dprintk(CVP_CORE, "no elements in qdss reg set\n");
|
||||
return rc;
|
||||
}
|
||||
|
||||
|
|
@ -210,7 +210,7 @@ static int msm_cvp_load_qdss_table(struct msm_cvp_platform_resources *res)
|
|||
}
|
||||
|
||||
for (i = 0; i < qdss_addr_set->count; i++) {
|
||||
dprintk(CVP_DBG, "qdss addr = %x, value = %x\n",
|
||||
dprintk(CVP_CORE, "qdss addr = %x, value = %x\n",
|
||||
qdss_addr_set->addr_tbl[i].start,
|
||||
qdss_addr_set->addr_tbl[i].size);
|
||||
}
|
||||
|
|
@ -227,7 +227,7 @@ static int msm_cvp_load_subcache_info(struct msm_cvp_platform_resources *res)
|
|||
num_subcaches = of_property_count_strings(pdev->dev.of_node,
|
||||
"cache-slice-names");
|
||||
if (num_subcaches <= 0) {
|
||||
dprintk(CVP_DBG, "No subcaches found\n");
|
||||
dprintk(CVP_CORE, "No subcaches found\n");
|
||||
goto err_load_subcache_table_fail;
|
||||
}
|
||||
|
||||
|
|
@ -241,7 +241,7 @@ static int msm_cvp_load_subcache_info(struct msm_cvp_platform_resources *res)
|
|||
}
|
||||
|
||||
subcaches->count = num_subcaches;
|
||||
dprintk(CVP_DBG, "Found %d subcaches\n", num_subcaches);
|
||||
dprintk(CVP_CORE, "Found %d subcaches\n", num_subcaches);
|
||||
|
||||
for (c = 0; c < num_subcaches; ++c) {
|
||||
struct subcache_info *vsc = &res->subcache_set.subcache_tbl[c];
|
||||
|
|
@ -287,7 +287,7 @@ int msm_cvp_load_u32_table(struct platform_device *pdev,
|
|||
u32 *ptbl = NULL;
|
||||
|
||||
if (!of_find_property(of_node, table_name, NULL)) {
|
||||
dprintk(CVP_DBG, "%s not found\n", table_name);
|
||||
dprintk(CVP_CORE, "%s not found\n", table_name);
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
|
@ -333,7 +333,7 @@ static int msm_cvp_load_allowed_clocks_table(
|
|||
|
||||
if (!of_find_property(pdev->dev.of_node,
|
||||
"qcom,allowed-clock-rates", NULL)) {
|
||||
dprintk(CVP_DBG, "qcom,allowed-clock-rates not found\n");
|
||||
dprintk(CVP_CORE, "qcom,allowed-clock-rates not found\n");
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
|
@ -428,7 +428,7 @@ static int msm_cvp_populate_bus(struct device *dev,
|
|||
&bus->governor);
|
||||
if (rc) {
|
||||
rc = 0;
|
||||
dprintk(CVP_DBG,
|
||||
dprintk(CVP_CORE,
|
||||
"'qcom,bus-governor' not found, default to performance governor\n");
|
||||
bus->governor = PERF_GOV;
|
||||
}
|
||||
|
|
@ -440,7 +440,7 @@ static int msm_cvp_populate_bus(struct device *dev,
|
|||
range, ARRAY_SIZE(range));
|
||||
if (rc) {
|
||||
rc = 0;
|
||||
dprintk(CVP_DBG,
|
||||
dprintk(CVP_CORE,
|
||||
"'qcom,range' not found defaulting to <0 INT_MAX>\n");
|
||||
range[0] = 0;
|
||||
range[1] = INT_MAX;
|
||||
|
|
@ -451,7 +451,7 @@ static int msm_cvp_populate_bus(struct device *dev,
|
|||
|
||||
buses->count++;
|
||||
bus->dev = dev;
|
||||
dprintk(CVP_DBG, "Found bus %s [%d->%d] with governor %s\n",
|
||||
dprintk(CVP_CORE, "Found bus %s [%d->%d] with governor %s\n",
|
||||
bus->name, bus->master, bus->slave, bus->governor);
|
||||
err_bus:
|
||||
return rc;
|
||||
|
|
@ -537,13 +537,13 @@ static int msm_cvp_load_regulator_table(
|
|||
rinfo->has_hw_power_collapse = of_property_read_bool(
|
||||
regulator_node, "qcom,support-hw-trigger");
|
||||
|
||||
dprintk(CVP_DBG, "Found regulator %s: h/w collapse = %s\n",
|
||||
dprintk(CVP_CORE, "Found regulator %s: h/w collapse = %s\n",
|
||||
rinfo->name,
|
||||
rinfo->has_hw_power_collapse ? "yes" : "no");
|
||||
}
|
||||
|
||||
if (!regulators->count)
|
||||
dprintk(CVP_DBG, "No regulators found");
|
||||
dprintk(CVP_CORE, "No regulators found");
|
||||
|
||||
return 0;
|
||||
|
||||
|
|
@ -564,7 +564,7 @@ static int msm_cvp_load_clock_table(
|
|||
num_clocks = of_property_count_strings(pdev->dev.of_node,
|
||||
"clock-names");
|
||||
if (num_clocks <= 0) {
|
||||
dprintk(CVP_DBG, "No clocks found\n");
|
||||
dprintk(CVP_CORE, "No clocks found\n");
|
||||
clocks->count = 0;
|
||||
rc = 0;
|
||||
goto err_load_clk_table_fail;
|
||||
|
|
@ -595,7 +595,7 @@ static int msm_cvp_load_clock_table(
|
|||
}
|
||||
|
||||
clocks->count = num_clocks;
|
||||
dprintk(CVP_DBG, "Found %d clocks\n", num_clocks);
|
||||
dprintk(CVP_CORE, "Found %d clocks\n", num_clocks);
|
||||
|
||||
for (c = 0; c < num_clocks; ++c) {
|
||||
struct clock_info *vc = &res->clock_set.clock_tbl[c];
|
||||
|
|
@ -615,7 +615,7 @@ static int msm_cvp_load_clock_table(
|
|||
else
|
||||
vc->has_mem_retention = false;
|
||||
|
||||
dprintk(CVP_DBG, "Found clock %s: scale-able = %s\n", vc->name,
|
||||
dprintk(CVP_CORE, "Found clock %s: scale-able = %s\n", vc->name,
|
||||
vc->count ? "yes" : "no");
|
||||
}
|
||||
|
||||
|
|
@ -650,7 +650,7 @@ static int msm_cvp_load_reset_table(
|
|||
return -ENOMEM;
|
||||
|
||||
rst->count = num_clocks;
|
||||
dprintk(CVP_DBG, "Found %d reset clocks\n", num_clocks);
|
||||
dprintk(CVP_CORE, "Found %d reset clocks\n", num_clocks);
|
||||
ret = of_property_read_u32_array(pdev->dev.of_node,
|
||||
"reset-power-status", pwr_stats,
|
||||
num_clocks);
|
||||
|
|
@ -703,7 +703,7 @@ int cvp_read_platform_resources_from_drv_data(
|
|||
|
||||
res->fw_name = "cvpss";
|
||||
|
||||
dprintk(CVP_DBG, "Firmware filename: %s\n", res->fw_name);
|
||||
dprintk(CVP_CORE, "Firmware filename: %s\n", res->fw_name);
|
||||
|
||||
res->auto_pil = find_key_value(platform_data,
|
||||
"qcom,auto-pil");
|
||||
|
|
@ -817,7 +817,7 @@ int cvp_read_platform_resources_from_dt(
|
|||
of_property_read_u32(pdev->dev.of_node, "qcom,fw-bias",
|
||||
&firmware_base);
|
||||
res->firmware_base = (phys_addr_t)firmware_base;
|
||||
dprintk(CVP_DBG,
|
||||
dprintk(CVP_CORE,
|
||||
"Using fw-bias : %pa", &res->firmware_base);
|
||||
}
|
||||
|
||||
|
|
@ -866,8 +866,8 @@ static int msm_cvp_setup_context_bank(struct msm_cvp_platform_resources *res,
|
|||
dma_set_max_seg_size(dev, DMA_BIT_MASK(32));
|
||||
dma_set_seg_boundary(dev, DMA_BIT_MASK(64));
|
||||
|
||||
dprintk(CVP_DBG, "Attached %s and created mapping\n", dev_name(dev));
|
||||
dprintk(CVP_DBG,
|
||||
dprintk(CVP_CORE, "Attached %s and created mapping\n", dev_name(dev));
|
||||
dprintk(CVP_CORE,
|
||||
"Context bank name:%s, buffer_type: %#x, is_secure: %d, address range start: %#x, size: %#x, dev: %pK",
|
||||
cb->name, cb->buffer_type, cb->is_secure, cb->addr_range.start,
|
||||
cb->addr_range.size, cb->dev);
|
||||
|
|
@ -942,12 +942,12 @@ static int msm_cvp_populate_context_bank(struct device *dev,
|
|||
|
||||
rc = of_property_read_string(np, "label", &cb->name);
|
||||
if (rc) {
|
||||
dprintk(CVP_DBG,
|
||||
dprintk(CVP_CORE,
|
||||
"Failed to read cb label from device tree\n");
|
||||
rc = 0;
|
||||
}
|
||||
|
||||
dprintk(CVP_DBG, "%s: context bank has name %s\n", __func__, cb->name);
|
||||
dprintk(CVP_CORE, "%s: context bank has name %s\n", __func__, cb->name);
|
||||
rc = of_property_read_u32_array(np, "qcom,iommu-dma-addr-pool",
|
||||
(u32 *)&cb->addr_range, 2);
|
||||
if (rc) {
|
||||
|
|
@ -958,7 +958,7 @@ static int msm_cvp_populate_context_bank(struct device *dev,
|
|||
}
|
||||
|
||||
cb->is_secure = of_property_read_bool(np, "qcom,iommu-vmid");
|
||||
dprintk(CVP_DBG, "context bank %s : secure = %d\n",
|
||||
dprintk(CVP_CORE, "context bank %s : secure = %d\n",
|
||||
cb->name, cb->is_secure);
|
||||
|
||||
/* setup buffer type for each sub device*/
|
||||
|
|
@ -968,7 +968,7 @@ static int msm_cvp_populate_context_bank(struct device *dev,
|
|||
rc = -ENOENT;
|
||||
goto err_setup_cb;
|
||||
}
|
||||
dprintk(CVP_DBG,
|
||||
dprintk(CVP_CORE,
|
||||
"context bank %s address start = %x address size = %x buffer_type = %x\n",
|
||||
cb->name, cb->addr_range.start,
|
||||
cb->addr_range.size, cb->buffer_type);
|
||||
|
|
@ -1021,7 +1021,7 @@ int cvp_read_context_bank_resources_from_dt(struct platform_device *pdev)
|
|||
if (rc)
|
||||
dprintk(CVP_ERR, "Failed to probe context bank\n");
|
||||
else
|
||||
dprintk(CVP_DBG, "Successfully probed context bank\n");
|
||||
dprintk(CVP_CORE, "Successfully probed context bank\n");
|
||||
|
||||
return rc;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -421,7 +421,7 @@ static int cvp_wait_fd_synx_deprecate(struct synx_session ssid, u32 *synx,
|
|||
if (rc) {
|
||||
*synx_state = synx_get_status(ssid, h_synx);
|
||||
if (*synx_state == SYNX_STATE_SIGNALED_CANCEL) {
|
||||
dprintk(CVP_DBG,
|
||||
dprintk(CVP_SYNX,
|
||||
"%s: synx_wait %d cancel %d state %d\n",
|
||||
current->comm, i, rc, *synx_state);
|
||||
} else {
|
||||
|
|
@ -479,7 +479,7 @@ static int cvp_wait_synx(struct synx_session ssid, u32 *synx, u32 num_synx,
|
|||
if (rc) {
|
||||
*synx_state = synx_get_status(ssid, h_synx);
|
||||
if (*synx_state == SYNX_STATE_SIGNALED_CANCEL) {
|
||||
dprintk(CVP_DBG,
|
||||
dprintk(CVP_SYNX,
|
||||
"%s: synx_wait %d cancel %d state %d\n",
|
||||
current->comm, i, rc, *synx_state);
|
||||
} else {
|
||||
|
|
|
|||
|
|
@ -89,7 +89,7 @@ static int msm_dma_get_device_address(struct dma_buf *dbuf, u32 align,
|
|||
mapping_info->buf = dbuf;
|
||||
mapping_info->cb_info = (void *)cb;
|
||||
} else {
|
||||
dprintk(CVP_DBG, "iommu not present, use phys mem addr\n");
|
||||
dprintk(CVP_MEM, "iommu not present, use phys mem addr\n");
|
||||
}
|
||||
|
||||
return 0;
|
||||
|
|
@ -251,13 +251,13 @@ static int alloc_dma_mem(size_t size, u32 align, u32 flags, int map_kernel,
|
|||
|
||||
if (is_iommu_present(res)) {
|
||||
if (flags & SMEM_ADSP) {
|
||||
dprintk(CVP_DBG, "Allocating from ADSP heap\n");
|
||||
dprintk(CVP_MEM, "Allocating from ADSP heap\n");
|
||||
heap_mask = ION_HEAP(ION_ADSP_HEAP_ID);
|
||||
} else {
|
||||
heap_mask = ION_HEAP(ION_SYSTEM_HEAP_ID);
|
||||
}
|
||||
} else {
|
||||
dprintk(CVP_DBG,
|
||||
dprintk(CVP_MEM,
|
||||
"allocate shared memory from adsp heap size %zx align %d\n",
|
||||
size, align);
|
||||
heap_mask = ION_HEAP(ION_ADSP_HEAP_ID);
|
||||
|
|
@ -314,7 +314,7 @@ static int alloc_dma_mem(size_t size, u32 align, u32 flags, int map_kernel,
|
|||
}
|
||||
}
|
||||
|
||||
dprintk(CVP_DBG,
|
||||
dprintk(CVP_MEM,
|
||||
"%s: dma_buf = %pK, device_addr = %x, size = %d, kvaddr = %pK, ion_flags = %#x, flags = %#lx\n",
|
||||
__func__, mem->dma_buf, mem->device_addr, mem->size,
|
||||
mem->kvaddr, mem->ion_flags, mem->flags);
|
||||
|
|
@ -331,7 +331,7 @@ fail_shared_mem_alloc:
|
|||
|
||||
static int free_dma_mem(struct msm_cvp_smem *mem)
|
||||
{
|
||||
dprintk(CVP_DBG,
|
||||
dprintk(CVP_MEM,
|
||||
"%s: dma_buf = %pK, device_addr = %x, size = %d, kvaddr = %pK, ion_flags = %#x\n",
|
||||
__func__, mem->dma_buf, mem->device_addr, mem->size,
|
||||
mem->kvaddr, mem->ion_flags);
|
||||
|
|
|
|||
Loading…
Reference in a new issue