netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: "Figo.zhang" <figo1802@gmail.com>
To: zeal <zealcook@gmail.com>
Cc: netdev@vger.kernel.org, ben@simtec.co.uk, davem@davemloft.net
Subject: Re: [PATCH 2/2 v2] KS8695: fix ks8695_rx() unreasonable action.
Date: Fri, 13 Nov 2009 01:16:34 +0800	[thread overview]
Message-ID: <1258046194.1931.18.camel@myhost> (raw)
In-Reply-To: <4b016886.16115e0a.355d.ffffca52@mx.google.com>

On Mon, 2009-11-16 at 22:58 +0800, zeal wrote:
> From: zeal <zealcook@gmail.com>
> 
> ks8695_rx() will call refill_buffers() for every incoming packet.
> Its not necessary. We just need do it after finishing receiving thing.
> And the 'RX dma engine' is in the same situation.
> This blocks our user space application. The following patch may fix it.
> 

yes, it is right.

Best,
Figo.zhang

> Signed-off-by: zeal <zealcook@gmail.com>
> ---
>  drivers/net/arm/ks8695net.c |   13 ++++++-------
>  1 files changed, 6 insertions(+), 7 deletions(-)
> 
> diff --git a/drivers/net/arm/ks8695net.c b/drivers/net/arm/ks8695net.c
> index e15451a..be256b3 100644
> --- a/drivers/net/arm/ks8695net.c
> +++ b/drivers/net/arm/ks8695net.c
> @@ -544,14 +544,13 @@ rx_finished:
>  				ksp->next_rx_desc_read =
>  					(last_rx_processed + 1) &
>  					MAX_RX_DESC_MASK;
> -
> -			/* And refill the buffers */
> -			ks8695_refill_rxbuffers(ksp);
> -
> -			/* Kick the RX DMA engine, in case it became
> -			 *  suspended */
> -			ks8695_writereg(ksp, KS8695_DRSC, 0);
>  	}
> +	/* And refill the buffers */
> +	ks8695_refill_rxbuffers(ksp);
> +
> +	/* Kick the RX DMA engine, in case it became
> +	 *  suspended */
> +	ks8695_writereg(ksp, KS8695_DRSC, 0);
>  	return received;
>  }
>  



  reply	other threads:[~2009-11-16 16:04 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <1258383490-13341-1-git-send-email-zeal>
2009-11-16 14:58 ` [PATCH 2/2 v2] KS8695: fix ks8695_rx() unreasonable action zeal
2009-11-12 17:16   ` Figo.zhang [this message]
2009-11-17  7:52     ` David Miller

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=1258046194.1931.18.camel@myhost \
    --to=figo1802@gmail.com \
    --cc=ben@simtec.co.uk \
    --cc=davem@davemloft.net \
    --cc=netdev@vger.kernel.org \
    --cc=zealcook@gmail.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).