* [net-next-2.6 PATCH] enic: fix compile when CONFIG_PCI_IOV is not enabled
@ 2012-01-20 8:25 Roopa Prabhu
2012-01-20 18:40 ` David Miller
2012-01-20 22:49 ` Randy Dunlap
0 siblings, 2 replies; 4+ messages in thread
From: Roopa Prabhu @ 2012-01-20 8:25 UTC (permalink / raw)
To: roprabhu, davem; +Cc: netdev, rdunlap
From: Roopa Prabhu <roprabhu@cisco.com>
reverting back change that access enic->num_vfs outside
CONFIG_PCI_IOV
Reported-by: Randy Dunlap <rdunlap@xenotime.net>
Signed-off-by: Roopa Prabhu <roprabhu@cisco.com>
---
drivers/net/ethernet/cisco/enic/enic_main.c | 4 ++--
1 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/net/ethernet/cisco/enic/enic_main.c b/drivers/net/ethernet/cisco/enic/enic_main.c
index 045c468..ab3f67f 100644
--- a/drivers/net/ethernet/cisco/enic/enic_main.c
+++ b/drivers/net/ethernet/cisco/enic/enic_main.c
@@ -2273,7 +2273,7 @@ static int __devinit enic_probe(struct pci_dev *pdev,
#ifdef CONFIG_PCI_IOV
int pos = 0;
#endif
- int num_pps;
+ int num_pps = 1;
/* Allocate net device structure and initialize. Private
* instance data is initialized to zero.
@@ -2380,11 +2380,11 @@ static int __devinit enic_probe(struct pci_dev *pdev,
goto err_out_vnic_unregister;
}
enic->priv_flags |= ENIC_SRIOV_ENABLED;
+ num_pps = enic->num_vfs;
}
}
#endif
- num_pps = enic->num_vfs ? enic->num_vfs : 1;
/* Allocate structure for port profiles */
enic->pp = kcalloc(num_pps, sizeof(*enic->pp), GFP_KERNEL);
if (!enic->pp) {
^ permalink raw reply related [flat|nested] 4+ messages in thread
* Re: [net-next-2.6 PATCH] enic: fix compile when CONFIG_PCI_IOV is not enabled
2012-01-20 8:25 [net-next-2.6 PATCH] enic: fix compile when CONFIG_PCI_IOV is not enabled Roopa Prabhu
@ 2012-01-20 18:40 ` David Miller
2012-01-21 8:03 ` Roopa Prabhu
2012-01-20 22:49 ` Randy Dunlap
1 sibling, 1 reply; 4+ messages in thread
From: David Miller @ 2012-01-20 18:40 UTC (permalink / raw)
To: roprabhu; +Cc: netdev, rdunlap
From: Roopa Prabhu <roprabhu@cisco.com>
Date: Fri, 20 Jan 2012 00:25:36 -0800
> From: Roopa Prabhu <roprabhu@cisco.com>
>
> reverting back change that access enic->num_vfs outside
> CONFIG_PCI_IOV
>
> Reported-by: Randy Dunlap <rdunlap@xenotime.net>
> Signed-off-by: Roopa Prabhu <roprabhu@cisco.com>
Applied, thanks.
I don't see how you can be asking this to be applied to the net-next
tree. I applied your patches to the plain 'net' tree and therefore
this patch won't apply to net-next at all, go and see for yourself
if you don't believe me. :-)
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [net-next-2.6 PATCH] enic: fix compile when CONFIG_PCI_IOV is not enabled
2012-01-20 18:40 ` David Miller
@ 2012-01-21 8:03 ` Roopa Prabhu
0 siblings, 0 replies; 4+ messages in thread
From: Roopa Prabhu @ 2012-01-21 8:03 UTC (permalink / raw)
To: David Miller; +Cc: netdev, rdunlap
On 1/20/12 10:40 AM, "David Miller" <davem@davemloft.net> wrote:
> From: Roopa Prabhu <roprabhu@cisco.com>
> Date: Fri, 20 Jan 2012 00:25:36 -0800
>
>> From: Roopa Prabhu <roprabhu@cisco.com>
>>
>> reverting back change that access enic->num_vfs outside
>> CONFIG_PCI_IOV
>>
>> Reported-by: Randy Dunlap <rdunlap@xenotime.net>
>> Signed-off-by: Roopa Prabhu <roprabhu@cisco.com>
>
> Applied, thanks.
>
> I don't see how you can be asking this to be applied to the net-next
> tree. I applied your patches to the plain 'net' tree and therefore
> this patch won't apply to net-next at all, go and see for yourself
> if you don't believe me. :-)
Ah..:). I looked for my patches in net-next... And did not find them. did
not realize why.. I wanted to get the patch out soon and had very little
time at hand, so created it on top of my net-next clone that had my previous
patches applied. Thanks for applying it to the correct tree.
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [net-next-2.6 PATCH] enic: fix compile when CONFIG_PCI_IOV is not enabled
2012-01-20 8:25 [net-next-2.6 PATCH] enic: fix compile when CONFIG_PCI_IOV is not enabled Roopa Prabhu
2012-01-20 18:40 ` David Miller
@ 2012-01-20 22:49 ` Randy Dunlap
1 sibling, 0 replies; 4+ messages in thread
From: Randy Dunlap @ 2012-01-20 22:49 UTC (permalink / raw)
To: Roopa Prabhu; +Cc: davem, netdev
On 01/20/2012 12:25 AM, Roopa Prabhu wrote:
> From: Roopa Prabhu <roprabhu@cisco.com>
>
> reverting back change that access enic->num_vfs outside
> CONFIG_PCI_IOV
>
> Reported-by: Randy Dunlap <rdunlap@xenotime.net>
> Signed-off-by: Roopa Prabhu <roprabhu@cisco.com>
Acked-by: Randy Dunlap <rdunlap@xenotime.net>
Thanks.
> ---
> drivers/net/ethernet/cisco/enic/enic_main.c | 4 ++--
> 1 files changed, 2 insertions(+), 2 deletions(-)
>
>
> diff --git a/drivers/net/ethernet/cisco/enic/enic_main.c b/drivers/net/ethernet/cisco/enic/enic_main.c
> index 045c468..ab3f67f 100644
> --- a/drivers/net/ethernet/cisco/enic/enic_main.c
> +++ b/drivers/net/ethernet/cisco/enic/enic_main.c
> @@ -2273,7 +2273,7 @@ static int __devinit enic_probe(struct pci_dev *pdev,
> #ifdef CONFIG_PCI_IOV
> int pos = 0;
> #endif
> - int num_pps;
> + int num_pps = 1;
>
> /* Allocate net device structure and initialize. Private
> * instance data is initialized to zero.
> @@ -2380,11 +2380,11 @@ static int __devinit enic_probe(struct pci_dev *pdev,
> goto err_out_vnic_unregister;
> }
> enic->priv_flags |= ENIC_SRIOV_ENABLED;
> + num_pps = enic->num_vfs;
> }
> }
> #endif
>
> - num_pps = enic->num_vfs ? enic->num_vfs : 1;
> /* Allocate structure for port profiles */
> enic->pp = kcalloc(num_pps, sizeof(*enic->pp), GFP_KERNEL);
> if (!enic->pp) {
>
> --
--
~Randy
*** Remember to use Documentation/SubmitChecklist when testing your code ***
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2012-01-21 8:03 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-01-20 8:25 [net-next-2.6 PATCH] enic: fix compile when CONFIG_PCI_IOV is not enabled Roopa Prabhu
2012-01-20 18:40 ` David Miller
2012-01-21 8:03 ` Roopa Prabhu
2012-01-20 22:49 ` Randy Dunlap
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).