All of lore.kernel.org
 help / color / mirror / Atom feed
From: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
To: Rob Herring <robh@kernel.org>, John Stultz <john.stultz@linaro.org>
Cc: linuxarm@huawei.com, mauro.chehab@huawei.com,
	Mauro Carvalho Chehab <mchehab+huawei@kernel.org>,
	Rob Herring <robh+dt@kernel.org>,
	devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org,
	linux-kernel@vger.kernel.org
Subject: [PATCH v4 0/4] Make USB ports to work on HiKey960/970
Date: Fri,  3 Sep 2021 11:28:31 +0200	[thread overview]
Message-ID: <cover.1630659949.git.mchehab+huawei@kernel.org> (raw)

Hi Rob,

It follows the patchset adding a DT schema needed to power on and to
use the integrated USB hub found on HiKey 960 and Hikey 970 boards.

Besides each board use a different chip for the hub,  on both they're
controlled the same way. Such boards come with an integrated 4-port
USB hub on it, set on what it seems to be a non-standard way: on both 
implementations, the USB type-C port is used to detect the USB role.

When in host mode, the 3.3V power supply (VDD33 pins) for the hub
are disabled. That disables the USB I/O on type-A ports.

When USB type-C is on device mode, the OTG is switched via a GPIO pin
to device mode, and the hub is powered on.

A Type-C power supply line is also controlled depending on the role.

-

The entire series  which contains the remaining patches to support
PCI and USB on HiKey970, and USB on HiKey960 is at:

    https://github.com/mchehab/linux/commits/linux-master

The patches needed by the USB on HiKey970 were already merged
upstream. So, the above branch applies on the top of Linux master
branch.

Tested on HiKey 960:

	$ lsusb
	Bus 002 Device 002: ID 0424:5734 Standard Microsystems Corp. 
	Bus 002 Device 001: ID 1d6b:0003 Linux Foundation 3.0 root hub
	Bus 001 Device 004: ID 0424:2740 Standard Microsystems Corp. 
	Bus 001 Device 003: ID 046d:c52b Logitech, Inc. Unifying Receiver
	Bus 001 Device 002: ID 0424:2734 Standard Microsystems Corp. 
	Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub

Tested on HiKey 970:
	
	$ lsusb
	Bus 002 Device 002: ID 0451:8140 Texas Instruments, Inc. TUSB8041 4-Port Hub
	Bus 002 Device 001: ID 1d6b:0003 Linux Foundation 3.0 root hub
	Bus 001 Device 003: ID 0a12:0001 Cambridge Silicon Radio, Ltd Bluetooth Dongle (HCI mode)
	Bus 001 Device 002: ID 0451:8142 Texas Instruments, Inc. TUSB8041 4-Port Hub
	Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub

v4:
  - Improved description at the DT schema;
  - Use just one compatible, as there's no difference between
    HiKey 960 and 970 with regards to how the hub should be
    controlled;
  - parse usb-role-switch property at the driver;
  - make the properties that depends on usb-role-switch optional.

v3:
  - The examples at the dt-bindings were updated to reflect
    the actual DTS content and won't produce any warnings;
  - Added John Stultz SoB to Hikey960 DTS patch;
  - Added a patch for the mux hub driver for it to work with
    the newer schema;

John Stultz (1):
  arm64: dts: hisilicon: Add usb mux hub for hikey960

Mauro Carvalho Chehab (2):
  misc: hisi_hikey_usb: change the DT schema
  arm64: dts: hisilicon: Add usb mux hub for hikey970

Yu Chen (1):
  dt-bindings: misc: add schema for USB hub on Kirin devices

 .../bindings/misc/hisilicon,hikey-usb.yaml    |  87 +++++++++++++
 .../boot/dts/hisilicon/hi3660-hikey960.dts    |  35 +++++-
 .../boot/dts/hisilicon/hi3670-hikey970.dts    |  23 ++++
 drivers/misc/hisi_hikey_usb.c                 | 119 +++++++++---------
 4 files changed, 206 insertions(+), 58 deletions(-)
 create mode 100644 Documentation/devicetree/bindings/misc/hisilicon,hikey-usb.yaml

-- 
2.31.1



_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

WARNING: multiple messages have this Message-ID (diff)
From: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
To: Rob Herring <robh@kernel.org>, John Stultz <john.stultz@linaro.org>
Cc: linuxarm@huawei.com, mauro.chehab@huawei.com,
	Mauro Carvalho Chehab <mchehab+huawei@kernel.org>,
	Rob Herring <robh+dt@kernel.org>,
	devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org,
	linux-kernel@vger.kernel.org
Subject: [PATCH v4 0/4] Make USB ports to work on HiKey960/970
Date: Fri,  3 Sep 2021 11:28:31 +0200	[thread overview]
Message-ID: <cover.1630659949.git.mchehab+huawei@kernel.org> (raw)

Hi Rob,

It follows the patchset adding a DT schema needed to power on and to
use the integrated USB hub found on HiKey 960 and Hikey 970 boards.

Besides each board use a different chip for the hub,  on both they're
controlled the same way. Such boards come with an integrated 4-port
USB hub on it, set on what it seems to be a non-standard way: on both 
implementations, the USB type-C port is used to detect the USB role.

When in host mode, the 3.3V power supply (VDD33 pins) for the hub
are disabled. That disables the USB I/O on type-A ports.

When USB type-C is on device mode, the OTG is switched via a GPIO pin
to device mode, and the hub is powered on.

A Type-C power supply line is also controlled depending on the role.

-

The entire series  which contains the remaining patches to support
PCI and USB on HiKey970, and USB on HiKey960 is at:

    https://github.com/mchehab/linux/commits/linux-master

The patches needed by the USB on HiKey970 were already merged
upstream. So, the above branch applies on the top of Linux master
branch.

Tested on HiKey 960:

	$ lsusb
	Bus 002 Device 002: ID 0424:5734 Standard Microsystems Corp. 
	Bus 002 Device 001: ID 1d6b:0003 Linux Foundation 3.0 root hub
	Bus 001 Device 004: ID 0424:2740 Standard Microsystems Corp. 
	Bus 001 Device 003: ID 046d:c52b Logitech, Inc. Unifying Receiver
	Bus 001 Device 002: ID 0424:2734 Standard Microsystems Corp. 
	Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub

Tested on HiKey 970:
	
	$ lsusb
	Bus 002 Device 002: ID 0451:8140 Texas Instruments, Inc. TUSB8041 4-Port Hub
	Bus 002 Device 001: ID 1d6b:0003 Linux Foundation 3.0 root hub
	Bus 001 Device 003: ID 0a12:0001 Cambridge Silicon Radio, Ltd Bluetooth Dongle (HCI mode)
	Bus 001 Device 002: ID 0451:8142 Texas Instruments, Inc. TUSB8041 4-Port Hub
	Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub

v4:
  - Improved description at the DT schema;
  - Use just one compatible, as there's no difference between
    HiKey 960 and 970 with regards to how the hub should be
    controlled;
  - parse usb-role-switch property at the driver;
  - make the properties that depends on usb-role-switch optional.

v3:
  - The examples at the dt-bindings were updated to reflect
    the actual DTS content and won't produce any warnings;
  - Added John Stultz SoB to Hikey960 DTS patch;
  - Added a patch for the mux hub driver for it to work with
    the newer schema;

John Stultz (1):
  arm64: dts: hisilicon: Add usb mux hub for hikey960

Mauro Carvalho Chehab (2):
  misc: hisi_hikey_usb: change the DT schema
  arm64: dts: hisilicon: Add usb mux hub for hikey970

Yu Chen (1):
  dt-bindings: misc: add schema for USB hub on Kirin devices

 .../bindings/misc/hisilicon,hikey-usb.yaml    |  87 +++++++++++++
 .../boot/dts/hisilicon/hi3660-hikey960.dts    |  35 +++++-
 .../boot/dts/hisilicon/hi3670-hikey970.dts    |  23 ++++
 drivers/misc/hisi_hikey_usb.c                 | 119 +++++++++---------
 4 files changed, 206 insertions(+), 58 deletions(-)
 create mode 100644 Documentation/devicetree/bindings/misc/hisilicon,hikey-usb.yaml

-- 
2.31.1



             reply	other threads:[~2021-09-03  9:31 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-09-03  9:28 Mauro Carvalho Chehab [this message]
2021-09-03  9:28 ` [PATCH v4 0/4] Make USB ports to work on HiKey960/970 Mauro Carvalho Chehab
2021-09-03  9:28 ` [PATCH v4 1/4] dt-bindings: misc: add schema for USB hub on Kirin devices Mauro Carvalho Chehab
2021-09-03  9:28 ` [PATCH v4 2/4] misc: hisi_hikey_usb: change the DT schema Mauro Carvalho Chehab
2021-09-03  9:28 ` [PATCH v4 3/4] arm64: dts: hisilicon: Add usb mux hub for hikey970 Mauro Carvalho Chehab
2021-09-03  9:28   ` Mauro Carvalho Chehab
2021-09-09 23:12   ` kernel test robot
2021-09-09 23:12     ` kernel test robot
2021-09-09 23:12     ` kernel test robot
2021-09-03  9:28 ` [PATCH v4 4/4] arm64: dts: hisilicon: Add usb mux hub for hikey960 Mauro Carvalho Chehab
2021-09-03  9:28   ` Mauro Carvalho Chehab
2021-09-15 13:12 ` [PATCH v4 0/4] Make USB ports to work on HiKey960/970 Mauro Carvalho Chehab
2021-09-15 13:12   ` Mauro Carvalho Chehab

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=cover.1630659949.git.mchehab+huawei@kernel.org \
    --to=mchehab+huawei@kernel.org \
    --cc=devicetree@vger.kernel.org \
    --cc=john.stultz@linaro.org \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linuxarm@huawei.com \
    --cc=mauro.chehab@huawei.com \
    --cc=robh+dt@kernel.org \
    --cc=robh@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 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.