From: Sergey Balabanov <balabanovsv@ecotelecom.ru>
To: dev@dpdk.org
Subject: Re: [dpdk-dev] [PATCH] mbuf: fix incompatibility with C++ in header file
Date: Fri, 14 Aug 2015 11:59:40 +0300 [thread overview]
Message-ID: <3166223.tPyzP6C51N@stand> (raw)
In-Reply-To: <1439541195-26630-1-git-send-email-avi@cloudius-systems.com>
The patch duplicates http://dpdk.org/dev/patchwork/patch/6750/
On Friday 14 August 2015 11:33:15 Avi Kivity wrote:
> C++ doesn't allow implied casting from void * to another pointer, so
> supply an explicit cast.
>
> Signed-off-by: Avi Kivity <avi@cloudius-systems.com>
> ---
> lib/librte_mbuf/rte_mbuf.h | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/lib/librte_mbuf/rte_mbuf.h b/lib/librte_mbuf/rte_mbuf.h
> index c3b8c98..8c2db1b 100644
> --- a/lib/librte_mbuf/rte_mbuf.h
> +++ b/lib/librte_mbuf/rte_mbuf.h
> @@ -882,7 +882,7 @@ static inline uint16_t rte_pktmbuf_priv_size(struct
> rte_mempool *mp); static inline struct rte_mbuf *
> rte_mbuf_from_indirect(struct rte_mbuf *mi)
> {
> - return RTE_PTR_SUB(mi->buf_addr, sizeof(*mi) + mi->priv_size);
> + return (struct rte_mbuf *)RTE_PTR_SUB(mi->buf_addr, sizeof(*mi) +
> mi->priv_size); }
>
> /**
prev parent reply other threads:[~2015-08-14 8:59 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-08-14 8:33 Avi Kivity
2015-08-14 8:59 ` Sergey Balabanov [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=3166223.tPyzP6C51N@stand \
--to=balabanovsv@ecotelecom.ru \
--cc=dev@dpdk.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).