Lines Matching refs:iforce

13 	struct iforce iforce;  member
23 static void __iforce_usb_xmit(struct iforce *iforce) in __iforce_usb_xmit() argument
25 struct iforce_usb *iforce_usb = container_of(iforce, struct iforce_usb, in __iforce_usb_xmit()
26 iforce); in __iforce_usb_xmit()
30 spin_lock_irqsave(&iforce->xmit_lock, flags); in __iforce_usb_xmit()
32 if (iforce->xmit.head == iforce->xmit.tail) { in __iforce_usb_xmit()
33 iforce_clear_xmit_and_wake(iforce); in __iforce_usb_xmit()
34 spin_unlock_irqrestore(&iforce->xmit_lock, flags); in __iforce_usb_xmit()
38 ((char *)iforce_usb->out->transfer_buffer)[0] = iforce->xmit.buf[iforce->xmit.tail]; in __iforce_usb_xmit()
39 XMIT_INC(iforce->xmit.tail, 1); in __iforce_usb_xmit()
40 n = iforce->xmit.buf[iforce->xmit.tail]; in __iforce_usb_xmit()
41 XMIT_INC(iforce->xmit.tail, 1); in __iforce_usb_xmit()
47 c = CIRC_CNT_TO_END(iforce->xmit.head, iforce->xmit.tail, XMIT_SIZE); in __iforce_usb_xmit()
51 &iforce->xmit.buf[iforce->xmit.tail], in __iforce_usb_xmit()
55 &iforce->xmit.buf[0], in __iforce_usb_xmit()
58 XMIT_INC(iforce->xmit.tail, n); in __iforce_usb_xmit()
63 iforce_clear_xmit_and_wake(iforce); in __iforce_usb_xmit()
69 spin_unlock_irqrestore(&iforce->xmit_lock, flags); in __iforce_usb_xmit()
72 static void iforce_usb_xmit(struct iforce *iforce) in iforce_usb_xmit() argument
74 if (!test_and_set_bit(IFORCE_XMIT_RUNNING, iforce->xmit_flags)) in iforce_usb_xmit()
75 __iforce_usb_xmit(iforce); in iforce_usb_xmit()
78 static int iforce_usb_get_id(struct iforce *iforce, u8 id, in iforce_usb_get_id() argument
81 struct iforce_usb *iforce_usb = container_of(iforce, struct iforce_usb, in iforce_usb_get_id()
82 iforce); in iforce_usb_get_id()
111 static int iforce_usb_start_io(struct iforce *iforce) in iforce_usb_start_io() argument
113 struct iforce_usb *iforce_usb = container_of(iforce, struct iforce_usb, in iforce_usb_start_io()
114 iforce); in iforce_usb_start_io()
122 static void iforce_usb_stop_io(struct iforce *iforce) in iforce_usb_stop_io() argument
124 struct iforce_usb *iforce_usb = container_of(iforce, struct iforce_usb, in iforce_usb_stop_io()
125 iforce); in iforce_usb_stop_io()
141 struct iforce *iforce = &iforce_usb->iforce; in iforce_usb_irq() local
162 iforce_process_packet(iforce, iforce_usb->data_in[0], in iforce_usb_irq()
175 struct iforce *iforce = &iforce_usb->iforce; in iforce_usb_out() local
180 iforce_clear_xmit_and_wake(iforce); in iforce_usb_out()
184 __iforce_usb_xmit(iforce); in iforce_usb_out()
186 wake_up_all(&iforce->wait); in iforce_usb_out()
223 iforce_usb->iforce.xport_ops = &iforce_usb_xport_ops; in iforce_usb_probe()
238 err = iforce_init_device(&intf->dev, BUS_USB, &iforce_usb->iforce); in iforce_usb_probe()
261 input_unregister_device(iforce_usb->iforce.dev); in iforce_usb_disconnect()