Lines Matching refs:facilities
239 static int rose_parse_national(unsigned char *p, struct rose_facilities_struct *facilities, int len) in rose_parse_national() argument
259 facilities->rand = ((p[1] << 8) & 0xFF00) + ((p[2] << 0) & 0x00FF); in rose_parse_national()
283 memcpy(&facilities->source_digis[0], p + 2, AX25_ADDR_LEN); in rose_parse_national()
284 facilities->source_ndigis = 1; in rose_parse_national()
291 memcpy(&facilities->dest_digis[0], p + 2, AX25_ADDR_LEN); in rose_parse_national()
292 facilities->dest_ndigis = 1; in rose_parse_national()
298 memcpy(&facilities->fail_call, p + 2, AX25_ADDR_LEN); in rose_parse_national()
303 memcpy(&facilities->fail_addr, p + 3, ROSE_ADDR_LEN); in rose_parse_national()
309 facilities->source_ndigis = 0; in rose_parse_national()
310 facilities->dest_ndigis = 0; in rose_parse_national()
313 if (facilities->dest_ndigis >= ROSE_MAX_DIGIS) in rose_parse_national()
315 memcpy(&facilities->dest_digis[facilities->dest_ndigis++], pt, AX25_ADDR_LEN); in rose_parse_national()
317 if (facilities->source_ndigis >= ROSE_MAX_DIGIS) in rose_parse_national()
319 memcpy(&facilities->source_digis[facilities->source_ndigis++], pt, AX25_ADDR_LEN); in rose_parse_national()
333 static int rose_parse_ccitt(unsigned char *p, struct rose_facilities_struct *facilities, int len) in rose_parse_ccitt() argument
374 memcpy(&facilities->source_addr, p + 7, ROSE_ADDR_LEN); in rose_parse_ccitt()
377 asc2ax(&facilities->source_call, callsign); in rose_parse_ccitt()
380 memcpy(&facilities->dest_addr, p + 7, ROSE_ADDR_LEN); in rose_parse_ccitt()
383 asc2ax(&facilities->dest_call, callsign); in rose_parse_ccitt()
396 struct rose_facilities_struct *facilities) in rose_parse_facilities() argument
411 len = rose_parse_national(p + 1, facilities, facilities_len - 1); in rose_parse_facilities()
415 len = rose_parse_ccitt(p + 1, facilities, facilities_len - 1); in rose_parse_facilities()