eal: remove use of register keyword

The 'register' keyword does nothing, and has been removed in C++17.

Remove it for compatibility.

Signed-off-by: Avi Kivity <avi@scylladb.com>
This commit is contained in:
Avi Kivity 2018-01-09 18:11:08 +02:00 committed by Thomas Monjalon
parent 7eafccfa9d
commit 0d5f2ed12f
2 changed files with 3 additions and 3 deletions

View File

@ -50,7 +50,7 @@ extern "C" {
static inline uint16_t rte_arch_bswap16(uint16_t _x)
{
register uint16_t x = _x;
uint16_t x = _x;
asm volatile ("rev16 %w0,%w1"
: "=r" (x)

View File

@ -24,7 +24,7 @@ extern "C" {
*/
static inline uint16_t rte_arch_bswap16(uint16_t _x)
{
register uint16_t x = _x;
uint16_t x = _x;
asm volatile ("xchgb %b[x1],%h[x2]"
: [x1] "=Q" (x)
: [x2] "0" (x)
@ -39,7 +39,7 @@ static inline uint16_t rte_arch_bswap16(uint16_t _x)
*/
static inline uint32_t rte_arch_bswap32(uint32_t _x)
{
register uint32_t x = _x;
uint32_t x = _x;
asm volatile ("bswap %[x]"
: [x] "+r" (x)
);