Lines Matching refs:mdev

38 	struct mt76_dev *mdev;  in mt76x2e_probe()  local
55 mdev = mt76_alloc_device(&pdev->dev, sizeof(*dev), &mt76x2_ops, in mt76x2e_probe()
57 if (!mdev) in mt76x2e_probe()
60 dev = container_of(mdev, struct mt76x02_dev, mt76); in mt76x2e_probe()
61 mt76_mmio_init(mdev, pcim_iomap_table(pdev)[0]); in mt76x2e_probe()
64 mdev->rev = mt76_rr(dev, MT_ASIC_VERSION); in mt76x2e_probe()
65 dev_info(mdev->dev, "ASIC revision: %08x\n", mdev->rev); in mt76x2e_probe()
69 ret = devm_request_irq(mdev->dev, pdev->irq, mt76x02_irq_handler, in mt76x2e_probe()
102 struct mt76_dev *mdev = pci_get_drvdata(pdev); in mt76x2e_remove() local
103 struct mt76x02_dev *dev = container_of(mdev, struct mt76x02_dev, mt76); in mt76x2e_remove()
105 mt76_unregister_device(mdev); in mt76x2e_remove()
107 mt76_free_device(mdev); in mt76x2e_remove()
113 struct mt76_dev *mdev = pci_get_drvdata(pdev); in mt76x2e_suspend() local
116 napi_disable(&mdev->tx_napi); in mt76x2e_suspend()
117 tasklet_kill(&mdev->pre_tbtt_tasklet); in mt76x2e_suspend()
118 mt76_worker_disable(&mdev->tx_worker); in mt76x2e_suspend()
120 mt76_for_each_q_rx(mdev, i) in mt76x2e_suspend()
121 napi_disable(&mdev->napi[i]); in mt76x2e_suspend()
132 mt76_for_each_q_rx(mdev, i) in mt76x2e_suspend()
133 napi_enable(&mdev->napi[i]); in mt76x2e_suspend()
134 napi_enable(&mdev->tx_napi); in mt76x2e_suspend()
142 struct mt76_dev *mdev = pci_get_drvdata(pdev); in mt76x2e_resume() local
143 struct mt76x02_dev *dev = container_of(mdev, struct mt76x02_dev, mt76); in mt76x2e_resume()
152 mt76_worker_enable(&mdev->tx_worker); in mt76x2e_resume()
154 mt76_for_each_q_rx(mdev, i) { in mt76x2e_resume()
155 napi_enable(&mdev->napi[i]); in mt76x2e_resume()
157 napi_enable(&mdev->tx_napi); in mt76x2e_resume()
160 mt76_for_each_q_rx(mdev, i) { in mt76x2e_resume()
161 napi_schedule(&mdev->napi[i]); in mt76x2e_resume()
163 napi_schedule(&mdev->tx_napi); in mt76x2e_resume()