Bug 3003

Summary: Refactoring of WifiRemoteStationManager
Product: ns-3 Reporter: sebastien.deronne
Component: wifiAssignee: sebastien.deronne
Status: RESOLVED FIXED    
Severity: enhancement CC: ns-bugs, redieteab.orange
Priority: P5    
Version: unspecified   
Hardware: All   
OS: All   
Attachments: patch1: Reduce code size by removing what we can outside of the class
patch2: Move GetControlAnswerMode to MacLow

Description sebastien.deronne 2018-11-03 13:55:30 UTC
I am working on various refactoring patches for 11ad and 11ax integration to ns-3-dev.
WifiRemoteStationManager has grown over the years and deserves a refactoring.
Comment 1 sebastien.deronne 2018-11-03 13:56:47 UTC
Created attachment 3200 [details]
patch1: Reduce code size by removing what we can outside of the class
Comment 2 sebastien.deronne 2018-11-03 13:58:47 UTC
Created attachment 3201 [details]
patch2: Move GetControlAnswerMode to MacLow

GetControlAnswerMode is used by MacLow and this was causing a lot of issues when integrating 802.11ad code (and I guess 11ax in the future). Furthermore, this is the kind of method implemented in the firmware in practice, so MacLow is according to me the best place for selecting the mode of the response frame.
Comment 3 sebastien.deronne 2018-11-03 13:59:16 UTC
I have those two patches for the moment, let me know what you think about it and whether you still see some potential improvements.
Comment 4 Rediet 2018-11-05 02:43:29 UTC
(In reply to sebastien.deronne from comment #2)
> Created attachment 3201 [details]
> patch2: Move GetControlAnswerMode to MacLow

Hello Sébastien.
Quick comment: the UseGreenfieldForDestination method in Patch 2 seems to be already defined in Patch 1.
Comment 5 sebastien.deronne 2018-11-07 07:27:14 UTC
(In reply to Rediet from comment #4)
> (In reply to sebastien.deronne from comment #2)
> > Created attachment 3201 [details]
> > patch2: Move GetControlAnswerMode to MacLow
> 
> Hello Sébastien.
> Quick comment: the UseGreenfieldForDestination method in Patch 2 seems to be
> already defined in Patch 1.

What do you mean? This method is already there.
Comment 6 sebastien.deronne 2018-11-07 07:27:51 UTC
I'd like to push this in the coming days.
Comment 7 Rediet 2018-11-07 08:00:01 UTC
(In reply to sebastien.deronne from comment #5)
> (In reply to Rediet from comment #4)
> > Hello Sébastien.
> > Quick comment: the UseGreenfieldForDestination method in Patch 2 seems to be
> > already defined in Patch 1.
> 
> What do you mean? This method is already there.

Sorry, my mistake, I didn't see that it was simply moved up in the .h.
Comment 8 sebastien.deronne 2018-11-18 03:20:22 UTC
Patches pushed in changesets 13858:63e7f6b8eeaf and 13859:8af38198d131, respectively.