Re: [PATCH wpan-next v2 07/11] mac802154: Handle association requests from peers

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi Stefan,

> > +static int
> > +mac802154_send_association_resp_locked(struct ieee802154_sub_if_data *sdata,
> > +				       struct ieee802154_pan_device *target,
> > +				       struct ieee802154_assoc_resp_pl *assoc_resp_pl)
> > +{
> > +	u64 teaddr = swab64((__force u64)target->extended_addr);
> > +	struct ieee802154_association_resp_frame frame = {};
> > +	struct ieee802154_local *local = sdata->local;
> > +	struct wpan_dev *wpan_dev = &sdata->wpan_dev;
> > +	struct sk_buff *skb;
> > +	int ret;
> > +
> > +	frame.mhr.fc.type = IEEE802154_FC_TYPE_MAC_CMD;
> > +	frame.mhr.fc.security_enabled = 0;
> > +	frame.mhr.fc.frame_pending = 0;
> > +	frame.mhr.fc.ack_request = 1; /* We always expect an ack here */
> > +	frame.mhr.fc.intra_pan = 1;
> > +	frame.mhr.fc.dest_addr_mode = IEEE802154_EXTENDED_ADDRESSING;
> > +	frame.mhr.fc.version = IEEE802154_2003_STD;
> > +	frame.mhr.fc.source_addr_mode = IEEE802154_EXTENDED_ADDRESSING;
> > +	frame.mhr.seq = 10;  
> 
> Where does the 10 come from and what is the meaning?

Good point, that is a leftover from my earlier WIP versions. A few lines
below this is overwritten by:

	frame.mhr.seq = atomic_inc_return(&wpan_dev->dsn) & 0xFF;

I'll of course drop the `seq = 10` line.

Thanks,
Miquèl




[Index of Archives]     [Linux NFS]     [Linux NILFS]     [Linux USB Devel]     [Linux Audio Users]     [Photo]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux