Skip to content

Commit

Permalink
Switched to flow isolation by default instead of dropping from queue 0 (
Browse files Browse the repository at this point in the history
#624)

* Switched to flow isolation by default instead of dropping from queue 0

Signed-off-by: Cliff Burdick <cburdick@nvidia.com>

* Code review comments

Signed-off-by: Cliff Burdick <cburdick@nvidia.com>

---------

Signed-off-by: Cliff Burdick <cburdick@nvidia.com>
  • Loading branch information
cliffburdick authored Dec 16, 2024
1 parent 0e89c6e commit a30a331
Show file tree
Hide file tree
Showing 5 changed files with 9 additions and 68 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -48,28 +48,15 @@ advanced_network:
- local
num_bufs: 30720
buf_size: 1064
- name: "Default_RX_CPU"
kind: "huge"
affinity: 0
access:
- local
num_bufs: 30720
buf_size: 1064

interfaces:
- name: data2
address: 0005:03:00.0
flow_isolation: true
rx:
- queues:
- name: "Default"
id: 0
cpu_core: 7
batch_size: 10240
output_port: "bench_rx_out"
memory_regions:
- "Default_RX_CPU"
- name: "Data"
id: 1
id: 0
cpu_core: 8
batch_size: 10240
output_port: "bench_rx_out"
Expand All @@ -80,7 +67,7 @@ advanced_network:
- name: "ADC Samples"
action:
type: queue
id: 1
id: 0
match:
udp_src: 4096 #12288
udp_dst: 4096 #12288
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -42,13 +42,6 @@ advanced_network:
- local
num_bufs: 51200
buf_size: 9000
- name: "Default_RX_GPU"
kind: "device"
affinity: 0
access:
- local
num_bufs: 51200
buf_size: 9000
- name: "Data_RX_GPU"
kind: "device"
affinity: 0
Expand All @@ -72,18 +65,11 @@ advanced_network:
- "tx_eth_src"
- name: data2
address: <0000:00:00.0> # The BUS address of the interface doing Rx
flow_isolation: false
flow_isolation: true
rx:
- queues:
- name: "Default"
id: 0
cpu_core: 10
batch_size: 10240
output_port: "bench_rx_out"
memory_regions:
- "Default_RX_GPU"
- name: "Data"
id: 1
id: 0
cpu_core: 9
batch_size: 10240
output_port: "bench_rx_out"
Expand All @@ -94,7 +80,7 @@ advanced_network:
id: 2
action:
type: queue
id: 1
id: 0
match:
udp_src: 4096 #12288
udp_dst: 4096 #12288
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -39,13 +39,6 @@ advanced_network:
- local
num_bufs: 51200
buf_size: 9000
- name: "Default_RX_GPU"
kind: "device"
affinity: 0
access:
- local
num_bufs: 51200
buf_size: 9000
- name: "Data_RX_GPU"
kind: "device"
affinity: 0
Expand All @@ -57,7 +50,7 @@ advanced_network:
interfaces:
- name: data1
address: 0000:ca:00.0
flow_isolation: false
flow_isolation: true
tx:
- queues:
- name: "ADC Samples"
Expand All @@ -70,15 +63,8 @@ advanced_network:
- "tx_eth_src"
rx:
- queues:
- name: "Default"
id: 0
cpu_core: 10
batch_size: 10240
output_port: "bench_rx_out"
memory_regions:
- "Default_RX_GPU"
- name: "Data"
id: 1
id: 0
cpu_core: 10
batch_size: 10240
output_port: "bench_rx_out"
Expand All @@ -88,7 +74,7 @@ advanced_network:
- name: "ADC Samples"
action:
type: queue
id: 1
id: 0
match:
udp_src: 4096 #12288
udp_dst: 4096 #12288
Expand Down
9 changes: 0 additions & 9 deletions applications/adv_networking_bench/cpp/default_bench_op_rx.h
Original file line number Diff line number Diff line change
Expand Up @@ -184,15 +184,6 @@ class AdvNetworkingBenchDefaultRxOp : public Operator {

auto burst_size = adv_net_get_num_pkts(burst);

// If packets are coming in from our non-GPUDirect queue, free them and move on
// hardcoded to match the YAML config files in this sample app.
// NOTE: we can't actually ignore all standard linux packets on a real network (with a switch),
// at least ARP packets should be processed, or delegate to linux for standard traffic.
if (adv_net_get_q_id(burst) == 0) {
adv_net_free_all_pkts_and_burst(burst);
return;
}

// Count packets received
ttl_pkts_recv_ += burst_size;

Expand Down
9 changes: 0 additions & 9 deletions applications/adv_networking_bench/cpp/doca_bench_op_rx.h
Original file line number Diff line number Diff line change
Expand Up @@ -115,15 +115,6 @@ class AdvNetworkingBenchDocaRxOp : public Operator {
}
auto burst = burst_opt.value();

// If packets are coming in from our default (non-data) queue, free them and move on. This is
// hardcoded to match the YAML config files in this sample app.
// NOTE: we can't actually ignore all standard linux packets on a real network (with a switch),
// at least ARP packets should be processed, or delegate to linux for standard traffic.
if (adv_net_get_q_id(burst) == 0) {
HOLOSCAN_LOG_DEBUG("Ignoring packets on queue 0");
return;
}

// Count packets received
ttl_pkts_recv_ += adv_net_get_num_pkts(burst);

Expand Down

0 comments on commit a30a331

Please sign in to comment.