Lines Matching full:mtu

81 	struct mtu3 *mtu = sf->private;  in mtu3_link_state_show()  local
82 void __iomem *mbase = mtu->mac_base; in mtu3_link_state_show()
93 struct mtu3 *mtu = sf->private; in mtu3_ep_used_show() local
99 spin_lock_irqsave(&mtu->lock, flags); in mtu3_ep_used_show()
101 for (i = 0; i < mtu->num_eps; i++) { in mtu3_ep_used_show()
102 mep = mtu->in_eps + i; in mtu3_ep_used_show()
108 mep = mtu->out_eps + i; in mtu3_ep_used_show()
116 spin_unlock_irqrestore(&mtu->lock, flags); in mtu3_ep_used_show()
124 static void mtu3_debugfs_regset(struct mtu3 *mtu, void __iomem *base, in mtu3_debugfs_regset() argument
131 mregs = devm_kzalloc(mtu->dev, sizeof(*mregs), GFP_KERNEL); in mtu3_debugfs_regset()
144 static void mtu3_debugfs_ep_regset(struct mtu3 *mtu, struct mtu3_ep *mep, in mtu3_debugfs_ep_regset() argument
151 regs = devm_kcalloc(mtu->dev, 7, sizeof(*regs), GFP_KERNEL); in mtu3_debugfs_ep_regset()
170 mtu3_debugfs_regset(mtu, mtu->mac_base, regs, 7, "ep-regs", parent); in mtu3_debugfs_ep_regset()
176 struct mtu3 *mtu = mep->mtu; in mtu3_ep_info_show() local
179 spin_lock_irqsave(&mtu->lock, flags); in mtu3_ep_info_show()
182 spin_unlock_irqrestore(&mtu->lock, flags); in mtu3_ep_info_show()
190 struct mtu3 *mtu = mep->mtu; in mtu3_fifo_show() local
193 spin_lock_irqsave(&mtu->lock, flags); in mtu3_fifo_show()
196 spin_unlock_irqrestore(&mtu->lock, flags); in mtu3_fifo_show()
204 struct mtu3 *mtu = mep->mtu; in mtu3_qmu_ring_show() local
209 spin_lock_irqsave(&mtu->lock, flags); in mtu3_qmu_ring_show()
214 spin_unlock_irqrestore(&mtu->lock, flags); in mtu3_qmu_ring_show()
222 struct mtu3 *mtu = mep->mtu; in mtu3_qmu_gpd_show() local
229 spin_lock_irqsave(&mtu->lock, flags); in mtu3_qmu_gpd_show()
245 spin_unlock_irqrestore(&mtu->lock, flags); in mtu3_qmu_gpd_show()
292 struct mtu3 *mtu = sf->private; in mtu3_probe_show() local
304 mtu3_readl(mtu->ippc_base, (u32)regs->offset)); in mtu3_probe_show()
319 struct mtu3 *mtu = sf->private; in mtu3_probe_write() local
337 mtu3_writel(mtu->ippc_base, (u32)regs->offset, val); in mtu3_probe_write()
350 static void mtu3_debugfs_create_prb_files(struct mtu3 *mtu) in mtu3_debugfs_create_prb_files() argument
352 struct ssusb_mtk *ssusb = mtu->ssusb; in mtu3_debugfs_create_prb_files()
362 mtu, &mtu3_probe_fops); in mtu3_debugfs_create_prb_files()
365 mtu3_debugfs_regset(mtu, mtu->ippc_base, mtu3_prb_regs, in mtu3_debugfs_create_prb_files()
377 mtu3_debugfs_ep_regset(mep->mtu, mep, dir_ep); in mtu3_debugfs_create_ep_dir()
387 static void mtu3_debugfs_create_ep_dirs(struct mtu3 *mtu) in mtu3_debugfs_create_ep_dirs() argument
389 struct ssusb_mtk *ssusb = mtu->ssusb; in mtu3_debugfs_create_ep_dirs()
395 for (i = 1; i < mtu->num_eps; i++) { in mtu3_debugfs_create_ep_dirs()
396 mtu3_debugfs_create_ep_dir(mtu->in_eps + i, dir_eps); in mtu3_debugfs_create_ep_dirs()
397 mtu3_debugfs_create_ep_dir(mtu->out_eps + i, dir_eps); in mtu3_debugfs_create_ep_dirs()
403 struct mtu3 *mtu = ssusb->u3d; in ssusb_dev_debugfs_init() local
408 mtu3_debugfs_regset(mtu, mtu->ippc_base, in ssusb_dev_debugfs_init()
412 mtu3_debugfs_regset(mtu, mtu->mac_base, in ssusb_dev_debugfs_init()
416 mtu3_debugfs_regset(mtu, mtu->mac_base, in ssusb_dev_debugfs_init()
420 mtu3_debugfs_create_ep_dirs(mtu); in ssusb_dev_debugfs_init()
422 mtu3_debugfs_create_prb_files(mtu); in ssusb_dev_debugfs_init()
425 mtu, &mtu3_link_state_fops); in ssusb_dev_debugfs_init()
427 mtu, &mtu3_ep_used_fops); in ssusb_dev_debugfs_init()