From: Ferruh Yigit <ferruh.yigit@intel.com>
To: Remy Horton <remy.horton@intel.com>
Cc: dev@dpdk.org
Subject: Re: [dpdk-dev] [PATCH 1/3] kcp: add kernel control path kernel module
Date: Thu, 28 Jan 2016 13:50:38 +0000 [thread overview]
Message-ID: <20160128135038.GA24660@sivlogin002.ir.intel.com> (raw)
In-Reply-To: <56A9E43D.5000105@intel.com>
On Thu, Jan 28, 2016 at 09:49:49AM +0000, Remy Horton wrote:
> Comments inline
>
> ..Remy
>
>
> On 27/01/2016 16:24, Ferruh Yigit wrote:
> > This kernel module is based on KNI module, but this one is stripped
> > version of it and only for control messages, no data transfer
> > functionality provided.
> >
> > This Linux kernel module helps userspace application create virtual
> > interfaces and when a control command issued into that virtual
> > interface, module pushes the command to the userspace and gets the
> > response back for the caller application.
> >
> > Signed-off-by: Ferruh Yigit <ferruh.yigit@intel.com>
> > ---
>
>
> > + net_dev = alloc_netdev(sizeof(struct kcp_dev), name,
> > +#ifdef NET_NAME_UNKNOWN
> > + NET_NAME_UNKNOWN,
> > +#endif
> > + kcp_net_init);
>
> Something doesn't feel quite right here. In cases where NET_NAME_UNKNOWN is
> undefined, is the signature for alloc_netdev different?
>
Yes, this is because of API change between kernel versions,
when NET_NAME_* introduced, alloc_netdev() also updated to have this.
>
> > +MODULE_LICENSE("Dual BSD/GPL");
> > +MODULE_AUTHOR("Intel Corporation");
> > +MODULE_DESCRIPTION("Kernel Module for managing kcp devices");
>
> I'm not up to speed on this area, but some of the file headers only mention
> GPL/LGPL. This correct?
>
This is because a header file (rte_kcp_common.h) shared by this kernel module and user-space application is dual licensed (BSD + GPL)
I mimicked this from exiting KNI.
>
> > + nlmsg_unicast(nl_sock, skb, pid);
> > + KCP_DBG("Sent cmd:%d port:%d\n", cmd_id, port_id);
> > +
> > + /*nlmsg_free(skb);*/
> > +
> > + return 0;
> > +}
>
> Oops.. :)
> Possible memory leak, or is *skb statically allocated?
>
No leak, not statically allocated, but taken care by nlmsg_unicast()
But commented code needs to be removed.
Thanks,
ferruh
next prev parent reply other threads:[~2016-01-28 13:50 UTC|newest]
Thread overview: 82+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <1453911849-16562-1-git-send-email-ferruh.yigit@intel.com>
2016-01-27 16:24 ` Ferruh Yigit
2016-01-28 9:49 ` Remy Horton
2016-01-28 13:50 ` Ferruh Yigit [this message]
2016-02-28 15:34 ` Avi Kivity
2016-02-28 20:16 ` Ferruh Yigit
2016-02-29 9:43 ` Avi Kivity
2016-02-29 10:43 ` Ferruh Yigit
2016-02-29 10:58 ` Avi Kivity
2016-02-29 11:06 ` Thomas Monjalon
2016-02-29 11:35 ` Ferruh Yigit
2016-02-29 15:05 ` Ferruh Yigit
2016-02-29 15:19 ` Panu Matilainen
2016-02-29 15:27 ` Thomas Monjalon
2016-02-29 16:04 ` Panu Matilainen
2016-02-29 14:33 ` Jay Rolette
2016-03-01 22:40 ` Bruce Richardson
2016-03-02 2:02 ` Stephen Hemminger
2016-03-02 8:27 ` Panu Matilainen
2016-03-02 10:47 ` Vincent JARDIN
2016-03-02 10:51 ` Jim Thompson
2016-03-02 12:03 ` Vincent JARDIN
2016-03-02 22:51 ` Jim Thompson
2016-03-02 11:21 ` Thomas Monjalon
2016-03-02 22:35 ` Thomas Monjalon
2016-03-03 8:31 ` Panu Matilainen
2016-03-03 10:05 ` Ferruh Yigit
2016-03-03 10:11 ` Thomas Monjalon
2016-03-03 10:51 ` Panu Matilainen
2016-03-10 0:04 ` Thomas Monjalon
2016-03-10 6:31 ` Vincent JARDIN
2016-03-02 22:18 ` Jay Rolette
2016-03-03 10:11 ` Ferruh Yigit
2016-03-03 16:59 ` Stephen Hemminger
2016-03-03 18:18 ` Ferruh Yigit
2016-02-29 11:27 ` Ferruh Yigit
2016-02-29 11:39 ` Avi Kivity
2016-02-29 14:35 ` Ferruh Yigit
2016-02-29 20:11 ` Stephen Hemminger
2016-03-01 0:35 ` Ferruh Yigit
2016-01-27 16:24 ` [dpdk-dev] [PATCH 2/3] rte_ctrl_if: add control interface library Ferruh Yigit
2016-01-28 11:14 ` Remy Horton
2016-01-28 13:15 ` Ferruh Yigit
2016-01-28 13:24 ` Jay Rolette
2016-01-28 13:56 ` Ferruh Yigit
2016-01-28 13:57 ` Ananyev, Konstantin
2016-01-28 14:22 ` Yigit, Ferruh
2016-01-27 16:24 ` [dpdk-dev] [PATCH 3/3] examples/ethtool: add control interface support to the application Ferruh Yigit
2016-02-12 13:45 ` [dpdk-dev] [PATCH v2 0/3] Use common Linux tools to control DPDK ports Ferruh Yigit
2016-02-12 13:45 ` [dpdk-dev] [PATCH v2 1/3] kcp: add kernel control path kernel module Ferruh Yigit
2016-02-12 13:45 ` [dpdk-dev] [PATCH v2 2/3] rte_ctrl_if: add control interface library Ferruh Yigit
2016-02-17 19:58 ` Ananyev, Konstantin
2016-02-18 10:43 ` Yigit, Ferruh
2016-02-12 13:45 ` [dpdk-dev] [PATCH v2 3/3] examples/ethtool: add control interface support to the application Ferruh Yigit
2016-02-17 19:39 ` Ananyev, Konstantin
2016-02-18 10:11 ` Yigit, Ferruh
2016-02-26 14:10 ` [dpdk-dev] [PATCH v3 0/4] Use common Linux tools to control DPDK ports Ferruh Yigit
2016-02-26 14:10 ` [dpdk-dev] [PATCH v3 1/4] lib/librte_ethtool: move librte_ethtool form examples to lib folder Ferruh Yigit
2016-02-26 14:10 ` [dpdk-dev] [PATCH v3 2/4] kcp: add kernel control path kernel module Ferruh Yigit
2016-03-01 1:02 ` Stephen Hemminger
2016-03-01 15:53 ` Ferruh Yigit
2016-02-26 14:10 ` [dpdk-dev] [PATCH v3 3/4] rte_ctrl_if: add control interface library Ferruh Yigit
2016-02-26 14:10 ` [dpdk-dev] [PATCH v3 4/4] examples/ethtool: add control interface support to the application Ferruh Yigit
2016-02-29 9:33 ` [dpdk-dev] [PATCH v3 0/4] Use common Linux tools to control DPDK ports Remy Horton
2016-03-01 15:41 ` [dpdk-dev] [PATCH v4 " Ferruh Yigit
2016-03-01 15:41 ` [dpdk-dev] [PATCH v4 1/4] lib/librte_ethtool: move librte_ethtool form examples to lib folder Ferruh Yigit
2016-03-01 15:41 ` [dpdk-dev] [PATCH v4 2/4] kcp: add kernel control path kernel module Ferruh Yigit
2016-03-01 23:06 ` Stephen Hemminger
2016-03-02 11:05 ` Ferruh Yigit
2016-03-01 23:09 ` Stephen Hemminger
2016-03-01 23:10 ` Stephen Hemminger
2016-03-02 11:06 ` Ferruh Yigit
2016-03-01 15:41 ` [dpdk-dev] [PATCH v4 3/4] rte_ctrl_if: add control interface library Ferruh Yigit
2016-03-01 15:42 ` [dpdk-dev] [PATCH v4 4/4] examples/ethtool: add control interface support to the application Ferruh Yigit
2016-03-09 11:41 ` [dpdk-dev] [PATCH v5 0/4] Use common Linux tools to control DPDK ports Ferruh Yigit
2016-03-09 11:41 ` [dpdk-dev] [PATCH v5 1/4] lib/librte_ethtool: move librte_ethtool form examples to lib folder Ferruh Yigit
2016-03-09 11:41 ` [dpdk-dev] [PATCH v5 2/4] kcp: add kernel control path kernel module Ferruh Yigit
2016-03-09 11:41 ` [dpdk-dev] [PATCH v5 3/4] rte_ctrl_if: add control interface library Ferruh Yigit
2016-03-09 11:41 ` [dpdk-dev] [PATCH v5 4/4] examples/ethtool: add control interface support to the application Ferruh Yigit
2016-03-09 12:23 ` Ananyev, Konstantin
2016-03-14 15:31 ` [dpdk-dev] [PATCH v5 0/4] Use common Linux tools to control DPDK ports Ferruh Yigit
2016-03-14 17:40 ` Jay Rolette
2016-03-15 0:00 ` Ferruh Yigit
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=20160128135038.GA24660@sivlogin002.ir.intel.com \
--to=ferruh.yigit@intel.com \
--cc=dev@dpdk.org \
--cc=remy.horton@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).