* [jkirsher/net-queue PATCH] i40e: Add programming descriptors to cleaned_count
@ 2017-10-22 1:12 Alexander Duyck
2017-10-22 18:01 ` Anders K. Pedersen | Cohaesio
0 siblings, 1 reply; 6+ messages in thread
From: Alexander Duyck @ 2017-10-22 1:12 UTC (permalink / raw)
To: netdev, intel-wired-lan, akp, pstaszewski
From: Alexander Duyck <alexander.h.duyck@intel.com>
This patch updates the i40e driver to include programming descriptors in
the cleaned_count. Without this change it becomes possible for us to leak
memory as we don't trigger a large enough allocation when the time comes to
allocate new buffers and we end up overwriting a number of rx_buffers equal
to the number of programming descriptors we encountered.
Fixes: 0e626ff7ccbf ("i40e: Fix support for flow director programming status")
Signed-off-by: Alexander Duyck <alexander.h.duyck@intel.com>
---
drivers/net/ethernet/intel/i40e/i40e_txrx.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/drivers/net/ethernet/intel/i40e/i40e_txrx.c b/drivers/net/ethernet/intel/i40e/i40e_txrx.c
index 368722defacb..d6d352a6e6ea 100644
--- a/drivers/net/ethernet/intel/i40e/i40e_txrx.c
+++ b/drivers/net/ethernet/intel/i40e/i40e_txrx.c
@@ -2102,6 +2102,7 @@ static int i40e_clean_rx_irq(struct i40e_ring *rx_ring, int budget)
if (unlikely(i40e_rx_is_programming_status(qword))) {
i40e_clean_programming_status(rx_ring, rx_desc, qword);
+ cleaned_count++;
continue;
}
size = (qword & I40E_RXD_QW1_LENGTH_PBUF_MASK) >>
^ permalink raw reply related [flat|nested] 6+ messages in thread
* Re: [jkirsher/net-queue PATCH] i40e: Add programming descriptors to cleaned_count
2017-10-22 1:12 [jkirsher/net-queue PATCH] i40e: Add programming descriptors to cleaned_count Alexander Duyck
@ 2017-10-22 18:01 ` Anders K. Pedersen | Cohaesio
2017-10-22 23:15 ` Paweł Staszewski
0 siblings, 1 reply; 6+ messages in thread
From: Anders K. Pedersen | Cohaesio @ 2017-10-22 18:01 UTC (permalink / raw)
To: pstaszewski@itcare.pl, netdev@vger.kernel.org,
intel-wired-lan@lists.osuosl.org, alexander.duyck@gmail.com
On lør, 2017-10-21 at 18:12 -0700, Alexander Duyck wrote:
> From: Alexander Duyck <alexander.h.duyck@intel.com>
>
> This patch updates the i40e driver to include programming descriptors
> in
> the cleaned_count. Without this change it becomes possible for us to
> leak
> memory as we don't trigger a large enough allocation when the time
> comes to
> allocate new buffers and we end up overwriting a number of rx_buffers
> equal
> to the number of programming descriptors we encountered.
>
> Fixes: 0e626ff7ccbf ("i40e: Fix support for flow director programming
> status")
> Signed-off-by: Alexander Duyck <alexander.h.duyck@intel.com>
This patch solves the remaining memory leak we've seen, so
Tested-by: Anders K. Pedersen <akp@cohaesio.com>
Regards,
Anders
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [jkirsher/net-queue PATCH] i40e: Add programming descriptors to cleaned_count
2017-10-22 18:01 ` Anders K. Pedersen | Cohaesio
@ 2017-10-22 23:15 ` Paweł Staszewski
2017-10-27 21:20 ` [Intel-wired-lan] " Pavlos Parissis
0 siblings, 1 reply; 6+ messages in thread
From: Paweł Staszewski @ 2017-10-22 23:15 UTC (permalink / raw)
To: Anders K. Pedersen | Cohaesio, netdev@vger.kernel.org,
intel-wired-lan@lists.osuosl.org, alexander.duyck@gmail.com
Yes can confirm that after adding patch:
[jkirsher/net-queue PATCH] i40e: Add programming descriptors to
cleaned_count
There is no memleak.
W dniu 2017-10-22 o 20:01, Anders K. Pedersen | Cohaesio pisze:
> On lør, 2017-10-21 at 18:12 -0700, Alexander Duyck wrote:
>> From: Alexander Duyck <alexander.h.duyck@intel.com>
>>
>> This patch updates the i40e driver to include programming descriptors
>> in
>> the cleaned_count. Without this change it becomes possible for us to
>> leak
>> memory as we don't trigger a large enough allocation when the time
>> comes to
>> allocate new buffers and we end up overwriting a number of rx_buffers
>> equal
>> to the number of programming descriptors we encountered.
>>
>> Fixes: 0e626ff7ccbf ("i40e: Fix support for flow director programming
>> status")
>> Signed-off-by: Alexander Duyck <alexander.h.duyck@intel.com>
> This patch solves the remaining memory leak we've seen, so
>
> Tested-by: Anders K. Pedersen <akp@cohaesio.com>
>
> Regards,
> Anders
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [Intel-wired-lan] [jkirsher/net-queue PATCH] i40e: Add programming descriptors to cleaned_count
2017-10-22 23:15 ` Paweł Staszewski
@ 2017-10-27 21:20 ` Pavlos Parissis
2017-10-27 22:21 ` Paweł Staszewski
0 siblings, 1 reply; 6+ messages in thread
From: Pavlos Parissis @ 2017-10-27 21:20 UTC (permalink / raw)
To: Paweł Staszewski
Cc: Anders K. Pedersen | Cohaesio, netdev@vger.kernel.org,
intel-wired-lan@lists.osuosl.org, alexander.duyck@gmail.com
On 23 October 2017 at 01:15, Paweł Staszewski <pstaszewski@itcare.pl> wrote:
> Yes can confirm that after adding patch:
>
> [jkirsher/net-queue PATCH] i40e: Add programming descriptors to
> cleaned_count
>
>
> There is no memleak.
>
>
Somehow this patch isn't present in the current net-next repo.
Shouldn't it be there?
Cheers,
Pavlos
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [Intel-wired-lan] [jkirsher/net-queue PATCH] i40e: Add programming descriptors to cleaned_count
2017-10-27 21:20 ` [Intel-wired-lan] " Pavlos Parissis
@ 2017-10-27 22:21 ` Paweł Staszewski
2017-10-27 22:58 ` Pavlos Parissis
0 siblings, 1 reply; 6+ messages in thread
From: Paweł Staszewski @ 2017-10-27 22:21 UTC (permalink / raw)
To: Pavlos Parissis
Cc: Anders K. Pedersen | Cohaesio, netdev@vger.kernel.org,
intel-wired-lan@lists.osuosl.org, alexander.duyck@gmail.com
from today it is in net.git
https://git.kernel.org/pub/scm/linux/kernel/git/davem/net.git/log/?qt=grep&q=i40e
It will be later in net-next
Also can You please tell me what firmware You are using with Your nics ?
Those are X710 ?
Thanks
Paweł
W dniu 2017-10-27 o 23:20, Pavlos Parissis pisze:
> On 23 October 2017 at 01:15, Paweł Staszewski <pstaszewski@itcare.pl> wrote:
>> Yes can confirm that after adding patch:
>>
>> [jkirsher/net-queue PATCH] i40e: Add programming descriptors to
>> cleaned_count
>>
>>
>> There is no memleak.
>>
>>
> Somehow this patch isn't present in the current net-next repo.
> Shouldn't it be there?
>
> Cheers,
> Pavlos
>
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [Intel-wired-lan] [jkirsher/net-queue PATCH] i40e: Add programming descriptors to cleaned_count
2017-10-27 22:21 ` Paweł Staszewski
@ 2017-10-27 22:58 ` Pavlos Parissis
0 siblings, 0 replies; 6+ messages in thread
From: Pavlos Parissis @ 2017-10-27 22:58 UTC (permalink / raw)
To: Paweł Staszewski
Cc: Anders K. Pedersen | Cohaesio, netdev@vger.kernel.org,
intel-wired-lan@lists.osuosl.org, alexander.duyck@gmail.com
On 28 October 2017 at 00:21, Paweł Staszewski <pstaszewski@itcare.pl> wrote:
> from today it is in net.git
>
> https://git.kernel.org/pub/scm/linux/kernel/git/davem/net.git/log/?qt=grep&q=i40e
>
> It will be later in net-next
>
>
I have to admit I am not that familiar with repo layout, I though
net-next holds what is going to be pushed to Linus's repo and
potentially some parts to linux-stable.
> Also can You please tell me what firmware You are using with Your nics ?
>
1.1752.0., but we use the firmware version that comes from HP, as we
use HP servers, see details here
https://communities.intel.com/message/501682#501682
> Those are X710 ?
Correct.
Cheers,
Pavlos
^ permalink raw reply [flat|nested] 6+ messages in thread
end of thread, other threads:[~2017-10-27 22:58 UTC | newest]
Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2017-10-22 1:12 [jkirsher/net-queue PATCH] i40e: Add programming descriptors to cleaned_count Alexander Duyck
2017-10-22 18:01 ` Anders K. Pedersen | Cohaesio
2017-10-22 23:15 ` Paweł Staszewski
2017-10-27 21:20 ` [Intel-wired-lan] " Pavlos Parissis
2017-10-27 22:21 ` Paweł Staszewski
2017-10-27 22:58 ` Pavlos Parissis
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).