/net/irda/ |
D | irlap_event.c | 50 static int irlap_state_ndm (struct irlap_cb *self, IRLAP_EVENT event, 52 static int irlap_state_query (struct irlap_cb *self, IRLAP_EVENT event, 54 static int irlap_state_reply (struct irlap_cb *self, IRLAP_EVENT event, 56 static int irlap_state_conn (struct irlap_cb *self, IRLAP_EVENT event, 58 static int irlap_state_setup (struct irlap_cb *self, IRLAP_EVENT event, 60 static int irlap_state_offline(struct irlap_cb *self, IRLAP_EVENT event, 62 static int irlap_state_xmit_p (struct irlap_cb *self, IRLAP_EVENT event, 64 static int irlap_state_pclose (struct irlap_cb *self, IRLAP_EVENT event, 66 static int irlap_state_nrm_p (struct irlap_cb *self, IRLAP_EVENT event, 68 static int irlap_state_reset_wait(struct irlap_cb *self, IRLAP_EVENT event, [all …]
|
D | irlap.c | 60 extern void irlap_queue_xmit(struct irlap_cb *self, struct sk_buff *skb); 61 static void __irlap_close(struct irlap_cb *self); 62 static void irlap_init_qos_capabilities(struct irlap_cb *self, 114 struct irlap_cb *self; in irlap_open() local 119 self = kzalloc(sizeof(struct irlap_cb), GFP_KERNEL); in irlap_open() 120 if (self == NULL) in irlap_open() 123 self->magic = LAP_MAGIC; in irlap_open() 126 self->netdev = dev; in irlap_open() 127 self->qos_dev = qos; in irlap_open() 130 strlcpy(self->hw_name, hw_name, sizeof(self->hw_name)); in irlap_open() [all …]
|
D | irttp.c | 45 static void __irttp_close_tsap(struct tsap_cb *self); 59 static void irttp_run_tx_queue(struct tsap_cb *self); 60 static void irttp_run_rx_queue(struct tsap_cb *self); 62 static void irttp_flush_queues(struct tsap_cb *self); 63 static void irttp_fragment_skb(struct tsap_cb *self, struct sk_buff *skb); 64 static struct sk_buff *irttp_reassemble_skb(struct tsap_cb *self); 141 static inline void irttp_start_todo_timer(struct tsap_cb *self, int timeout) in irttp_start_todo_timer() argument 144 mod_timer(&self->todo_timer, jiffies + timeout); in irttp_start_todo_timer() 163 struct tsap_cb *self = (struct tsap_cb *) data; in irttp_todo_expired() local 166 if (!self || self->magic != TTP_TSAP_MAGIC) in irttp_todo_expired() [all …]
|
D | irlmp_event.c | 119 static inline void irlmp_next_lap_state(struct lap_cb *self, in irlmp_next_lap_state() argument 125 self->lap_state = state; in irlmp_next_lap_state() 128 static inline void irlmp_next_lsap_state(struct lsap_cb *self, in irlmp_next_lsap_state() argument 135 self->lsap_state = state; in irlmp_next_lsap_state() 139 int irlmp_do_lsap_event(struct lsap_cb *self, IRLMP_EVENT event, in irlmp_do_lsap_event() argument 142 IRDA_ASSERT(self != NULL, return -1;); in irlmp_do_lsap_event() 143 IRDA_ASSERT(self->magic == LMP_LSAP_MAGIC, return -1;); in irlmp_do_lsap_event() 146 __func__, irlmp_event[event], irlsap_state[ self->lsap_state]); in irlmp_do_lsap_event() 148 return (*lsap_state[self->lsap_state]) (self, event, skb); in irlmp_do_lsap_event() 157 void irlmp_do_lap_event(struct lap_cb *self, IRLMP_EVENT event, in irlmp_do_lap_event() argument [all …]
|
D | iriap_event.c | 34 static void state_s_disconnect (struct iriap_cb *self, IRIAP_EVENT event, 36 static void state_s_connecting (struct iriap_cb *self, IRIAP_EVENT event, 38 static void state_s_call (struct iriap_cb *self, IRIAP_EVENT event, 41 static void state_s_make_call (struct iriap_cb *self, IRIAP_EVENT event, 43 static void state_s_calling (struct iriap_cb *self, IRIAP_EVENT event, 45 static void state_s_outstanding (struct iriap_cb *self, IRIAP_EVENT event, 47 static void state_s_replying (struct iriap_cb *self, IRIAP_EVENT event, 49 static void state_s_wait_for_call(struct iriap_cb *self, IRIAP_EVENT event, 51 static void state_s_wait_active (struct iriap_cb *self, IRIAP_EVENT event, 54 static void state_r_disconnect (struct iriap_cb *self, IRIAP_EVENT event, [all …]
|
D | irlap_frame.c | 47 static void irlap_send_i_frame(struct irlap_cb *self, struct sk_buff *skb, 57 static inline void irlap_insert_info(struct irlap_cb *self, in irlap_insert_info() argument 67 cb->mtt = self->mtt_required; in irlap_insert_info() 68 cb->next_speed = self->speed; in irlap_insert_info() 71 self->mtt_required = 0; in irlap_insert_info() 77 cb->xbofs = self->bofs_count; in irlap_insert_info() 78 cb->next_xbofs = self->next_bofs; in irlap_insert_info() 79 cb->xbofs_delay = self->xbofs_delay; in irlap_insert_info() 82 self->xbofs_delay = 0; in irlap_insert_info() 84 self->bofs_count = self->next_bofs; in irlap_insert_info() [all …]
|
D | timer.c | 44 void irlap_start_slot_timer(struct irlap_cb *self, int timeout) in irlap_start_slot_timer() argument 46 irda_start_timer(&self->slot_timer, timeout, (void *) self, in irlap_start_slot_timer() 50 void irlap_start_query_timer(struct irlap_cb *self, int S, int s) in irlap_start_query_timer() argument 69 irda_start_timer( &self->query_timer, timeout, (void *) self, in irlap_start_query_timer() 73 void irlap_start_final_timer(struct irlap_cb *self, int timeout) in irlap_start_final_timer() argument 75 irda_start_timer(&self->final_timer, timeout, (void *) self, in irlap_start_final_timer() 79 void irlap_start_wd_timer(struct irlap_cb *self, int timeout) in irlap_start_wd_timer() argument 81 irda_start_timer(&self->wd_timer, timeout, (void *) self, in irlap_start_wd_timer() 85 void irlap_start_backoff_timer(struct irlap_cb *self, int timeout) in irlap_start_backoff_timer() argument 87 irda_start_timer(&self->backoff_timer, timeout, (void *) self, in irlap_start_backoff_timer() [all …]
|
D | iriap.c | 66 static void __iriap_close(struct iriap_cb *self); 67 static int iriap_register_lsap(struct iriap_cb *self, __u8 slsap_sel, int mode); 83 static inline void iriap_start_watchdog_timer(struct iriap_cb *self, in iriap_start_watchdog_timer() argument 86 irda_start_timer(&self->watchdog_timer, timeout, self, in iriap_start_watchdog_timer() 178 struct iriap_cb *self; in iriap_open() local 182 self = kzalloc(sizeof(*self), GFP_ATOMIC); in iriap_open() 183 if (!self) { in iriap_open() 192 self->magic = IAS_MAGIC; in iriap_open() 193 self->mode = mode; in iriap_open() 195 iriap_register_lsap(self, slsap_sel, mode); in iriap_open() [all …]
|
D | af_irda.c | 85 struct irda_sock *self; in irda_data_indication() local 91 self = instance; in irda_data_indication() 97 self->rx_flow = FLOW_STOP; in irda_data_indication() 115 struct irda_sock *self; in irda_disconnect_indication() local 118 self = instance; in irda_disconnect_indication() 120 IRDA_DEBUG(2, "%s(%p)\n", __func__, self); in irda_disconnect_indication() 129 __func__, self); in irda_disconnect_indication() 154 if (self->tsap) { in irda_disconnect_indication() 155 irttp_close_tsap(self->tsap); in irda_disconnect_indication() 156 self->tsap = NULL; in irda_disconnect_indication() [all …]
|
D | irlmp.c | 156 struct lsap_cb *self; in irlmp_open_lsap() local 172 self = kzalloc(sizeof(struct lsap_cb), GFP_ATOMIC); in irlmp_open_lsap() 173 if (self == NULL) { in irlmp_open_lsap() 178 self->magic = LMP_LSAP_MAGIC; in irlmp_open_lsap() 179 self->slsap_sel = slsap_sel; in irlmp_open_lsap() 184 self->dlsap_sel = LSAP_CONNLESS; in irlmp_open_lsap() 185 self->pid = pid; in irlmp_open_lsap() 188 self->dlsap_sel = LSAP_ANY; in irlmp_open_lsap() 191 init_timer(&self->watchdog_timer); in irlmp_open_lsap() 193 self->notify = *notify; in irlmp_open_lsap() [all …]
|
/net/irda/ircomm/ |
D | ircomm_tty_attach.c | 49 static void ircomm_tty_ias_register(struct ircomm_tty_cb *self); 55 static void ircomm_tty_start_watchdog_timer(struct ircomm_tty_cb *self, 59 static int ircomm_tty_state_idle(struct ircomm_tty_cb *self, 63 static int ircomm_tty_state_search(struct ircomm_tty_cb *self, 67 static int ircomm_tty_state_query_parameters(struct ircomm_tty_cb *self, 71 static int ircomm_tty_state_query_lsap_sel(struct ircomm_tty_cb *self, 75 static int ircomm_tty_state_setup(struct ircomm_tty_cb *self, 79 static int ircomm_tty_state_ready(struct ircomm_tty_cb *self, 113 static int (*state[])(struct ircomm_tty_cb *self, IRCOMM_TTY_EVENT event, 131 int ircomm_tty_attach_cable(struct ircomm_tty_cb *self) in ircomm_tty_attach_cable() argument [all …]
|
D | ircomm_tty.c | 70 static void ircomm_tty_shutdown(struct ircomm_tty_cb *self); 112 struct ircomm_tty_cb *self = container_of(port, struct ircomm_tty_cb, in ircomm_port_raise_dtr_rts() local 120 self->settings.dte |= IRCOMM_RTS | IRCOMM_DTR; in ircomm_port_raise_dtr_rts() 122 self->settings.dte &= ~(IRCOMM_RTS | IRCOMM_DTR); in ircomm_port_raise_dtr_rts() 124 ircomm_param_request(self, IRCOMM_DTE, TRUE); in ircomm_port_raise_dtr_rts() 129 struct ircomm_tty_cb *self = container_of(port, struct ircomm_tty_cb, in ircomm_port_carrier_raised() local 131 return self->settings.dce & IRCOMM_CD; in ircomm_port_carrier_raised() 176 static void __exit __ircomm_tty_cleanup(struct ircomm_tty_cb *self) in __ircomm_tty_cleanup() argument 180 IRDA_ASSERT(self != NULL, return;); in __ircomm_tty_cleanup() 181 IRDA_ASSERT(self->magic == IRCOMM_TTY_MAGIC, return;); in __ircomm_tty_cleanup() [all …]
|
D | ircomm_core.c | 51 static int __ircomm_close(struct ircomm_cb *self); 52 static void ircomm_control_indication(struct ircomm_cb *self, 112 struct ircomm_cb *self = NULL; in ircomm_open() local 120 self = kzalloc(sizeof(struct ircomm_cb), GFP_KERNEL); in ircomm_open() 121 if (self == NULL) in ircomm_open() 124 self->notify = *notify; in ircomm_open() 125 self->magic = IRCOMM_MAGIC; in ircomm_open() 129 self->flow_status = FLOW_START; in ircomm_open() 130 ret = ircomm_open_lsap(self); in ircomm_open() 132 ret = ircomm_open_tsap(self); in ircomm_open() [all …]
|
D | ircomm_param.c | 100 int ircomm_param_request(struct ircomm_tty_cb *self, __u8 pi, int flush) in ircomm_param_request() argument 108 IRDA_ASSERT(self != NULL, return -1;); in ircomm_param_request() 109 IRDA_ASSERT(self->magic == IRCOMM_TTY_MAGIC, return -1;); in ircomm_param_request() 112 if (self->service_type == IRCOMM_3_WIRE_RAW) in ircomm_param_request() 115 spin_lock_irqsave(&self->spinlock, flags); in ircomm_param_request() 117 skb = self->ctrl_skb; in ircomm_param_request() 121 spin_unlock_irqrestore(&self->spinlock, flags); in ircomm_param_request() 125 skb_reserve(skb, self->max_header_size); in ircomm_param_request() 126 self->ctrl_skb = skb; in ircomm_param_request() 132 count = irda_param_insert(self, pi, skb_tail_pointer(skb), in ircomm_param_request() [all …]
|
D | ircomm_event.c | 43 static int ircomm_state_idle(struct ircomm_cb *self, IRCOMM_EVENT event, 45 static int ircomm_state_waiti(struct ircomm_cb *self, IRCOMM_EVENT event, 47 static int ircomm_state_waitr(struct ircomm_cb *self, IRCOMM_EVENT event, 49 static int ircomm_state_conn(struct ircomm_cb *self, IRCOMM_EVENT event, 80 static int (*state[])(struct ircomm_cb *self, IRCOMM_EVENT event, 95 static int ircomm_state_idle(struct ircomm_cb *self, IRCOMM_EVENT event, in ircomm_state_idle() argument 102 ircomm_next_state(self, IRCOMM_WAITI); in ircomm_state_idle() 103 ret = self->issue.connect_request(self, skb, info); in ircomm_state_idle() 107 ircomm_next_state(self, IRCOMM_WAITR); in ircomm_state_idle() 108 ircomm_connect_indication(self, skb, info); in ircomm_state_idle() [all …]
|
D | ircomm_lmp.c | 51 static int ircomm_lmp_connect_request(struct ircomm_cb *self, in ircomm_lmp_connect_request() argument 63 ret = irlmp_connect_request(self->lsap, info->dlsap_sel, in ircomm_lmp_connect_request() 74 static int ircomm_lmp_connect_response(struct ircomm_cb *self, in ircomm_lmp_connect_response() argument 102 return irlmp_connect_response(self->lsap, tx_skb); in ircomm_lmp_connect_response() 105 static int ircomm_lmp_disconnect_request(struct ircomm_cb *self, in ircomm_lmp_disconnect_request() argument 127 ret = irlmp_disconnect_request(self->lsap, userdata); in ircomm_lmp_disconnect_request() 142 struct ircomm_cb *self; in ircomm_lmp_flow_control() local 153 self = (struct ircomm_cb *) hashbin_lock_find(ircomm, line, NULL); in ircomm_lmp_flow_control() 154 if (!self) { in ircomm_lmp_flow_control() 159 IRDA_ASSERT(self != NULL, return;); in ircomm_lmp_flow_control() [all …]
|
D | ircomm_tty_ioctl.c | 55 static void ircomm_tty_change_speed(struct ircomm_tty_cb *self, in ircomm_tty_change_speed() argument 63 if (!self->ircomm) in ircomm_tty_change_speed() 89 self->settings.data_rate = baud; in ircomm_tty_change_speed() 90 ircomm_param_request(self, IRCOMM_DATA_RATE, FALSE); in ircomm_tty_change_speed() 94 self->port.flags |= ASYNC_CTS_FLOW; in ircomm_tty_change_speed() 95 self->settings.flow_control |= IRCOMM_RTS_CTS_IN; in ircomm_tty_change_speed() 97 if (self->service_type == IRCOMM_3_WIRE_RAW) in ircomm_tty_change_speed() 100 self->port.flags &= ~ASYNC_CTS_FLOW; in ircomm_tty_change_speed() 101 self->settings.flow_control &= ~IRCOMM_RTS_CTS_IN; in ircomm_tty_change_speed() 104 self->port.flags &= ~ASYNC_CHECK_CD; in ircomm_tty_change_speed() [all …]
|
D | ircomm_ttp.c | 59 static int ircomm_ttp_data_request(struct ircomm_cb *self, 62 static int ircomm_ttp_connect_request(struct ircomm_cb *self, 65 static int ircomm_ttp_connect_response(struct ircomm_cb *self, 67 static int ircomm_ttp_disconnect_request(struct ircomm_cb *self, 77 int ircomm_open_tsap(struct ircomm_cb *self) in ircomm_open_tsap() argument 90 notify.instance = self; in ircomm_open_tsap() 93 self->tsap = irttp_open_tsap(LSAP_ANY, DEFAULT_INITIAL_CREDIT, in ircomm_open_tsap() 95 if (!self->tsap) { in ircomm_open_tsap() 99 self->slsap_sel = self->tsap->stsap_sel; in ircomm_open_tsap() 104 self->issue.data_request = ircomm_ttp_data_request; in ircomm_open_tsap() [all …]
|
/net/irda/irnet/ |
D | irnet_irda.c | 23 irnet_socket * self = in irnet_ppp_disconnect() local 26 if (self == NULL) in irnet_ppp_disconnect() 32 if (self->ppp_open && !self->ttp_open && !self->ttp_connect) { in irnet_ppp_disconnect() 33 ppp_unregister_channel(&self->chan); in irnet_ppp_disconnect() 34 self->ppp_open = 0; in irnet_ppp_disconnect() 124 irnet_open_tsap(irnet_socket * self) in irnet_open_tsap() argument 128 DENTER(IRDA_SR_TRACE, "(self=0x%p)\n", self); in irnet_open_tsap() 130 DABORT(self->tsap != NULL, -EBUSY, IRDA_SR_ERROR, "Already busy !\n"); in irnet_open_tsap() 141 notify.instance = self; in irnet_open_tsap() 145 self->tsap = irttp_open_tsap(LSAP_ANY, DEFAULT_INITIAL_CREDIT, in irnet_open_tsap() [all …]
|
/net/irda/irlan/ |
D | irlan_client_event.c | 39 static int irlan_client_state_idle (struct irlan_cb *self, IRLAN_EVENT event, 41 static int irlan_client_state_query(struct irlan_cb *self, IRLAN_EVENT event, 43 static int irlan_client_state_conn (struct irlan_cb *self, IRLAN_EVENT event, 45 static int irlan_client_state_info (struct irlan_cb *self, IRLAN_EVENT event, 47 static int irlan_client_state_media(struct irlan_cb *self, IRLAN_EVENT event, 49 static int irlan_client_state_open (struct irlan_cb *self, IRLAN_EVENT event, 51 static int irlan_client_state_wait (struct irlan_cb *self, IRLAN_EVENT event, 53 static int irlan_client_state_arb (struct irlan_cb *self, IRLAN_EVENT event, 55 static int irlan_client_state_data (struct irlan_cb *self, IRLAN_EVENT event, 57 static int irlan_client_state_close(struct irlan_cb *self, IRLAN_EVENT event, [all …]
|
D | irlan_client.c | 67 static void irlan_check_response_param(struct irlan_cb *self, char *param, 69 static void irlan_client_open_ctrl_tsap(struct irlan_cb *self); 73 struct irlan_cb *self = (struct irlan_cb *) data; in irlan_client_kick_timer_expired() local 77 IRDA_ASSERT(self != NULL, return;); in irlan_client_kick_timer_expired() 78 IRDA_ASSERT(self->magic == IRLAN_MAGIC, return;); in irlan_client_kick_timer_expired() 85 if ((self->provider.access_type == ACCESS_PEER) && in irlan_client_kick_timer_expired() 86 (self->client.state == IRLAN_IDLE) && in irlan_client_kick_timer_expired() 87 (self->provider.state != IRLAN_IDLE)) { in irlan_client_kick_timer_expired() 88 irlan_client_wakeup(self, self->saddr, self->daddr); in irlan_client_kick_timer_expired() 92 static void irlan_client_start_kick_timer(struct irlan_cb *self, int timeout) in irlan_client_start_kick_timer() argument [all …]
|
D | irlan_common.c | 102 static void __irlan_close(struct irlan_cb *self); 106 static void irlan_open_unicast_addr(struct irlan_cb *self); 107 static void irlan_get_unicast_addr(struct irlan_cb *self); 108 void irlan_close_tsaps(struct irlan_cb *self); 174 struct irlan_cb *self, *next; in irlan_cleanup() local 187 list_for_each_entry_safe(self, next, &irlans, dev_list) { in irlan_cleanup() 188 __irlan_close(self); in irlan_cleanup() 202 struct irlan_cb *self; in irlan_open() local 211 self = netdev_priv(dev); in irlan_open() 212 self->dev = dev; in irlan_open() [all …]
|
D | irlan_provider_event.c | 33 static int irlan_provider_state_idle(struct irlan_cb *self, IRLAN_EVENT event, 35 static int irlan_provider_state_info(struct irlan_cb *self, IRLAN_EVENT event, 37 static int irlan_provider_state_open(struct irlan_cb *self, IRLAN_EVENT event, 39 static int irlan_provider_state_data(struct irlan_cb *self, IRLAN_EVENT event, 42 static int (*state[])(struct irlan_cb *self, IRLAN_EVENT event, 58 void irlan_do_provider_event(struct irlan_cb *self, IRLAN_EVENT event, in irlan_do_provider_event() argument 61 IRDA_ASSERT(*state[ self->provider.state] != NULL, return;); in irlan_do_provider_event() 63 (*state[self->provider.state]) (self, event, skb); in irlan_do_provider_event() 72 static int irlan_provider_state_idle(struct irlan_cb *self, IRLAN_EVENT event, in irlan_provider_state_idle() argument 77 IRDA_ASSERT(self != NULL, return -1;); in irlan_provider_state_idle() [all …]
|
D | irlan_provider.c | 70 struct irlan_cb *self; in irlan_provider_data_indication() local 75 self = instance; in irlan_provider_data_indication() 77 IRDA_ASSERT(self != NULL, return -1;); in irlan_provider_data_indication() 78 IRDA_ASSERT(self->magic == IRLAN_MAGIC, return -1;); in irlan_provider_data_indication() 86 irlan_do_provider_event(self, IRLAN_GET_INFO_CMD, skb); in irlan_provider_data_indication() 91 irlan_do_provider_event(self, IRLAN_GET_MEDIA_CMD, skb); in irlan_provider_data_indication() 95 irlan_do_provider_event(self, IRLAN_OPEN_DATA_CMD, skb); in irlan_provider_data_indication() 99 irlan_do_provider_event(self, IRLAN_FILTER_CONFIG_CMD, skb); in irlan_provider_data_indication() 128 struct irlan_cb *self; in irlan_provider_connect_indication() local 133 self = instance; in irlan_provider_connect_indication() [all …]
|
D | irlan_filter.c | 38 void irlan_filter_request(struct irlan_cb *self, struct sk_buff *skb) in irlan_filter_request() argument 40 IRDA_ASSERT(self != NULL, return;); in irlan_filter_request() 41 IRDA_ASSERT(self->magic == IRLAN_MAGIC, return;); in irlan_filter_request() 43 if ((self->provider.filter_type == IRLAN_DIRECTED) && in irlan_filter_request() 44 (self->provider.filter_operation == DYNAMIC)) in irlan_filter_request() 47 self->provider.mac_address[0] = 0x40; in irlan_filter_request() 48 self->provider.mac_address[1] = 0x00; in irlan_filter_request() 49 self->provider.mac_address[2] = 0x00; in irlan_filter_request() 50 self->provider.mac_address[3] = 0x00; in irlan_filter_request() 53 if (self->provider.access_type == ACCESS_PEER) { in irlan_filter_request() [all …]
|