Lines Matching defs:mhi_cntrl

17 	struct mhi_controller *mhi_cntrl = m->private;
21 to_mhi_pm_state_str(mhi_cntrl->pm_state),
22 mhi_is_active(mhi_cntrl) ? "Active" : "Inactive",
23 mhi_state_str(mhi_cntrl->dev_state),
24 TO_MHI_EXEC_STR(mhi_cntrl->ee),
25 mhi_cntrl->wake_set ? "true" : "false");
28 seq_printf(m, "M0: %u M2: %u M3: %u", mhi_cntrl->M0, mhi_cntrl->M2,
29 mhi_cntrl->M3);
32 atomic_read(&mhi_cntrl->dev_wake),
33 atomic_read(&mhi_cntrl->pending_pkts));
40 struct mhi_controller *mhi_cntrl = m->private;
45 if (!mhi_is_active(mhi_cntrl)) {
50 er_ctxt = mhi_cntrl->mhi_ctxt->er_ctxt;
51 mhi_event = mhi_cntrl->mhi_event;
52 for (i = 0; i < mhi_cntrl->total_ev_rings;
83 struct mhi_controller *mhi_cntrl = m->private;
88 if (!mhi_is_active(mhi_cntrl)) {
93 mhi_chan = mhi_cntrl->mhi_chan;
94 chan_ctxt = mhi_cntrl->mhi_ctxt->chan_ctxt;
95 for (i = 0; i < mhi_cntrl->max_chan; i++, chan_ctxt++, mhi_chan++) {
155 struct mhi_controller *mhi_cntrl = m->private;
157 if (!mhi_is_active(mhi_cntrl)) {
163 mhi_device_info_show(&mhi_cntrl->mhi_dev->dev, m);
164 device_for_each_child(&mhi_cntrl->mhi_dev->dev, m, mhi_device_info_show);
171 struct mhi_controller *mhi_cntrl = m->private;
176 void __iomem *mhi_base = mhi_cntrl->regs;
177 void __iomem *bhi_base = mhi_cntrl->bhi;
178 void __iomem *bhie_base = mhi_cntrl->bhie;
179 void __iomem *wake_db = mhi_cntrl->wake_db;
204 if (!MHI_REG_ACCESS_VALID(mhi_cntrl->pm_state))
208 to_mhi_pm_state_str(mhi_cntrl->pm_state),
209 mhi_state_str(mhi_cntrl->dev_state),
210 TO_MHI_EXEC_STR(mhi_cntrl->ee));
212 state = mhi_get_mhi_state(mhi_cntrl);
213 ee = mhi_get_exec_env(mhi_cntrl);
220 ret = mhi_read_reg(mhi_cntrl, regs[i].base, regs[i].offset,
233 struct mhi_controller *mhi_cntrl = m->private;
234 struct mhi_device *mhi_dev = mhi_cntrl->mhi_dev;
236 if (!mhi_is_active(mhi_cntrl)) {
253 struct mhi_controller *mhi_cntrl = m->private;
254 struct mhi_device *mhi_dev = mhi_cntrl->mhi_dev;
273 struct mhi_controller *mhi_cntrl = m->private;
275 seq_printf(m, "%u ms\n", mhi_cntrl->timeout_ms);
285 struct mhi_controller *mhi_cntrl = m->private;
291 mhi_cntrl->timeout_ms = timeout_ms;
377 void mhi_create_debugfs(struct mhi_controller *mhi_cntrl)
379 mhi_cntrl->debugfs_dentry =
380 debugfs_create_dir(dev_name(&mhi_cntrl->mhi_dev->dev),
383 debugfs_create_file("states", 0444, mhi_cntrl->debugfs_dentry,
384 mhi_cntrl, &debugfs_states_fops);
385 debugfs_create_file("events", 0444, mhi_cntrl->debugfs_dentry,
386 mhi_cntrl, &debugfs_events_fops);
387 debugfs_create_file("channels", 0444, mhi_cntrl->debugfs_dentry,
388 mhi_cntrl, &debugfs_channels_fops);
389 debugfs_create_file("devices", 0444, mhi_cntrl->debugfs_dentry,
390 mhi_cntrl, &debugfs_devices_fops);
391 debugfs_create_file("regdump", 0444, mhi_cntrl->debugfs_dentry,
392 mhi_cntrl, &debugfs_regdump_fops);
393 debugfs_create_file("device_wake", 0644, mhi_cntrl->debugfs_dentry,
394 mhi_cntrl, &debugfs_device_wake_fops);
395 debugfs_create_file("timeout_ms", 0644, mhi_cntrl->debugfs_dentry,
396 mhi_cntrl, &debugfs_timeout_ms_fops);
399 void mhi_destroy_debugfs(struct mhi_controller *mhi_cntrl)
401 debugfs_remove_recursive(mhi_cntrl->debugfs_dentry);
402 mhi_cntrl->debugfs_dentry = NULL;