Toggle navigation
Toggle navigation
This project
Loading...
Sign in
홍길동
/
onos
Go to a project
Toggle navigation
Toggle navigation pinning
Projects
Groups
Snippets
Help
Project
Activity
Repository
Pipelines
Graphs
Issues
0
Merge Requests
0
Wiki
Snippets
Network
Create a new issue
Builds
Commits
Issue Boards
Authored by
alshabib
2014-09-17 09:22:51 -0700
Browse Files
Options
Browse Files
Download
Email Patches
Plain Diff
Commit
e79bf95b61d352ec336aad6146a904e591b78ce3
e79bf95b
1 parent
9842a4ef
esthetic changes
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
11 additions
and
20 deletions
apps/fwd/src/main/java/org/onlab/onos/fwd/ReactiveForwarding.java
of/api/src/main/java/org/onlab/onos/of/controller/DefaultOpenFlowPacketContext.java
of/ctl/src/main/java/org/onlab/onos/of/controller/impl/Controller.java
of/ctl/src/main/java/org/onlab/onos/of/controller/impl/OFChannelHandler.java
apps/fwd/src/main/java/org/onlab/onos/fwd/ReactiveForwarding.java
View file @
e79bf95
...
...
@@ -156,9 +156,7 @@ public class ReactiveForwarding {
private
void
installRule
(
PacketContext
context
,
PortNumber
portNumber
)
{
// we don't yet support bufferids in the flowservice so packet out and
// then install a flowmod.
context
.
treatmentBuilder
().
add
(
Instructions
.
createOutput
(
portNumber
));
context
.
send
();
packetOutFlood
(
context
);
Ethernet
inPkt
=
context
.
inPacket
().
parsed
();
TrafficSelector
.
Builder
builder
=
new
DefaultTrafficSelector
.
Builder
();
...
...
of/api/src/main/java/org/onlab/onos/of/controller/DefaultOpenFlowPacketContext.java
View file @
e79bf95
...
...
@@ -78,7 +78,8 @@ public final class DefaultOpenFlowPacketContext implements OpenFlowPacketContext
return
new
Dpid
(
sw
.
getId
());
}
public
static
OpenFlowPacketContext
packetContextFromPacketIn
(
OpenFlowSwitch
s
,
OFPacketIn
pkt
)
{
public
static
OpenFlowPacketContext
packetContextFromPacketIn
(
OpenFlowSwitch
s
,
OFPacketIn
pkt
)
{
return
new
DefaultOpenFlowPacketContext
(
s
,
pkt
);
}
...
...
of/ctl/src/main/java/org/onlab/onos/of/controller/impl/Controller.java
View file @
e79bf95
...
...
@@ -53,8 +53,6 @@ public class Controller {
protected
static
final
OFFactory
FACTORY13
=
OFFactories
.
getFactory
(
OFVersion
.
OF_13
);
protected
static
final
OFFactory
FACTORY10
=
OFFactories
.
getFactory
(
OFVersion
.
OF_10
);
// The controllerNodeIPsCache maps Controller IDs to their IP address.
// It's only used by handleControllerNodeIPsChanged
protected
HashMap
<
String
,
String
>
controllerNodeIPsCache
;
...
...
@@ -68,16 +66,12 @@ public class Controller {
// Start time of the controller
protected
long
systemStartTime
;
// Flag to always flush flow table on switch reconnect (HA or otherwise)
protected
boolean
alwaysClearFlowsOnSwAdd
=
false
;
private
OpenFlowAgent
agent
;
private
NioServerSocketChannelFactory
execFactory
;
// Perf. related configuration
protected
static
final
int
SEND_BUFFER_SIZE
=
4
*
1024
*
1024
;
protected
static
final
int
BATCH_MAX_SIZE
=
100
;
protected
static
final
boolean
ALWAYS_DECODE_ETH
=
true
;
// ***************
// Getters/Setters
...
...
of/ctl/src/main/java/org/onlab/onos/of/controller/impl/OFChannelHandler.java
View file @
e79bf95
...
...
@@ -538,43 +538,41 @@ class OFChannelHandler extends IdleStateAwareChannelHandler {
@Override
void
processOFStatisticsReply
(
OFChannelHandler
h
,
OFStatsReply
m
)
{
h
.
sw
.
handle
Message
(
m
);
h
.
dispatch
Message
(
m
);
}
@Override
void
processOFExperimenter
(
OFChannelHandler
h
,
OFExperimenter
m
)
throws
IOException
,
SwitchStateException
{
throws
SwitchStateException
{
h
.
sw
.
handleNiciraRole
(
m
);
}
@Override
void
processOFRoleReply
(
OFChannelHandler
h
,
OFRoleReply
m
)
throws
SwitchStateException
,
IOException
{
throws
SwitchStateException
{
h
.
sw
.
handleRole
(
m
);
}
@Override
void
processOFPortStatus
(
OFChannelHandler
h
,
OFPortStatus
m
)
throws
IOException
,
SwitchStateException
{
throws
SwitchStateException
{
handlePortStatusMessage
(
h
,
m
,
true
);
h
.
dispatchMessage
(
m
);
}
@Override
void
processOFPacketIn
(
OFChannelHandler
h
,
OFPacketIn
m
)
throws
IOException
{
void
processOFPacketIn
(
OFChannelHandler
h
,
OFPacketIn
m
)
{
h
.
dispatchMessage
(
m
);
}
@Override
void
processOFFlowRemoved
(
OFChannelHandler
h
,
OFFlowRemoved
m
)
throws
IOException
{
OFFlowRemoved
m
)
{
h
.
dispatchMessage
(
m
);
}
@Override
void
processOFBarrierReply
(
OFChannelHandler
h
,
OFBarrierReply
m
)
throws
IOException
{
void
processOFBarrierReply
(
OFChannelHandler
h
,
OFBarrierReply
m
)
{
h
.
dispatchMessage
(
m
);
}
...
...
@@ -1092,7 +1090,7 @@ class OFChannelHandler extends IdleStateAwareChannelHandler {
return
this
.
state
.
isHandshakeComplete
();
}
private
void
dispatchMessage
(
OFMessage
m
)
throws
IOException
{
private
void
dispatchMessage
(
OFMessage
m
)
{
sw
.
handleMessage
(
m
);
}
...
...
Please
register
or
login
to post a comment