DPDK patches and discussions
 help / color / mirror / Atom feed
From: "Rohit Saini (Stellus)" <rohit.saini@stellus.com>
To: "'dev@dpdk.org'" <dev@dpdk.org>
Subject: [dpdk-dev] Use rte_malloc  in application
Date: Thu, 03 Aug 2017 05:57:46 +0000	[thread overview]
Message-ID: <ef1a0bcc9f954e31877f638751cab1a5@stellus.com> (raw)
In-Reply-To: <CGME20170803055747uscas1p15fd0c2a998cf260734f89cc48192a61c@uscas1p1.samsung.com>

Hi,
I have a use case in my application where I need to implement my own memory manager, rather than doing malloc/free everytime to kernel.
Instead of writing my own memory manager, I am thinking to use dpdk rte_malloc or rte_mempool. Please let me know if this is a good idea.

Also,

my_node_t *data_ptr = (my_node_t *) (uintptr_t) rte_malloc(NULL, sizeof(my_node_t), 0);

data_ptr is pointing to some invalid memory.  Am I doing anything wrong here?


Thanks,
Rohit

       reply	other threads:[~2017-08-03  5:57 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <CGME20170803055747uscas1p15fd0c2a998cf260734f89cc48192a61c@uscas1p1.samsung.com>
2017-08-03  5:57 ` Rohit Saini (Stellus) [this message]
2017-08-03  6:12   ` Rohit Saini (Stellus)
2017-08-03  8:29     ` Sergio Gonzalez Monroy
2017-08-10 11:19       ` Rohit Saini (Stellus)
2017-08-03 13:29     ` Stefan Puiu

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=ef1a0bcc9f954e31877f638751cab1a5@stellus.com \
    --to=rohit.saini@stellus.com \
    --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).