DPDK patches and discussions
 help / color / mirror / Atom feed
From: "Zhang, Helin" <helin.zhang@intel.com>
To: "Padam J. Singh" <padam.singh@inventum.net>
Cc: "dev@dpdk.org" <dev@dpdk.org>
Subject: Re: [dpdk-dev] KNI hw Address.
Date: Thu, 3 Jul 2014 06:22:54 +0000
Message-ID: <F35DEAC7BCE34641BA9FAC6BCA4A12E70A74A155@SHSMSX104.ccr.corp.intel.com> (raw)
In-Reply-To: <AC395003-9317-49E8-81E2-1B39195E7244@inventum.net>



> -----Original Message-----
> From: Padam J. Singh [mailto:padam.singh@inventum.net]
> Sent: Thursday, July 3, 2014 1:06 PM
> To: Zhang, Helin
> Cc: Alex Markuze; dev@dpdk.org
> Subject: Re: [dpdk-dev] KNI hw Address.
> 
> Zhang, Alex,
> 
> Please see the patch I had submitted a few days back which allows setting the
> MAC address using
> 
> ifconfig ... hw ether MAC-ADDRESS
> 
> An "ifconfig DEV up" , followed by this sets the MAC address.
> 
> Thanks,
> Padam
> 
> On 03-Jul-2014, at 10:26 am, Zhang, Helin <helin.zhang@intel.com> wrote:
> 
> >
> >> -----Original Message-----
> >> From: dev [mailto:dev-bounces@dpdk.org] On Behalf Of Alex Markuze
> >> Sent: Wednesday, July 2, 2014 11:57 PM
> >> To: dev@dpdk.org
> >> Subject: [dpdk-dev] KNI hw Address.
> >>
> >> Hi, I'm playing with KNI on a VM (kvm), the Interface that is created
> >> has no MAC address until the IP is set via ifconfig  - then a random mac is
> created.
> >> The VF has a mac address that is easily retrieved with
> rte_eth_macaddr_get.
> >>
> >> What I did not find is a way to create the KNI with that specific mac
> >> address enabled.
> >> What are the ways to set the KNI mac address?
> >>
> >> Thanks
> >> Alex
> >
> > Hi Alex
> >
> > No way without modifying the code. Two ways can be taken into account as
> below.
> >
> > 1. Implement ndo_set_mac in KNI kernel module to set the MAC address.
> > 2. Add mac address as one more parameters in user space KNI interface, to
> tell the kernel module the mac during kni device creation.
> >
> > Regards,
> > Helin

Hi Padam

Great! I think you have implemented the first way I listed. It is good for VM environments. I remember that might be adopted by some projects based on DPDK. Thank you!
I will review your patch, and possibly add reviewed-by: to your patch.

Regards,
Helin

  reply	other threads:[~2014-07-03  6:22 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-07-02 15:57 Alex Markuze
2014-07-03  4:56 ` Zhang, Helin
2014-07-03  5:05   ` Padam J. Singh
2014-07-03  6:22     ` Zhang, Helin [this message]
2014-07-03  7:06       ` Alex Markuze

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=F35DEAC7BCE34641BA9FAC6BCA4A12E70A74A155@SHSMSX104.ccr.corp.intel.com \
    --to=helin.zhang@intel.com \
    --cc=dev@dpdk.org \
    --cc=padam.singh@inventum.net \
    /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

DPDK patches and discussions

This inbox may be cloned and mirrored by anyone:

	git clone --mirror https://inbox.dpdk.org/dev/0 dev/git/0.git

	# If you have public-inbox 1.1+ installed, you may
	# initialize and index your mirror using the following commands:
	public-inbox-init -V2 dev dev/ https://inbox.dpdk.org/dev \
		dev@dpdk.org
	public-inbox-index dev

Example config snippet for mirrors.
Newsgroup available over NNTP:
	nntp://inbox.dpdk.org/inbox.dpdk.dev


AGPL code for this site: git clone https://public-inbox.org/public-inbox.git