Skip to contentSkip to conversation

ivshmem: fix for modified mempool struct

PATCH Applied Ferruh Yigit 3 participants 3 messages Jul 1, 2016

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 ivshmem: fix for modified mempool struct

struct rte_mempool changed its "ring" field to "pool_data"

"ring" field is accessed by ivshmem library, and updated to "pool_data"

This patch fixes the compile error:

== Build lib/librte_ivshmem
CC rte_ivshmem.o
.../lib/librte_ivshmem/rte_ivshmem.c:
In function 'add_mempool_to_metadata':
.../lib/librte_ivshmem/rte_ivshmem.c:584:32:
error: 'const struct rte_mempool' has no member named 'ring'

  return add_ring_to_metadata(mp->ring, config);
                                ^~
Fixes 449c49b93a6b ("mempool: support handler operations")
---
 lib/librte_ivshmem/rte_ivshmem.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
lib/librte_ivshmem/rte_ivshmem.c +1 -1
index 5c83920..c26edb6 100644
@@ -581,7 +581,7 @@ add_mempool_to_metadata(const struct rte_mempool *mp,
 	}
 
 	/* mempool consists of memzone and ring */
-	return add_ring_to_metadata(mp->ring, config);
+	return add_ring_to_metadata(mp->pool_data, config);
 }
 
 int
Signature · 1 line
2.7.4
Acked-by on v1 1/1
#1 lore raw
Quoted 26 lines · Ferruh Yigit

struct rte_mempool changed its "ring" field to "pool_data"

"ring" field is accessed by ivshmem library, and updated to "pool_data"

This patch fixes the compile error:

== Build lib/librte_ivshmem
CC rte_ivshmem.o
.../lib/librte_ivshmem/rte_ivshmem.c:
In function 'add_mempool_to_metadata':
.../lib/librte_ivshmem/rte_ivshmem.c:584:32:
error: 'const struct rte_mempool' has no member named 'ring'

   return add_ring_to_metadata(mp->ring, config);
                                 ^~
Fixes 449c49b93a6b ("mempool: support handler operations")
---
  lib/librte_ivshmem/rte_ivshmem.c | 2 +-
  1 file changed, 1 insertion(+), 1 deletion(-)
lib/librte_ivshmem/rte_ivshmem.c +0 -0
index 5c83920..c26edb6 100644

lib/librte_ivshmem/rte_ivshmem.c add_mempool_to_metadata(const struct rte_mempool *mp, · line 587

Quoted 8 lines
lib/librte_ivshmem/rte_ivshmem.c +1 -1
@@ -581,7 +581,7 @@ add_mempool_to_metadata(const struct rte_mempool *mp,
  	}
 
  	/* mempool consists of memzone and ring */
-	return add_ring_to_metadata(mp->ring, config);
+	return add_ring_to_metadata(mp->pool_data, config);
  }
 
  int
#2 lore raw
In reply to Ferruh Yigit

2016-07-01 17:26, Ferruh Yigit:

Quoted 12 lines

struct rte_mempool changed its "ring" field to "pool_data"

"ring" field is accessed by ivshmem library, and updated to "pool_data"

This patch fixes the compile error:

== Build lib/librte_ivshmem
CC rte_ivshmem.o
.../lib/librte_ivshmem/rte_ivshmem.c:
In function 'add_mempool_to_metadata':
.../lib/librte_ivshmem/rte_ivshmem.c:584:32:
error: 'const struct rte_mempool' has no member named 'ring'

Quoted 5 lines
  return add_ring_to_metadata(mp->ring, config);
                                ^~
Fixes 449c49b93a6b ("mempool: support handler operations")

Applied, thanks