lkml.org 
[lkml]   [2018]   [Oct]   [13]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
SubjectRE: [PATCH net-next, v2] hv_netvsc: fix vf serial matching with pci slot info
Date


> -----Original Message-----
> From: Stephen Hemminger <stephen@networkplumber.org>
> Sent: Friday, October 12, 2018 6:21 PM
> To: Haiyang Zhang <haiyangz@linuxonhyperv.com>
> Cc: Haiyang Zhang <haiyangz@microsoft.com>; davem@davemloft.net;
> netdev@vger.kernel.org; olaf@aepfle.de; linux-kernel@vger.kernel.org;
> devel@linuxdriverproject.org; vkuznets <vkuznets@redhat.com>
> Subject: Re: [PATCH net-next, v2] hv_netvsc: fix vf serial matching with pci slot
> info
>
> On Fri, 12 Oct 2018 20:55:15 +0000
> Haiyang Zhang <haiyangz@linuxonhyperv.com> wrote:
>
> Thanks for fixing this.
>
>
> > + if (kstrtou32(kobject_name(&pdev->slot->kobj), 10, &serial)) {
> > + netdev_notice(vf_netdev, "Invalid vf serial:%s\n",
> > + pdev->slot->kobj.name);
> > + return NULL;
> > + }
>
> Shouldn't this use kobject_name() in the message as well.
>
> Looking at the pci.h code there is already an API to get name from slot (it uses
> kobject_name()). So please use that one.

Sure, I will look for that api. Thanks.

\
 
 \ /
  Last update: 2018-10-13 00:28    [from the cache]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and my Meterkast|Read the blog