All of lore.kernel.org
 help / color / mirror / Atom feed
From: David Daney <ddaney@caviumnetworks.com>
To: Alan Stern <stern@rowland.harvard.edu>
Cc: Greg KH <greg@kroah.com>, Florian Fainelli <f.fainelli@gmail.com>,
	"Alex Smith" <alex.smith@imgtec.com>,
	Linux-MIPS <linux-mips@linux-mips.org>,
	"David Daney" <david.daney@cavium.com>,
	linux-usb <linux-usb@vger.kernel.org>
Subject: Re: [PATCH 3/3] usb host/MIPS: Remove hard-coded OCTEON platform information.
Date: Thu, 29 May 2014 14:26:00 -0700	[thread overview]
Message-ID: <5387A5E8.2030104@caviumnetworks.com> (raw)
In-Reply-To: <Pine.LNX.4.44L0.1405291632360.1285-100000@iolanthe.rowland.org>

On 05/29/2014 01:55 PM, Alan Stern wrote:
> On Thu, 29 May 2014, David Daney wrote:
>
>> Several points of clarification:
>>
>> 1) I wrote the patch in question, not Florian.
>>
>> 2) I agree that OCTEON ehci/ohci support could probably be refactored
>> along the lines of Alan's suggestion.
>>
>> 3) This patch is a relatively minor change to an *existing* driver
>> rather than a completely new thing that hasn't yet been merged.
>>
>> 4) There is a lot of precedent for merging minor enhancements and bug
>> fixes instead of requiring a complete refactoring of *existing* code.
>>
>> All that said, I haven't dug into the ehci-platform and ohci-platform
>> enough to be able to opine on the best course of action in this
>> particular case.  I hope to be able to make a more educated follow-up
>> next week.
>
> Moving these into the respective platform drivers shouldn't be a big
> deal.  Below is a totally untested preliminary pass -- I'm pleased that
> it removes a lot more lines than it adds.
>
> This first attempt leaves a few matters unresolved:
>
> 	The EHCI DMA mask is coerced to 32 bits by ehci-platform.c.
> 	Maybe this should be controllable by a flag in the
> 	usb_ehci_pdata structure.
>
> 	The timing of the calls to octeon_[eo]hci_hw_start() might
> 	be wrong.  The patch does it before the memory resources
> 	are mapped, rather than afterward as it is done now.  I don't
> 	know if this will matter.
>
> 	The clock management is awkward at best.  But it's about the
> 	same as what we do now.
>
> Anyway, it shouldn't be hard to fix this up and get it working, and
> then rebase your patch on top of it.
>
> Alan Stern
>
>
>
>   arch/mips/cavium-octeon/octeon-platform.c |  274 +++++++++++++++++++++++++++++-
>   arch/mips/configs/cavium_octeon_defconfig |    3
>   drivers/usb/host/Kconfig                  |   18 +
>   drivers/usb/host/Makefile                 |    1
>   drivers/usb/host/ehci-hcd.c               |    5
>   drivers/usb/host/ehci-octeon.c            |  188 --------------------
>   drivers/usb/host/octeon2-common.c         |  200 ---------------------
>   drivers/usb/host/ohci-hcd.c               |    5
>   drivers/usb/host/ohci-octeon.c            |  202 ----------------------
>   9 files changed, 285 insertions(+), 611 deletions(-)
>

Thanks Alan,

That goes beyond the call of duty!


I will try to test (and improve if necessary) this patch.

David Daney

      reply	other threads:[~2014-05-29 21:26 UTC|newest]

Thread overview: 21+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-05-29 10:10 [PATCH 0/3] Ubiquiti EdgeRouter/EdgeRouter Pro support Alex Smith
2014-05-29 10:10 ` Alex Smith
2014-05-29 10:10 ` [PATCH 1/3] MIPS: octeon: Add interface mode detection for Octeon II Alex Smith
2014-05-29 10:10   ` Alex Smith
2014-06-04 14:47   ` [1/3] " Aaro Koskinen
2014-06-04 15:58     ` Alex Smith
2014-06-04 15:58       ` Alex Smith
2014-06-04 17:12       ` David Daney
2014-06-04 17:12         ` David Daney
2014-06-04 18:53         ` Aaro Koskinen
2014-05-29 10:10 ` [PATCH 2/3] staging: octeon-ethernet: Move PHY activation to .ndo_open() Alex Smith
2014-05-29 10:10   ` Alex Smith
2014-05-29 10:10 ` [PATCH 3/3] usb host/MIPS: Remove hard-coded OCTEON platform information Alex Smith
2014-05-29 10:10   ` Alex Smith
2014-05-29 15:03   ` Alan Stern
2014-05-29 15:03     ` Alan Stern
2014-05-29 16:55     ` Florian Fainelli
2014-05-29 17:37       ` Greg KH
2014-05-29 17:59         ` David Daney
2014-05-29 20:55           ` Alan Stern
2014-05-29 21:26             ` David Daney [this message]

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=5387A5E8.2030104@caviumnetworks.com \
    --to=ddaney@caviumnetworks.com \
    --cc=alex.smith@imgtec.com \
    --cc=david.daney@cavium.com \
    --cc=f.fainelli@gmail.com \
    --cc=greg@kroah.com \
    --cc=linux-mips@linux-mips.org \
    --cc=linux-usb@vger.kernel.org \
    --cc=stern@rowland.harvard.edu \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.