Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Insufficient memory allocation for default Gateway #26

Closed
nithinn opened this issue Mar 7, 2017 · 1 comment
Closed

Insufficient memory allocation for default Gateway #26

nithinn opened this issue Mar 7, 2017 · 1 comment
Assignees
Labels
Milestone

Comments

@nithinn
Copy link

nithinn commented Mar 7, 2017

In function route_init(), the variable 'default_gw_per_port' is allocated for one instance'. This cause invalid memory access when multiple ports are used for traffic generation:
For e.g. in function route_v4_nh_lookup() where default_gw_per_port is accessed like this -> default_gw_per_port[port].re_nh.ip_v4;

default_gw_per_port = rte_zmalloc("default_gw_per_port",
                                      sizeof(*default_gw_per_port),
                                      0);

This should be

default_gw_per_port = rte_zmalloc("default_gw_per_port",
                                     rte_eth_dev_count() * sizeof(*default_gw_per_port),
                                      0);
@dceara dceara self-assigned this Mar 7, 2017
@dceara dceara added this to the 1.5 milestone Mar 7, 2017
@dceara dceara assigned davvore33 and unassigned dceara Apr 3, 2017
@dceara
Copy link
Collaborator

dceara commented Apr 18, 2017

Fixed with commit a558103

Will be available in v1.5

@dceara dceara closed this as completed Apr 18, 2017
@dceara dceara added the bug label Jun 14, 2017
chandrasheker pushed a commit to chandrasheker/warp17 that referenced this issue Sep 14, 2017
Issue: Juniper#26

Performance results:
2017-04-05 13:39:17,728 - TestPerf - INFO - Test test_1_4M_tcp_sess_setup_rate
2017-04-05 13:40:19,222 - TestPerf - INFO - Average Rate 3408606
2017-04-05 13:40:19,222 - TestPerf - INFO - Test test_2_8M_tcp_sess_setup_rate
2017-04-05 13:41:55,100 - TestPerf - INFO - Average Rate 3403477
2017-04-05 13:41:55,101 - TestPerf - INFO - Test test_3_10M_tcp_sess_setup_rate
2017-04-05 13:43:51,065 - TestPerf - INFO - Average Rate 3402288
2017-04-05 13:43:51,065 - TestPerf - INFO - Test test_4_4M_tcp_sess_data_10b_setup_rate
2017-04-05 13:45:00,506 - TestPerf - INFO - Average Rate 1792689
2017-04-05 13:45:00,506 - TestPerf - INFO - Test test_5_4M_tcp_sess_data_1024b_setup_rate
2017-04-05 13:46:10,007 - TestPerf - INFO - Average Rate 1771107
2017-04-05 13:46:10,008 - TestPerf - INFO - Test test_6_4M_tcp_sess_data_1300b_setup_rate
2017-04-05 13:47:19,525 - TestPerf - INFO - Average Rate 1911806
2017-04-05 13:47:19,525 - TestPerf - INFO - Test test_7_4M_udp_sess_data_10b_setup_rate
2017-04-05 13:48:12,542 - TestPerf - INFO - Average Rate 7204948
2017-04-05 13:48:12,542 - TestPerf - INFO - Test test_8_4M_http_sess_data_10b_setup_rate
2017-04-05 13:49:21,709 - TestPerf - INFO - Average Rate 1756078
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants