Lines Matching refs:dbg
26 struct wiimote_debug *dbg = f->private_data; in wiidebug_eeprom_read() local
27 struct wiimote_data *wdata = dbg->wdata; in wiidebug_eeprom_read()
100 struct wiimote_debug *dbg = f->private; in wiidebug_drm_show() local
105 spin_lock_irqsave(&dbg->wdata->state.lock, flags); in wiidebug_drm_show()
106 drm = dbg->wdata->state.drm; in wiidebug_drm_show()
107 spin_unlock_irqrestore(&dbg->wdata->state.lock, flags); in wiidebug_drm_show()
128 struct wiimote_debug *dbg = sf->private; in wiidebug_drm_write() local
153 spin_lock_irqsave(&dbg->wdata->state.lock, flags); in wiidebug_drm_write()
154 dbg->wdata->state.flags &= ~WIIPROTO_FLAG_DRM_LOCKED; in wiidebug_drm_write()
155 wiiproto_req_drm(dbg->wdata, (__u8) i); in wiidebug_drm_write()
157 dbg->wdata->state.flags |= WIIPROTO_FLAG_DRM_LOCKED; in wiidebug_drm_write()
158 spin_unlock_irqrestore(&dbg->wdata->state.lock, flags); in wiidebug_drm_write()
174 struct wiimote_debug *dbg; in wiidebug_init() local
178 dbg = kzalloc(sizeof(*dbg), GFP_KERNEL); in wiidebug_init()
179 if (!dbg) in wiidebug_init()
182 dbg->wdata = wdata; in wiidebug_init()
184 dbg->eeprom = debugfs_create_file("eeprom", S_IRUSR, in wiidebug_init()
185 dbg->wdata->hdev->debug_dir, dbg, &wiidebug_eeprom_fops); in wiidebug_init()
186 if (!dbg->eeprom) in wiidebug_init()
189 dbg->drm = debugfs_create_file("drm", S_IRUSR, in wiidebug_init()
190 dbg->wdata->hdev->debug_dir, dbg, &wiidebug_drm_fops); in wiidebug_init()
191 if (!dbg->drm) in wiidebug_init()
195 wdata->debug = dbg; in wiidebug_init()
201 debugfs_remove(dbg->eeprom); in wiidebug_init()
203 kfree(dbg); in wiidebug_init()
209 struct wiimote_debug *dbg = wdata->debug; in wiidebug_deinit() local
212 if (!dbg) in wiidebug_deinit()
219 debugfs_remove(dbg->drm); in wiidebug_deinit()
220 debugfs_remove(dbg->eeprom); in wiidebug_deinit()
221 kfree(dbg); in wiidebug_deinit()