All of lore.kernel.org
 help / color / mirror / Atom feed
* [U-Boot] [PATCH v6 0/20] tegra: Add fdt definitions and USB driver
@ 2012-02-27 20:52 Simon Glass
  2012-02-27 20:52   ` [U-Boot] " Simon Glass
                   ` (12 more replies)
  0 siblings, 13 replies; 83+ messages in thread
From: Simon Glass @ 2012-02-27 20:52 UTC (permalink / raw)
  To: u-boot

This series brings in the Linux kernel fdt file and provides a working
USB driver for Tegra2 Seaboard.

(I have done this in one series since otherwise most of the fdt additions
will just look like dead code.)

The driver requires CONFIG_OF_CONTROL and a device tree to operate.

Some enhancements to fdtdec are required to make this easier, and these
are included in the series also. I have had to bring in basic GPIO
support due to the request to put the USB VBUS into the fdt.

Since the kernel recently got a very minimal USB binding, I have started
with that and extended it where appropriate.

Tegra likes to have cache-aligned buffers. I have dropped the patch which
implements this since we will solve this problem by making callers align
their buffers (as we did with MMC).

Changes in v2:
- Add setting of pinmux for USB VBUS GPIO
- Decode USB VBUS GPIO from the fdt
- Decode phy type differently (to match new kernel fdt)
- Improve debug() printouts in case of failure to init USB
- Remove 0x from fdt aliases
- Remove non-fdt operation of USB, since it is not needed
- Remove unneeded CONFIG_TEGRA_USBx defines
- Rename params to timing
- Rename tegra20-usb to tegra20-ehcui (to match new kernel fdt)
- Store entire fdt config in port list, not just register pointer
- Use "okay" instead of "ok" for fdt node status

Changes in v3:
- Disable USB2 which is not used on Seaboard
- Drop Tegra USB alignment patch as we will deal with this another way
- Fix device tree indenting with tabs instead of spaces
- Remove "okay" from nodes since this is the default anyway
- Remove usbparams properties from fdt and moved them to C code

Changes in v4:
- Add clock bindings for Tegra2x
- Add fdtdec function to return peripheral ID
- Add staging area for device tree bindings used in U-Boot
- Use peripheral clock node to obtain peripheral ID
- Use updated fdtdec alias functiona to get USB aliases

Changes in v5:
- Add CONFIG_EHCI_DCACHE which is needed for dcache operation
- Add additional debugging to report active USB ports
- Add dr_mode property to control host/device/otg mode
- Add nvidia,has-legacy-mode property per review comments
- Allow any port to operate in otg mode
- Change device tree comment style from // to /* */
- Correct PTS_MASK value to be unsigned
- Drop unused CONFIG_USB_EHCI_DATA_ALIGN option
- Fixed endian bug in fdtdec_decode_gpios()
- Implement new device tree properties
- Make sure GPIO name is NULL if incorrectly decoded
- Put pinmux setting into a board-specific function
- Remove checking of peripheral ID and try to use only device tree
- Remove support-host-mode property
- Report error if phy clock does not start up
- Update README to indicate that we will commit fdt documentation to U-Boot

Changes in v6:
- Add clock bindings from Stephen Warren's latest patch
- Add new patch to bring in clock bindings to seaboard
- Drop fdt alignment patch as we will handle this after generic reloc
- Move peripheral decode function into Tegra's clock.c
- Remove dr_mode properties from SOC .dtsi file and move to boards
- Use updated clock_decode_periph_id() function

Simon Glass (20):
  fdt: Tidy up a few fdtdec problems
  fdt: Add functions to access phandles, arrays and bools
  fdt: Add basic support for decoding GPIO definitions
  arm: fdt: Add skeleton device tree file from kernel
  tegra: fdt: Add Tegra2x device tree file from kernel
  tegra: fdt: Add device tree file for Tegra2 Seaboard from kernel
  fdt: Add staging area for device tree binding documentation
  fdt: Add tegra-usb bindings file from linux
  tegra: fdt: Add additional USB binding
  tegra: fdt: Add clock bindings
  tegra: fdt: Add clock bindings for Tegra2 Seaboard
  tegra: usb: fdt: Add additional device tree definitions for USB ports
  tegra: usb: fdt: Add USB definitions for Tegra2 Seaboard
  usb: Add support for txfifo threshold
  tegra: fdt: Add function to return peripheral/clock ID
  tegra: usb: Add support for Tegra USB peripheral
  tegra: usb: Add USB support to nvidia boards
  tegra: usb: Add common USB defines for tegra2 boards
  tegra: usb: Enable USB on Seaboard
  tegra: fdt: Enable FDT support for Seaboard

 README                                             |    3 +
 arch/arm/cpu/armv7/tegra2/Makefile                 |    4 +-
 arch/arm/cpu/armv7/tegra2/clock.c                  |   19 +
 arch/arm/cpu/armv7/tegra2/config.mk                |    2 +
 arch/arm/cpu/armv7/tegra2/usb.c                    |  460 ++++++++++++++++++++
 arch/arm/dts/skeleton.dtsi                         |   13 +
 arch/arm/dts/tegra20.dtsi                          |  188 ++++++++
 arch/arm/include/asm/arch-tegra2/clock.h           |   13 +
 arch/arm/include/asm/arch-tegra2/tegra2.h          |    2 +
 arch/arm/include/asm/arch-tegra2/usb.h             |  252 +++++++++++
 board/nvidia/common/board.c                        |   12 +
 board/nvidia/common/board.h                        |    6 +
 board/nvidia/dts/tegra2-seaboard.dts               |   57 +++
 board/nvidia/seaboard/seaboard.c                   |    6 +
 doc/device-tree-bindings/README                    |   17 +
 .../clock/nvidia,tegra20-car.txt                   |  207 +++++++++
 doc/device-tree-bindings/usb/tegra-usb.txt         |   25 +
 drivers/usb/host/Makefile                          |    1 +
 drivers/usb/host/ehci-hcd.c                        |    7 +
 drivers/usb/host/ehci-tegra.c                      |   62 +++
 drivers/usb/host/ehci.h                            |    6 +-
 include/configs/seaboard.h                         |   12 +
 include/configs/tegra2-common.h                    |   10 +
 include/fdtdec.h                                   |  108 +++++-
 lib/fdtdec.c                                       |  169 +++++++-
 25 files changed, 1649 insertions(+), 12 deletions(-)
 create mode 100644 arch/arm/cpu/armv7/tegra2/usb.c
 create mode 100644 arch/arm/dts/skeleton.dtsi
 create mode 100644 arch/arm/dts/tegra20.dtsi
 create mode 100644 arch/arm/include/asm/arch-tegra2/usb.h
 create mode 100644 board/nvidia/dts/tegra2-seaboard.dts
 create mode 100644 doc/device-tree-bindings/README
 create mode 100644 doc/device-tree-bindings/clock/nvidia,tegra20-car.txt
 create mode 100644 doc/device-tree-bindings/usb/tegra-usb.txt
 create mode 100644 drivers/usb/host/ehci-tegra.c

-- 
1.7.7.3

^ permalink raw reply	[flat|nested] 83+ messages in thread

end of thread, other threads:[~2012-03-07  2:48 UTC | newest]

Thread overview: 83+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-02-27 20:52 [U-Boot] [PATCH v6 0/20] tegra: Add fdt definitions and USB driver Simon Glass
2012-02-27 20:52 ` [PATCH v6 01/20] fdt: Tidy up a few fdtdec problems Simon Glass
2012-02-27 20:52   ` [U-Boot] " Simon Glass
2012-02-27 20:52 ` [PATCH v6 02/20] fdt: Add functions to access phandles, arrays and bools Simon Glass
2012-02-27 20:52   ` [U-Boot] " Simon Glass
2012-02-27 20:52 ` [PATCH v6 03/20] fdt: Add basic support for decoding GPIO definitions Simon Glass
2012-02-27 20:52   ` [U-Boot] " Simon Glass
2012-02-27 20:52 ` [PATCH v6 04/20] arm: fdt: Add skeleton device tree file from kernel Simon Glass
2012-02-27 20:52   ` [U-Boot] " Simon Glass
2012-02-27 20:52 ` [PATCH v6 05/20] tegra: fdt: Add Tegra2x " Simon Glass
2012-02-27 20:52   ` [U-Boot] " Simon Glass
2012-02-27 20:52 ` [PATCH v6 07/20] fdt: Add staging area for device tree binding documentation Simon Glass
2012-02-27 20:52   ` [U-Boot] " Simon Glass
2012-02-27 20:52 ` [PATCH v6 08/20] fdt: Add tegra-usb bindings file from linux Simon Glass
2012-02-27 20:52   ` [U-Boot] " Simon Glass
     [not found] ` <1330375973-10681-1-git-send-email-sjg-F7+t8E8rja9g9hUCZPvPmw@public.gmane.org>
2012-02-27 20:52   ` [PATCH v6 06/20] tegra: fdt: Add device tree file for Tegra2 Seaboard from kernel Simon Glass
2012-02-27 20:52     ` [U-Boot] " Simon Glass
2012-02-27 20:52   ` [PATCH v6 09/20] tegra: fdt: Add additional USB binding Simon Glass
2012-02-27 20:52     ` [U-Boot] " Simon Glass
     [not found]     ` <1330375973-10681-10-git-send-email-sjg-F7+t8E8rja9g9hUCZPvPmw@public.gmane.org>
2012-02-27 23:27       ` Stephen Warren
2012-02-27 23:27         ` [U-Boot] " Stephen Warren
2012-02-27 20:52   ` [PATCH v6 10/20] tegra: fdt: Add clock bindings Simon Glass
2012-02-27 20:52     ` [U-Boot] " Simon Glass
2012-02-27 20:52   ` [PATCH v6 11/20] tegra: fdt: Add clock bindings for Tegra2 Seaboard Simon Glass
2012-02-27 20:52     ` [U-Boot] " Simon Glass
     [not found]     ` <1330375973-10681-12-git-send-email-sjg-F7+t8E8rja9g9hUCZPvPmw@public.gmane.org>
2012-02-27 23:29       ` Stephen Warren
2012-02-27 23:29         ` [U-Boot] " Stephen Warren
     [not found]         ` <4F4C11E9.1050907-DDmLM1+adcrQT0dZR+AlfA@public.gmane.org>
2012-02-28 17:20           ` Simon Glass
2012-02-28 17:20             ` [U-Boot] " Simon Glass
     [not found]             ` <CAPnjgZ0_xzn0tvETt3C=pjyRX-MXNA-JXy4fuAs9L8OdHuvLhg-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2012-02-28 17:32               ` Stephen Warren
2012-02-28 17:32                 ` [U-Boot] " Stephen Warren
     [not found]                 ` <74CDBE0F657A3D45AFBB94109FB122FF17BDDF1D6A-C7FfzLzN0UxDw2glCA4ptUEOCMrvLtNR@public.gmane.org>
2012-02-28 17:37                   ` Simon Glass
2012-02-28 17:37                     ` [U-Boot] " Simon Glass
2012-02-28 18:31                     ` Stephen Warren
2012-02-28 18:31                       ` [U-Boot] " Stephen Warren
2012-02-28 18:37                       ` Simon Glass
2012-02-28 18:37                         ` [U-Boot] " Simon Glass
2012-02-28 18:41                         ` Stephen Warren
2012-02-28 18:41                           ` [U-Boot] " Stephen Warren
2012-02-28 18:46                           ` Simon Glass
2012-02-28 18:46                             ` [U-Boot] " Simon Glass
     [not found]                             ` <CAPnjgZ0VGRSgb92u2UbNf+_HFF-EXhLZzC4XdYUvAjVKtz1XtQ-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2012-02-28 22:16                               ` Albert ARIBAUD
2012-02-28 22:16                                 ` Albert ARIBAUD
2012-03-03 16:26                                 ` Simon Glass
2012-03-03 16:26                                   ` [U-Boot] " Simon Glass
     [not found]                           ` <74CDBE0F657A3D45AFBB94109FB122FF17BDDF1DB8-C7FfzLzN0UxDw2glCA4ptUEOCMrvLtNR@public.gmane.org>
2012-03-05 20:46                             ` Tom Rini
2012-03-05 20:46                               ` Tom Rini
2012-03-07  2:48                               ` Simon Glass
2012-03-07  2:48                                 ` Simon Glass
2012-02-27 20:52   ` [PATCH v6 12/20] tegra: usb: fdt: Add additional device tree definitions for USB ports Simon Glass
2012-02-27 20:52     ` [U-Boot] " Simon Glass
2012-02-27 20:52   ` [PATCH v6 16/20] tegra: usb: Add support for Tegra USB peripheral Simon Glass
2012-02-27 20:52     ` [U-Boot] " Simon Glass
2012-02-27 20:52   ` [PATCH v6 17/20] tegra: usb: Add USB support to nvidia boards Simon Glass
2012-02-27 20:52     ` [U-Boot] " Simon Glass
2012-02-27 20:52   ` [PATCH v6 18/20] tegra: usb: Add common USB defines for tegra2 boards Simon Glass
2012-02-27 20:52     ` [U-Boot] " Simon Glass
2012-02-27 20:52   ` [PATCH v6 19/20] tegra: usb: Enable USB on Seaboard Simon Glass
2012-02-27 20:52     ` [U-Boot] " Simon Glass
2012-02-27 20:52 ` [PATCH v6 13/20] tegra: usb: fdt: Add USB definitions for Tegra2 Seaboard Simon Glass
2012-02-27 20:52   ` [U-Boot] " Simon Glass
2012-02-27 20:52 ` [U-Boot] [PATCH v6 14/20] usb: Add support for txfifo threshold Simon Glass
2012-02-27 20:52 ` [PATCH v6 15/20] tegra: fdt: Add function to return peripheral/clock ID Simon Glass
2012-02-27 20:52   ` [U-Boot] " Simon Glass
     [not found]   ` <1330375973-10681-16-git-send-email-sjg-F7+t8E8rja9g9hUCZPvPmw@public.gmane.org>
2012-02-27 23:41     ` Stephen Warren
2012-02-27 23:41       ` [U-Boot] " Stephen Warren
     [not found]       ` <4F4C149E.3070505-DDmLM1+adcrQT0dZR+AlfA@public.gmane.org>
2012-02-28 17:46         ` Simon Glass
2012-02-28 17:46           ` [U-Boot] " Simon Glass
     [not found]           ` <CAPnjgZ24vhy7NKj_Dt_dzn0qJ8=rj4nF04WSsY8u9MorAanzVA-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2012-02-28 18:37             ` Stephen Warren
2012-02-28 18:37               ` [U-Boot] " Stephen Warren
     [not found]               ` <74CDBE0F657A3D45AFBB94109FB122FF17BDDF1DB4-C7FfzLzN0UxDw2glCA4ptUEOCMrvLtNR@public.gmane.org>
2012-02-28 18:44                 ` Simon Glass
2012-02-28 18:44                   ` [U-Boot] " Simon Glass
2012-02-28 18:51                   ` Stephen Warren
2012-02-28 18:51                     ` [U-Boot] " Stephen Warren
     [not found]                     ` <74CDBE0F657A3D45AFBB94109FB122FF17BDDF1DC8-C7FfzLzN0UxDw2glCA4ptUEOCMrvLtNR@public.gmane.org>
2012-02-28 23:50                       ` Simon Glass
2012-02-28 23:50                         ` [U-Boot] " Simon Glass
     [not found]                         ` <CAPnjgZ2vwck_u1HVbpz=B4QjiCVoLeX6TcvwMi-o71Fqt_m3NQ-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2012-02-29 17:08                           ` Stephen Warren
2012-02-29 17:08                             ` [U-Boot] " Stephen Warren
2012-02-27 20:52 ` [PATCH v6 20/20] tegra: fdt: Enable FDT support for Seaboard Simon Glass
2012-02-27 20:52   ` [U-Boot] " Simon Glass
2012-02-27 23:42 ` [U-Boot] [PATCH v6 0/20] tegra: Add fdt definitions and USB driver Stephen Warren
2012-02-28 18:12   ` Simon Glass
2012-02-29 17:34     ` Simon Glass

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.