Skip to content

Commit

Permalink
rfxlink: remove deprecated ReceiveDefault and SnoopDefault
Browse files Browse the repository at this point in the history
ReceiveDefault and SnoopDefault were introduced and only used
by TosThreads which has been deprecated.  Remove vestiges.

fixes tinyos#345
  • Loading branch information
cire831 committed Jun 12, 2015
1 parent 1a2292f commit 905d096
Show file tree
Hide file tree
Showing 11 changed files with 2 additions and 94 deletions.
9 changes: 0 additions & 9 deletions tos/chips/atm128rfa1/radio/RFA1ActiveMessageC.nc
Original file line number Diff line number Diff line change
Expand Up @@ -49,11 +49,6 @@ configuration RFA1ActiveMessageC
interface Receive[am_id_t id];
interface Receive as Snoop[am_id_t id];
interface SendNotifier[am_id_t id];

// for TOSThreads
interface Receive as ReceiveDefault[am_id_t id];
interface Receive as SnoopDefault[am_id_t id];

interface Packet;
interface AMPacket;

Expand Down Expand Up @@ -83,10 +78,6 @@ implementation
Receive = RadioC.Receive;
Snoop = RadioC.Snoop;
SendNotifier = RadioC;

ReceiveDefault = RadioC.ReceiveDefault;
SnoopDefault = RadioC.SnoopDefault;

Packet = RadioC.PacketForActiveMessage;
AMPacket = RadioC;

Expand Down
8 changes: 0 additions & 8 deletions tos/chips/atm128rfa1/radio/RFA1RadioC.nc
Original file line number Diff line number Diff line change
Expand Up @@ -56,11 +56,6 @@ configuration RFA1RadioC
interface Receive[am_id_t id];
interface Receive as Snoop[am_id_t id];
interface SendNotifier[am_id_t id];

// for TOSThreads
interface Receive as ReceiveDefault[am_id_t id];
interface Receive as SnoopDefault[am_id_t id];

interface AMPacket;
interface Packet as PacketForActiveMessage;
#endif
Expand Down Expand Up @@ -147,9 +142,6 @@ implementation
SendNotifier = ActiveMessageLayerC;
AMPacket = ActiveMessageLayerC;
PacketForActiveMessage = ActiveMessageLayerC;

ReceiveDefault = ActiveMessageLayerC.ReceiveDefault;
SnoopDefault = ActiveMessageLayerC.SnoopDefault;
#endif

// -------- Automatic RadioSend Resource
Expand Down
9 changes: 0 additions & 9 deletions tos/chips/cc2420x/CC2420XActiveMessageC.nc
Original file line number Diff line number Diff line change
Expand Up @@ -37,11 +37,6 @@ configuration CC2420XActiveMessageC
interface Receive[am_id_t id];
interface Receive as Snoop[am_id_t id];
interface SendNotifier[am_id_t id];

// for TOSThreads
interface Receive as ReceiveDefault[am_id_t id];
interface Receive as SnoopDefault[am_id_t id];

interface Packet;
interface AMPacket;

Expand Down Expand Up @@ -79,10 +74,6 @@ implementation
Receive = RadioC.Receive;
Snoop = RadioC.Snoop;
SendNotifier = RadioC;

ReceiveDefault = RadioC.ReceiveDefault;
SnoopDefault = RadioC.SnoopDefault;

Packet = RadioC.PacketForActiveMessage;
AMPacket = RadioC;

Expand Down
8 changes: 0 additions & 8 deletions tos/chips/cc2420x/CC2420XRadioC.nc
Original file line number Diff line number Diff line change
Expand Up @@ -34,11 +34,6 @@ configuration CC2420XRadioC
interface Receive[am_id_t id];
interface Receive as Snoop[am_id_t id];
interface SendNotifier[am_id_t id];

// for TOSThreads
interface Receive as ReceiveDefault[am_id_t id];
interface Receive as SnoopDefault[am_id_t id];

interface AMPacket;
interface Packet as PacketForActiveMessage;
#endif
Expand Down Expand Up @@ -123,9 +118,6 @@ implementation
SendNotifier = ActiveMessageLayerC;
AMPacket = ActiveMessageLayerC;
PacketForActiveMessage = ActiveMessageLayerC;

ReceiveDefault = ActiveMessageLayerC.ReceiveDefault;
SnoopDefault = ActiveMessageLayerC.SnoopDefault;
#endif

// -------- Automatic RadioSend Resource
Expand Down
8 changes: 0 additions & 8 deletions tos/chips/cc2520/CC2520RadioC.nc
Original file line number Diff line number Diff line change
Expand Up @@ -49,11 +49,6 @@ configuration CC2520RadioC
interface Receive[am_id_t id];
interface Receive as Snoop[am_id_t id];
interface SendNotifier[am_id_t id];

// for TOSThreads
interface Receive as ReceiveDefault[am_id_t id];
interface Receive as SnoopDefault[am_id_t id];

interface AMPacket;
interface Packet as PacketForActiveMessage;
#endif
Expand Down Expand Up @@ -137,9 +132,6 @@ implementation
SendNotifier = ActiveMessageLayerC;
AMPacket = ActiveMessageLayerC;
PacketForActiveMessage = ActiveMessageLayerC;

ReceiveDefault = ActiveMessageLayerC.ReceiveDefault;
SnoopDefault = ActiveMessageLayerC.SnoopDefault;
#endif

// -------- Automatic RadioSend Resource
Expand Down
7 changes: 0 additions & 7 deletions tos/chips/rf212/RF212ActiveMessageC.nc
Original file line number Diff line number Diff line change
Expand Up @@ -49,10 +49,6 @@ configuration RF212ActiveMessageC
interface Receive as Snoop[am_id_t id];
interface SendNotifier[am_id_t id];

// for TOSThreads
interface Receive as ReceiveDefault[am_id_t id];
interface Receive as SnoopDefault[am_id_t id];

interface Packet;
interface AMPacket;

Expand Down Expand Up @@ -83,9 +79,6 @@ implementation
Snoop = RadioC.Snoop;
SendNotifier = RadioC;

ReceiveDefault = RadioC.ReceiveDefault;
SnoopDefault = RadioC.SnoopDefault;

Packet = RadioC.PacketForActiveMessage;
AMPacket = RadioC;

Expand Down
7 changes: 0 additions & 7 deletions tos/chips/rf212/RF212RadioC.nc
Original file line number Diff line number Diff line change
Expand Up @@ -46,10 +46,6 @@ configuration RF212RadioC
interface Receive as Snoop[am_id_t id];
interface SendNotifier[am_id_t id];

// for TOSThreads
interface Receive as ReceiveDefault[am_id_t id];
interface Receive as SnoopDefault[am_id_t id];

interface AMPacket;
interface Packet as PacketForActiveMessage;
#endif
Expand Down Expand Up @@ -134,9 +130,6 @@ implementation
SendNotifier = ActiveMessageLayerC;
AMPacket = ActiveMessageLayerC;
PacketForActiveMessage = ActiveMessageLayerC;

ReceiveDefault = ActiveMessageLayerC.ReceiveDefault;
SnoopDefault = ActiveMessageLayerC.SnoopDefault;
#endif

// -------- Automatic RadioSend Resource
Expand Down
7 changes: 0 additions & 7 deletions tos/chips/rf230/RF230ActiveMessageC.nc
Original file line number Diff line number Diff line change
Expand Up @@ -49,10 +49,6 @@ configuration RF230ActiveMessageC
interface Receive as Snoop[am_id_t id];
interface SendNotifier[am_id_t id];

// for TOSThreads
interface Receive as ReceiveDefault[am_id_t id];
interface Receive as SnoopDefault[am_id_t id];

interface Packet;
interface AMPacket;

Expand Down Expand Up @@ -83,9 +79,6 @@ implementation
Snoop = RadioC.Snoop;
SendNotifier = RadioC;

ReceiveDefault = RadioC.ReceiveDefault;
SnoopDefault = RadioC.SnoopDefault;

Packet = RadioC.PacketForActiveMessage;
AMPacket = RadioC;

Expand Down
8 changes: 0 additions & 8 deletions tos/chips/rf230/RF230RadioC.nc
Original file line number Diff line number Diff line change
Expand Up @@ -55,11 +55,6 @@ configuration RF230RadioC
interface Receive[am_id_t id];
interface Receive as Snoop[am_id_t id];
interface SendNotifier[am_id_t id];

// for TOSThreads
interface Receive as ReceiveDefault[am_id_t id];
interface Receive as SnoopDefault[am_id_t id];

interface AMPacket;
interface Packet as PacketForActiveMessage;
#endif
Expand Down Expand Up @@ -144,9 +139,6 @@ implementation
SendNotifier = ActiveMessageLayerC;
AMPacket = ActiveMessageLayerC;
PacketForActiveMessage = ActiveMessageLayerC;

ReceiveDefault = ActiveMessageLayerC.ReceiveDefault;
SnoopDefault = ActiveMessageLayerC.SnoopDefault;
#endif

// -------- Automatic RadioSend Resource
Expand Down
7 changes: 0 additions & 7 deletions tos/lib/rfxlink/layers/ActiveMessageLayerC.nc
Original file line number Diff line number Diff line change
Expand Up @@ -42,10 +42,6 @@ generic configuration ActiveMessageLayerC()
interface Receive[am_id_t id];
interface Receive as Snoop[am_id_t id];
interface SendNotifier[am_id_t id];

// for TOSThreads
interface Receive as ReceiveDefault[am_id_t id];
interface Receive as SnoopDefault[am_id_t id];
}

uses
Expand All @@ -69,9 +65,6 @@ implementation
Snoop = ActiveMessageLayerP.Snoop;
SendNotifier = ActiveMessageLayerP;

ReceiveDefault = ActiveMessageLayerP.ReceiveDefault;
SnoopDefault = ActiveMessageLayerP.SnoopDefault;

SubPacket = ActiveMessageLayerP;
SubSend = ActiveMessageLayerP;
SubReceive = ActiveMessageLayerP;
Expand Down
18 changes: 2 additions & 16 deletions tos/lib/rfxlink/layers/ActiveMessageLayerP.nc
Original file line number Diff line number Diff line change
Expand Up @@ -46,10 +46,6 @@ generic module ActiveMessageLayerP()
interface Receive[am_id_t id];
interface Receive as Snoop[am_id_t id];
interface SendNotifier[am_id_t id];

// for TOSThreads
interface Receive as ReceiveDefault[am_id_t id];
interface Receive as SnoopDefault[am_id_t id];
}

uses
Expand Down Expand Up @@ -142,22 +138,12 @@ implementation

default event message_t* Receive.receive[am_id_t id](message_t* msg, void* payload, uint8_t len)
{
return signal ReceiveDefault.receive[id](msg, payload, len);;
}

default event message_t* ReceiveDefault.receive[am_id_t id](message_t* msg, void* payload, uint8_t len)
{
return msg;
return msg;
}

default event message_t* Snoop.receive[am_id_t id](message_t* msg, void* payload, uint8_t len)
{
return signal SnoopDefault.receive[id](msg, payload, len);;
}

default event message_t* SnoopDefault.receive[am_id_t id](message_t* msg, void* payload, uint8_t len)
{
return msg;
return msg;
}

/*----------------- AMPacket -----------------*/
Expand Down

0 comments on commit 905d096

Please sign in to comment.