• Home
  • Raw
  • Download

Lines Matching refs:hdr

331 					 struct ieee802154_hdr *hdr,  in mac802154_set_header_security()  argument
350 hdr->fc.security_enabled = 1; in mac802154_set_header_security()
351 hdr->sec.level = level; in mac802154_set_header_security()
352 hdr->sec.key_id_mode = params.out_key.mode; in mac802154_set_header_security()
354 hdr->sec.short_src = params.out_key.short_source; in mac802154_set_header_security()
356 hdr->sec.extended_src = params.out_key.extended_source; in mac802154_set_header_security()
357 hdr->sec.key_id = params.out_key.id; in mac802154_set_header_security()
368 struct ieee802154_hdr hdr; in ieee802154_header_create() local
377 memset(&hdr.fc, 0, sizeof(hdr.fc)); in ieee802154_header_create()
378 hdr.fc.type = cb->type; in ieee802154_header_create()
379 hdr.fc.security_enabled = cb->secen; in ieee802154_header_create()
380 hdr.fc.ack_request = cb->ackreq; in ieee802154_header_create()
381 hdr.seq = atomic_inc_return(&dev->ieee802154_ptr->dsn) & 0xFF; in ieee802154_header_create()
383 if (mac802154_set_header_security(sdata, &hdr, cb) < 0) in ieee802154_header_create()
390 hdr.source.mode = IEEE802154_ADDR_LONG; in ieee802154_header_create()
391 hdr.source.extended_addr = wpan_dev->extended_addr; in ieee802154_header_create()
393 hdr.source.mode = IEEE802154_ADDR_SHORT; in ieee802154_header_create()
394 hdr.source.short_addr = wpan_dev->short_addr; in ieee802154_header_create()
397 hdr.source.pan_id = wpan_dev->pan_id; in ieee802154_header_create()
399 hdr.source = *(const struct ieee802154_addr *)saddr; in ieee802154_header_create()
402 hdr.dest = *(const struct ieee802154_addr *)daddr; in ieee802154_header_create()
404 hlen = ieee802154_hdr_push(skb, &hdr); in ieee802154_header_create()
411 if (len > ieee802154_max_payload(&hdr)) in ieee802154_header_create()
434 struct ieee802154_hdr hdr; in mac802154_header_create() local
443 memset(&hdr.fc, 0, sizeof(hdr.fc)); in mac802154_header_create()
444 hdr.fc.type = IEEE802154_FC_TYPE_DATA; in mac802154_header_create()
445 hdr.fc.ack_request = wpan_dev->ackreq; in mac802154_header_create()
446 hdr.seq = atomic_inc_return(&dev->ieee802154_ptr->dsn) & 0xFF; in mac802154_header_create()
451 if (mac802154_set_header_security(sdata, &hdr, &cb) < 0) in mac802154_header_create()
454 hdr.dest.pan_id = wpan_dev->pan_id; in mac802154_header_create()
455 hdr.dest.mode = IEEE802154_ADDR_LONG; in mac802154_header_create()
456 ieee802154_be64_to_le64(&hdr.dest.extended_addr, daddr); in mac802154_header_create()
458 hdr.source.pan_id = hdr.dest.pan_id; in mac802154_header_create()
459 hdr.source.mode = IEEE802154_ADDR_LONG; in mac802154_header_create()
462 hdr.source.extended_addr = wpan_dev->extended_addr; in mac802154_header_create()
464 ieee802154_be64_to_le64(&hdr.source.extended_addr, saddr); in mac802154_header_create()
466 hlen = ieee802154_hdr_push(skb, &hdr); in mac802154_header_create()
473 if (len > ieee802154_max_payload(&hdr)) in mac802154_header_create()
482 struct ieee802154_hdr hdr; in mac802154_header_parse() local
484 if (ieee802154_hdr_peek_addrs(skb, &hdr) < 0) { in mac802154_header_parse()
489 if (hdr.source.mode == IEEE802154_ADDR_LONG) { in mac802154_header_parse()
490 ieee802154_le64_to_be64(haddr, &hdr.source.extended_addr); in mac802154_header_parse()