linux-usb.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Greg KH <gregkh@linuxfoundation.org>
To: Frank Li <Frank.Li@nxp.com>
Cc: peter.chen@kernel.org, pawell@cadence.com, rogerq@kernel.org,
	a-govindraju@ti.com, linux-usb@vger.kernel.org, jun.li@nxp.com,
	lznuaa@gmail.com, linux-kernel@vger.kernel.org
Subject: Re: [PATCH v8 1/1] usb: cdns3: allocate TX FIFO size according to composite EP number
Date: Wed, 27 Apr 2022 18:57:12 +0200	[thread overview]
Message-ID: <Yml16DvnUR/tJSCO@kroah.com> (raw)
In-Reply-To: <20220427163525.1129887-1-Frank.Li@nxp.com>

On Wed, Apr 27, 2022 at 11:35:25AM -0500, Frank Li wrote:
> Some devices have USB compositions which may require multiple endpoints.
> To get better performance, need bigger CDNS3_EP_BUF_SIZE.
> 
> But bigger CDNS3_EP_BUF_SIZE may exceed total hardware FIFO size when
> multiple endpoints.
> 
> By introducing the check_config() callback, calculate CDNS3_EP_BUF_SIZE.
> 
> Move CDNS3_EP_BUF_SIZE into cnds3_device: ep_buf_size
> Combine CDNS3_EP_ISO_SS_BURST and CDNS3_EP_ISO_HS_MULT into
> ecnds3_device:ep_iso_burst
> 
> Using a simple algorithm to calculate ep_buf_size.
> ep_buf_size = ep_iso_burst = (onchip_buffers - 2k) / (number of IN EP +
> 1).
> 
> Test at 8qxp:
> 
> 	Gadget			ep_buf_size
> 
> 	RNDIS:				5
> 	RNDIS+ACM:			3
> 	Mass Storage + NCM + ACM	2
> 
> Previous CDNS3_EP_BUF_SIZE is 4, RNDIS + ACM will be failure because
> exceed FIFO memory.
> 
> Signed-off-by: Frank Li <Frank.Li@nxp.com>
> ---
> Change from v1 to v2:
>  Add safe check for mult, buffering and maxburst

that's nice, but this is v8, not v2?

confused,

greg k-h

  reply	other threads:[~2022-04-27 16:57 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-04-27 16:35 [PATCH v8 1/1] usb: cdns3: allocate TX FIFO size according to composite EP number Frank Li
2022-04-27 16:57 ` Greg KH [this message]
2022-04-27 17:03   ` Zhi Li
2022-05-05 19:31     ` Greg KH
2022-05-05  2:21 ` Peter Chen
2022-05-05 15:24   ` Zhi Li
2022-05-09  3:16     ` Peter Chen

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=Yml16DvnUR/tJSCO@kroah.com \
    --to=gregkh@linuxfoundation.org \
    --cc=Frank.Li@nxp.com \
    --cc=a-govindraju@ti.com \
    --cc=jun.li@nxp.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-usb@vger.kernel.org \
    --cc=lznuaa@gmail.com \
    --cc=pawell@cadence.com \
    --cc=peter.chen@kernel.org \
    --cc=rogerq@kernel.org \
    /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).