DPDK patches and discussions
 help / color / mirror / Atom feed
From: Thomas Monjalon <thomas@monjalon.net>
To: AndyPei <andy.pei@intel.com>
Cc: dev@dpdk.org, rosen.xu@intel.com, tianfei.zhang@intel.com
Subject: Re: [dpdk-dev] [PATCH v3]/driver/raw/ifpga_rawdev: fix a memory leak bug in ifpga
Date: Tue, 15 Jan 2019 01:03:36 +0100	[thread overview]
Message-ID: <2005571.rmhIWEJz30@xps> (raw)
In-Reply-To: <1545746524-116580-1-git-send-email-andy.pei@intel.com>

Hi Andy,

I comment here for all your patches (4 are pending).
They are your first patches for DPDK, welcome!
You may want to read the guides explaining how to contribute:
	http://doc.dpdk.org/guides/contributing/patches.html

The title should be "raw/ifpga: fix memory leak in [area here]"

25/12/2018 15:02, AndyPei:
> When ifpga_rawdev_create() allocate memory for a new rawdev, the original code
> allocate redundant memory for adapter, which is a member of the rawdev.
> What is actually necessary is the adapter to be initialized, not memory allocated.
> 
> What is different in v3 from v2 is that the adapter is no longer need to be freed.

The changelog is better located after --- below.

> fixes:ef1e8ede3da5
> cc: rosen.xu@intel.com
> cc: tianfei.zhang@intel.com

The format should be a bit different.
Please use git log -1 --abbrev=12 --format='Fixes: %h (\"%s\")%nCc: %ae'
and check with devtools/check-git-log.sh

> Signed-off-by: AndyPei <andy.pei@intel.com>

Should there be a space in your name as "Andy Pei"?

[...]
>  /**
> - * opae_adapter_data_alloc - alloc opae_adapter_data data structure
> + * opae_adapter_init - init opae_adapter data structure
> + * @adpdate: pointer of opae_adater data structure
> + * @name: adapter name.
> + * @data: private data of this adapter.

The doxygen format is @param param_name param_description.
It is also important to strictly match the name of the parameter.
@adpdate is a typo (should be @param adapter).

You can build the doc with "make doc-api-html"
and check the result in your browser.

> + *
> + * Return: 0 on success.
> + */
> +int opae_adapter_init(struct opae_adapter *adapter,
> +		const char *name, void *data)

  parent reply	other threads:[~2019-01-15  0:03 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-12-13 18:33 [dpdk-dev] [PATCH] Fix a memnory leak bug due to malloc unproperly AndyPei
2018-12-13 14:32 ` Burakov, Anatoly
2018-12-18  7:16 ` Xu, Rosen
2018-12-18 19:35 ` [dpdk-dev] [PATCH v2]/driver/raw/ifpga_rawdev: fix a memory leak bug in ifpga AndyPei
2018-12-19  7:16   ` Xu, Rosen
2018-12-19  8:42     ` Pei, Andy
2018-12-25 14:02   ` [dpdk-dev] [PATCH v3]/driver/raw/ifpga_rawdev: " AndyPei
2019-01-02  2:47     ` Zhang, Tianfei
2019-01-02  6:52     ` Xu, Rosen
2019-01-15  0:03     ` Thomas Monjalon [this message]
2019-01-15  5:38     ` [dpdk-dev] [DPDK] [PATCH v4] raw/ifpga: fix a typo and delete code of unused function Andy Pei
2019-01-16 11:26       ` Xu, Rosen
2019-01-17  5:26       ` [dpdk-dev] [DPDK] " Andy Pei
2019-01-17  5:36         ` Ye Xiaolong
2019-01-17  6:39         ` [dpdk-dev] [DPDK] raw/ifpga: fix a typo Andy Pei
2019-01-17  8:39           ` Xu, Rosen

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=2005571.rmhIWEJz30@xps \
    --to=thomas@monjalon.net \
    --cc=andy.pei@intel.com \
    --cc=dev@dpdk.org \
    --cc=rosen.xu@intel.com \
    --cc=tianfei.zhang@intel.com \
    /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).