[dpdk-dev] [PATCH v4 1/2] ethdev: remove get_reg_length callback

2016-06-23 Thread z...@semihalf.com
From: Zyta Szpak Version 4 of fixing the assumption of that device registers are always 32 bits long. rte_eth_dev_get_reg_length and rte_eth_dev_get_reg_info callbacks did not provide register size to the app in any way. It is needed to allocate proper number of bytes before retrieving registers

[dpdk-dev] [PATCH v4 2/2] examples/ethtool: use rte_eth_dev_get_reg_info for reg params

2016-06-23 Thread z...@semihalf.com
From: Zyta Szpak Version 4 of fixing the fixed register width assumption. The app was allocating too little space for 64-bit registers which resulted in memory corruption. This commit resolves this by getting the number of registers and size of register by rte_eth_dev_get_reg_info function called

[dpdk-dev] [PATCH v3 1/2] ethdev: add callback to get register size in bytes

2016-06-01 Thread z...@semihalf.com
From: Zyta Szpak Version 2 of fixing the fixed register width assumption. rte_eth_dev_get_reg_length and rte_eth_dev_get_reg callbacks do not provide register size to the app in any way. It is needed to allocate proper number of bytes before retrieving registers content with rte_eth_dev_get_reg.

[dpdk-dev] [PATCH v3 2/2] examples/ethtool: get reg width to allocate memory

2016-06-01 Thread z...@semihalf.com
From: Zyta Szpak Version 2 of fixing the fixed register width assumption. Not every device uses 32-bit wide register. The app was allocating too little space for 64-bit registers which resulted in memory corruption. This commit resolves this by getting the size of register in bytes for a specific

[dpdk-dev] [PATCH] examples/ethtool: include case for 64-bit registers

2016-05-11 Thread z...@semihalf.com
From: Zyta Szpak rte_eth_dev_get_reg_length and rte_eth_dev_get_reg callbacks do not provide register size to the app in any way. Example assuming they are 32-bit wide always allocates not enough memory if the registers are 64-bit wide. It results in memory corruption. This commit is a quick fix

[dpdk-dev] [PATCH 1/2] ethdev: add callback to get register size in bytes

2016-05-25 Thread z...@semihalf.com
From: Zyta Szpak Version 2 of fixing the fixed register width assumption. rte_eth_dev_get_reg_length and rte_eth_dev_get_reg callbacks do not provide register size to the app in any way. It is needed to allocate proper number of bytes before retrieving registers content with rte_eth_dev_get_reg.

[dpdk-dev] [PATCH 2/2] examples/ethtool: get reg width to allocate memory

2016-05-25 Thread z...@semihalf.com
From: Zyta Szpak Version 2 of fixing the fixed register width assumption. Not every device uses 32-bit wide register. The app was allocating too little space for 64-bit registers which resulted in memory corruption. This commit resolves this by getting the size of register in bytes for a specific

[dpdk-dev] [PATCH v2 1/2] ethdev: add callback to get register size in bytes

2016-05-30 Thread z...@semihalf.com
From: Zyta Szpak Version 2 of fixing the fixed register width assumption. rte_eth_dev_get_reg_length and rte_eth_dev_get_reg callbacks do not provide register size to the app in any way. It is needed to allocate proper number of bytes before retrieving registers content with rte_eth_dev_get_reg.

[dpdk-dev] [PATCH v2 1/2] ethdev: add callback to get register size in bytes

2016-05-30 Thread z...@semihalf.com
From: Zyta Szpak Version 2 of fixing the fixed register width assumption. rte_eth_dev_get_reg_length and rte_eth_dev_get_reg callbacks do not provide register size to the app in any way. It is needed to allocate proper number of bytes before retrieving registers content with rte_eth_dev_get_reg.

[dpdk-dev] [PATCH v2 2/2] examples/ethtool: get reg width to allocate memory

2016-05-30 Thread z...@semihalf.com
From: Zyta Szpak Version 2 of fixing the fixed register width assumption. Not every device uses 32-bit wide register. The app was allocating too little space for 64-bit registers which resulted in memory corruption. This commit resolves this by getting the size of register in bytes for a specific