#
c10a2bf3 |
| 03-Oct-2023 |
Stephen Hemminger <stephen@networkplumber.org> |
test/cmdline: remove some MAC address strings
Some of the Ethernet address formats which were invalid will now become valid inputs when rte_ether_unformat_addr is modified to allow leading zeros.
A
test/cmdline: remove some MAC address strings
Some of the Ethernet address formats which were invalid will now become valid inputs when rte_ether_unformat_addr is modified to allow leading zeros.
Also, make local variables static.
Signed-off-by: Stephen Hemminger <stephen@networkplumber.org> Acked-by: Morten Brørup <mb@smartsharesystems.com> Acked-by: Ferruh Yigit <ferruh.yigit@amd.com>
show more ...
|
#
71bdd8a1 |
| 24-Jan-2020 |
Pavan Nikhilesh <pbhagavatula@marvell.com> |
app: use common macro RTE_DIM
Use RTE_DIM macro to calculate array size.
Suggested-by: David Marchand <david.marchand@redhat.com> Signed-off-by: Pavan Nikhilesh <pbhagavatula@marvell.com> Acked-by:
app: use common macro RTE_DIM
Use RTE_DIM macro to calculate array size.
Suggested-by: David Marchand <david.marchand@redhat.com> Signed-off-by: Pavan Nikhilesh <pbhagavatula@marvell.com> Acked-by: David Marchand <david.marchand@redhat.com>
show more ...
|
#
35b2d13f |
| 21-May-2019 |
Olivier Matz <olivier.matz@6wind.com> |
net: add rte prefix to ether defines
Add 'RTE_' prefix to defines: - rename ETHER_ADDR_LEN as RTE_ETHER_ADDR_LEN. - rename ETHER_TYPE_LEN as RTE_ETHER_TYPE_LEN. - rename ETHER_CRC_LEN as RTE_ETHER_C
net: add rte prefix to ether defines
Add 'RTE_' prefix to defines: - rename ETHER_ADDR_LEN as RTE_ETHER_ADDR_LEN. - rename ETHER_TYPE_LEN as RTE_ETHER_TYPE_LEN. - rename ETHER_CRC_LEN as RTE_ETHER_CRC_LEN. - rename ETHER_HDR_LEN as RTE_ETHER_HDR_LEN. - rename ETHER_MIN_LEN as RTE_ETHER_MIN_LEN. - rename ETHER_MAX_LEN as RTE_ETHER_MAX_LEN. - rename ETHER_MTU as RTE_ETHER_MTU. - rename ETHER_MAX_VLAN_FRAME_LEN as RTE_ETHER_MAX_VLAN_FRAME_LEN. - rename ETHER_MAX_VLAN_ID as RTE_ETHER_MAX_VLAN_ID. - rename ETHER_MAX_JUMBO_FRAME_LEN as RTE_ETHER_MAX_JUMBO_FRAME_LEN. - rename ETHER_MIN_MTU as RTE_ETHER_MIN_MTU. - rename ETHER_LOCAL_ADMIN_ADDR as RTE_ETHER_LOCAL_ADMIN_ADDR. - rename ETHER_GROUP_ADDR as RTE_ETHER_GROUP_ADDR. - rename ETHER_TYPE_IPv4 as RTE_ETHER_TYPE_IPv4. - rename ETHER_TYPE_IPv6 as RTE_ETHER_TYPE_IPv6. - rename ETHER_TYPE_ARP as RTE_ETHER_TYPE_ARP. - rename ETHER_TYPE_VLAN as RTE_ETHER_TYPE_VLAN. - rename ETHER_TYPE_RARP as RTE_ETHER_TYPE_RARP. - rename ETHER_TYPE_QINQ as RTE_ETHER_TYPE_QINQ. - rename ETHER_TYPE_ETAG as RTE_ETHER_TYPE_ETAG. - rename ETHER_TYPE_1588 as RTE_ETHER_TYPE_1588. - rename ETHER_TYPE_SLOW as RTE_ETHER_TYPE_SLOW. - rename ETHER_TYPE_TEB as RTE_ETHER_TYPE_TEB. - rename ETHER_TYPE_LLDP as RTE_ETHER_TYPE_LLDP. - rename ETHER_TYPE_MPLS as RTE_ETHER_TYPE_MPLS. - rename ETHER_TYPE_MPLSM as RTE_ETHER_TYPE_MPLSM. - rename ETHER_VXLAN_HLEN as RTE_ETHER_VXLAN_HLEN. - rename ETHER_ADDR_FMT_SIZE as RTE_ETHER_ADDR_FMT_SIZE. - rename VXLAN_GPE_TYPE_IPV4 as RTE_VXLAN_GPE_TYPE_IPV4. - rename VXLAN_GPE_TYPE_IPV6 as RTE_VXLAN_GPE_TYPE_IPV6. - rename VXLAN_GPE_TYPE_ETH as RTE_VXLAN_GPE_TYPE_ETH. - rename VXLAN_GPE_TYPE_NSH as RTE_VXLAN_GPE_TYPE_NSH. - rename VXLAN_GPE_TYPE_MPLS as RTE_VXLAN_GPE_TYPE_MPLS. - rename VXLAN_GPE_TYPE_GBP as RTE_VXLAN_GPE_TYPE_GBP. - rename VXLAN_GPE_TYPE_VBNG as RTE_VXLAN_GPE_TYPE_VBNG. - rename ETHER_VXLAN_GPE_HLEN as RTE_ETHER_VXLAN_GPE_HLEN.
Do not update the command line library to avoid adding a dependency to librte_net.
Signed-off-by: Olivier Matz <olivier.matz@6wind.com> Reviewed-by: Stephen Hemminger <stephen@networkplumber.org> Reviewed-by: Maxime Coquelin <maxime.coquelin@redhat.com> Reviewed-by: Ferruh Yigit <ferruh.yigit@intel.com>
show more ...
|
#
6d13ea8e |
| 21-May-2019 |
Olivier Matz <olivier.matz@6wind.com> |
net: add rte prefix to ether structures
Add 'rte_' prefix to structures: - rename struct ether_addr as struct rte_ether_addr. - rename struct ether_hdr as struct rte_ether_hdr. - rename struct vlan_
net: add rte prefix to ether structures
Add 'rte_' prefix to structures: - rename struct ether_addr as struct rte_ether_addr. - rename struct ether_hdr as struct rte_ether_hdr. - rename struct vlan_hdr as struct rte_vlan_hdr. - rename struct vxlan_hdr as struct rte_vxlan_hdr. - rename struct vxlan_gpe_hdr as struct rte_vxlan_gpe_hdr.
Do not update the command line library to avoid adding a dependency to librte_net.
Signed-off-by: Olivier Matz <olivier.matz@6wind.com> Reviewed-by: Stephen Hemminger <stephen@networkplumber.org> Reviewed-by: Maxime Coquelin <maxime.coquelin@redhat.com> Reviewed-by: Ferruh Yigit <ferruh.yigit@intel.com>
show more ...
|
#
f9acaf84 |
| 03-Apr-2019 |
Bruce Richardson <bruce.richardson@intel.com> |
replace snprintf with strlcpy without adding extra include
For files that already have rte_string_fns.h included in them, we can do a straight replacement of snprintf(..."%s",...) with strlcpy. The
replace snprintf with strlcpy without adding extra include
For files that already have rte_string_fns.h included in them, we can do a straight replacement of snprintf(..."%s",...) with strlcpy. The changes in this patch were auto-generated via command:
spatch --sp-file devtools/cocci/strlcpy-with-header.cocci --dir . --in-place
Signed-off-by: Bruce Richardson <bruce.richardson@intel.com>
show more ...
|
#
a9de470c |
| 26-Feb-2019 |
Bruce Richardson <bruce.richardson@intel.com> |
test: move to app directory
Since all other apps have been moved to the "app" folder, the autotest app remains alone in the test folder. Rather than having an entire top-level folder for this, we ca
test: move to app directory
Since all other apps have been moved to the "app" folder, the autotest app remains alone in the test folder. Rather than having an entire top-level folder for this, we can move it back to where it all started in early versions of DPDK - the "app/" folder.
This move has a couple of advantages: * This reduces clutter at the top level of the project, due to one less folder. * It eliminates the separate build task necessary for building the autotests using make "make test-build" which means that developers are less likely to miss something in their own compilation tests * It re-aligns the final location of the test binary in the app folder when building with make with it's location in the source tree.
For meson builds, the autotest app is different from the other apps in that it needs a series of different test cases defined for it for use by "meson test". Therefore, it does not get built as part of the main loop in the app folder, but gets built separately at the end.
Signed-off-by: Bruce Richardson <bruce.richardson@intel.com>
show more ...
|
#
7d3b1ec4 |
| 16-Feb-2017 |
Ferruh Yigit <ferruh.yigit@intel.com> |
test: move unit tests to separate directory
This is to logically group unit tests into their own folder, separating them from "app" folder.
Hopefully this will make the unit test in DPDK more visib
test: move unit tests to separate directory
This is to logically group unit tests into their own folder, separating them from "app" folder.
Hopefully this will make the unit test in DPDK more visible.
Following binaries moved to "test" folder: cmdline-test test-acl test-pipeline test <-- various DPDK unit tests
Signed-off-by: Ferruh Yigit <ferruh.yigit@intel.com> Acked-by: Bruce Richardson <bruce.richardson@intel.com>
show more ...
|
#
aaa662e7 |
| 05-Dec-2014 |
Alan Carew <alan.carew@intel.com> |
cmdline: fix overflow on bsd
When using test-pmd with flow director in FreeBSD, the application will segfault/Bus error while parsing the command-line. This is due to how each commands result struct
cmdline: fix overflow on bsd
When using test-pmd with flow director in FreeBSD, the application will segfault/Bus error while parsing the command-line. This is due to how each commands result structure is represented during parsing, where the offsets for each tokens value is stored in a character array(char result_buf[BUFSIZ]) in cmdline_parse()(./lib/librte_cmdline/cmdline_parse.c).
The overflow occurs where BUFSIZ is less than the size of a commands result structure, in this case "struct cmd_pkt_filter_result" (app/test-pmd/cmdline.c) is 1088 bytes and BUFSIZ on FreeBSD is 1024 bytes as opposed to 8192 bytes on Linux.
The problem can be reproduced by running test-pmd on FreeBSD: ./testpmd -c 0x3 -n 4 -- -i --portmask=0x3 --pkt-filter-mode=perfect And adding a filter: add_perfect_filter 0 udp src 192.168.0.0 1024 dst 192.168.0.0 1024 flexbytes 0x800 vlan 0 queue 0 soft 0x17
This patch removes the OS dependency on BUFSIZ and defines and uses a library #define CMDLINE_PARSE_RESULT_BUFSIZE 8192
Added boundary checking to ensure this buffer size cannot overflow, with an error message being produced.
Suggested-by: Olivier Matz <olivier.matz@6wind.com> http://git.droids-corp.org/?p=libcmdline.git;a=commitdiff;h=b1d5b169352e57df3fc14c51ffad4b83f3e5613f
Signed-off-by: Alan Carew <alan.carew@intel.com> Signed-off-by: Olivier Matz <olivier.matz@6wind.com> Tested-by: Bruce Richardson <bruce.richardson@intel.com>
show more ...
|
#
8d964538 |
| 30-Jun-2014 |
Pablo de Lara <pablo.de.lara.guarch@intel.com> |
app/test: remove writes in NULL buffer from cmdline tests
Cmdline unit test calls several functions that use snprintf, with NULL pointer as the destination buffer. This patch eliminates these NULL p
app/test: remove writes in NULL buffer from cmdline tests
Cmdline unit test calls several functions that use snprintf, with NULL pointer as the destination buffer. This patch eliminates these NULL pointer tests.
Signed-off-by: Pablo de Lara <pablo.de.lara.guarch@intel.com> Acked-by: Olivier Matz <olivier.matz@6wind.com> Tested-by: Waterman Cao <waterman.cao@intel.com>
show more ...
|
#
6f41fe75 |
| 24-Jun-2014 |
Stephen Hemminger <stephen@networkplumber.org> |
eal: deprecate rte_snprintf
The function rte_snprintf serves no useful purpose. It is the same as snprintf() for all valid inputs. Deprecate it and replace all uses in current code.
Leave the tests
eal: deprecate rte_snprintf
The function rte_snprintf serves no useful purpose. It is the same as snprintf() for all valid inputs. Deprecate it and replace all uses in current code.
Leave the tests for the deprecated function in place.
Signed-off-by: Stephen Hemminger <stephen@networkplumber.org> Acked-by: Thomas Monjalon <thomas.monjalon@6wind.com>
show more ...
|
#
e8ed6c78 |
| 20-Jun-2014 |
Bruce Richardson <bruce.richardson@intel.com> |
eal: fix usage of printf-like functions
Mark the rte_log, cmdline_printf and rte_snprintf functions as being printf-style functions. This causes compilation errors due to mis-matched parameter types
eal: fix usage of printf-like functions
Mark the rte_log, cmdline_printf and rte_snprintf functions as being printf-style functions. This causes compilation errors due to mis-matched parameter types, so the parameter types are fixed where appropriate.
Signed-off-by: Bruce Richardson <bruce.richardson@intel.com> Acked-by: Thomas Monjalon <thomas.monjalon@6wind.com>
show more ...
|
#
3031749c |
| 03-Jun-2014 |
Bruce Richardson <bruce.richardson@intel.com> |
remove trailing whitespaces
This commit removes trailing whitespace from lines in files. Almost all files are affected, as the BSD license copyright header had trailing whitespace on 4 lines in it [
remove trailing whitespaces
This commit removes trailing whitespace from lines in files. Almost all files are affected, as the BSD license copyright header had trailing whitespace on 4 lines in it [hence the number of files reporting 8 lines changed in the diffstat].
Signed-off-by: Bruce Richardson <bruce.richardson@intel.com> Acked-by: Neil Horman <nhorman@tuxdriver.com> [Thomas: remove spaces before tabs in libs] [Thomas: remove more trailing spaces in non-C files] Signed-off-by: Thomas Monjalon <thomas.monjalon@6wind.com>
show more ...
|
#
e9d48c00 |
| 10-Feb-2014 |
Bruce Richardson <bruce.richardson@intel.com> |
update Intel copyright years to 2014
Signed-off-by: Bruce Richardson <bruce.richardson@intel.com>
|
#
1c1d4d7a |
| 18-Sep-2013 |
Intel <intel.com> |
doc: whitespace changes in licenses
Signed-off-by: Intel
|
#
b6df9fc8 |
| 12-Mar-2013 |
Intel <intel.com> |
update copyright date to 2013
Signed-off-by: Intel
|
#
dbb860e0 |
| 19-Dec-2012 |
Intel <intel.com> |
cmdline: tests
Signed-off-by: Intel
|