<div>Great! Thanks for the quick feedback.</div><div><div><br></div><div><br></div><div style="font-size: 12px;font-family: Arial Narrow;padding:2px 0 2px 0;">------------------ Original ------------------</div><div style="font-size: 12px;background:#efefef;padding:8px;"><div><b>From: </b> "Olivier MATZ"<olivier.matz@6wind.com>;</div><div><b>Date: </b> Wed, Jun 12, 2013 05:17 PM</div><div><b>To: </b> "dev"<dev@dpdk.org>; <wbr></div><div><b>Cc: </b> "lxu"<lxu4net@qq.com>; <wbr></div><div><b>Subject: </b> Re: [dpdk-dev] Can the empty struct rte_eth_txmode be enhanced?</div></div><div><br></div>Hello,<br><br>> Can we change the struct rte_eth_txmode ?<br>><br>> Such as :<br>><br>> struct rte_eth_txmode { int reserve[]; };   /* sizeof(struct rte_eth_txmode) == 0 in gcc and g++ */<br><br>I agree with your solution. Do you approve the following patch ?<br><br>From: lxu <lxu4net@qq.com><br>Date: Wed, 12 Jun 2013 09:32:30 +0200<br>Subject: [PATCH] ethdev: force the size of struct rte_eth_txmode to be 0<br><br>The size of an empty structure is 0 when compiling with gcc, and 1 when<br>compiling with g++. Adding an empty table forces the size fo be 0, in C<br>or C++.<br><br>Acked-by: Olivier Matz <olivier.matz@6wind.com><br>Signed-off-by: lxu <lxu4net@qq.com><br>---<br>  lib/librte_ether/rte_ethdev.h |    1 +<br>  1 file changed, 1 insertion(+)<br><br>diff --git a/lib/librte_ether/rte_ethdev.h b/lib/librte_ether/rte_ethdev.h<br>index 5985496..e0a1ccf 100644<br>--- a/lib/librte_ether/rte_ethdev.h<br>+++ b/lib/librte_ether/rte_ethdev.h<br>@@ -320,6 +320,7 @@ struct rte_eth_vmdq_dcb_conf {<br>   * For future extensions.<br>   */<br>  struct rte_eth_txmode {<br>+       int reserved[]; /* force the size of struct to be 0 */<br>  };<br><br>  /**<br>-- <br>1.7.10.4<br><br></div>