From patchwork Wed Oct 2 23:16:14 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: John Stultz X-Patchwork-Id: 175042 Delivered-To: patches@linaro.org Received: by 2002:a92:7e96:0:0:0:0:0 with SMTP id q22csp1417305ill; Wed, 2 Oct 2019 16:16:22 -0700 (PDT) X-Received: by 2002:a63:d343:: with SMTP id u3mr869714pgi.313.1570058182479; Wed, 02 Oct 2019 16:16:22 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1570058182; cv=none; d=google.com; s=arc-20160816; b=oPLwoyCRLH1w9Ds3LtdcvRSAkhQcwkThK+YhN5Hkf1QW3R851jRLufrB6w04ok3OWN +oboGRjEJdhQ/uNe+m7TH99KPUAoqdwQ1Wv0198/3zMvQYJVq9x8yH/szJ4TUNHTePxX 9ydQ3JhZ1GA1S/X5XAUwo2gavHVr5Zow/gZBHbVZqqEwrSu3lkYJj1jQzwxJUPRYgz6g 0HMV8fHAuJRvYBbgVI2g+UgydMffoASy5H/xQxbqbyDmbTAIUnPFyriBBdwpAy4aqV6h zPkkHsuptl8//8/tn4/Yk6EuEvxXiHjTJ3UmyjJF9ttF7U2zAcGoSaZYH5Qrum6+DqKw WnXQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=message-id:date:subject:cc:to:from:dkim-signature; bh=ze/XvAAk8GBZMksPYjyDCpmqV8AGCwQH61JmBZ7VYXE=; b=ShHs76FmR4QwsTQVTJF5NJCt6fKokI9l0dtrLmyh7hl14hZqo8M5tHWRsVgi3hGlGB w5W4xAvlFpRb609mdHLiD7KWg/8EWqx/6LlYRYe/I8ZeJqnwy0ocsPmlkGf/b/EFj9vr MxnaAdHj4s0v0tzIi/mvLkIZi/2mIiKVCEIzNfTNfC43wF0qoYTHvfV9e/HjVOpuWp+q KGBKfpgnYaFbiZJ06x3wASS4L8Ba6xsS9YvfpVjPiXftcnxkjvGZYZnHQsdhaLJlRl7s mMZItz3jxfawA2A/nDwMjP1nZ4jNnpBeY3uAahxJbYDX1xsZsY+GHoVFg4RpqwCg0YYb PeHg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=XuU6hHtC; spf=pass (google.com: domain of john.stultz@linaro.org designates 209.85.220.65 as permitted sender) smtp.mailfrom=john.stultz@linaro.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from mail-sor-f65.google.com (mail-sor-f65.google.com. [209.85.220.65]) by mx.google.com with SMTPS id d1sor783049pls.17.2019.10.02.16.16.22 for (Google Transport Security); Wed, 02 Oct 2019 16:16:22 -0700 (PDT) Received-SPF: pass (google.com: domain of john.stultz@linaro.org designates 209.85.220.65 as permitted sender) client-ip=209.85.220.65; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=XuU6hHtC; spf=pass (google.com: domain of john.stultz@linaro.org designates 209.85.220.65 as permitted sender) smtp.mailfrom=john.stultz@linaro.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id; bh=ze/XvAAk8GBZMksPYjyDCpmqV8AGCwQH61JmBZ7VYXE=; b=XuU6hHtCbzgnLgj5xFdd29USBSRIe9zpmWPOLYUJB/YMxHldDaP1t3RdXqKU7+9qST CHAm4YD7iyFga95zzDWl2BjqU7MUMTB3jy4xz1GdTiRkdD5XgK9GOF16bc+n1vXBwFTs cMRj5LW+ej1CyJRz6V9q57XBmn+T6zAnJz5PabxfyCmUJVXoe9vngSvvZmpQ/kbUIbMa +htweaej41pOqioUGALldV5jmpQexr9STl2LcRl08StyUthb17t34BXsB6Y8avXbOWPG 50XyAz92YjpfMHOFwtvoST77qm5oxCyFltxTEA2eGtbBN1yVvp8nGP7eMXXN+zGAZAp8 6SEQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id; bh=ze/XvAAk8GBZMksPYjyDCpmqV8AGCwQH61JmBZ7VYXE=; b=LeziFWcR7rrjVt7rcazcyfxBR9L+8Th1q58WzaHonw65fv/WezgWRREEJwHgJePXab iYzsfGNHHVDDo+DnCEXE6IE23/71TOun4GJwL0eZuNbNsaN3JEqH2jPl8xp/szkTZn5l zTpNxIx9hnZ4S+6zpbot9FA6y2RLPidilCEn+sbWA8Jx3alMYVB1BQm7W/1NCwOPMcTN IfIXa5MU5tuDHyhwQ7BiwTICxGx+nc8iKw+cPkWTkxyp9ykgUkpwHdbsDxH62iLNFMng dIHSfsobJsAz2nzc1APkuhTrAA/jNsxoDNz3n367tkfP3jTan9MU6f2TOLmZE8eqoFEu FOKw== X-Gm-Message-State: APjAAAVwRoE236LrhHZ34V16PsD65Qnd1TiKu2HkVDag0+fXJAvZRw4b NgQFsZBGVVdf5YCsRq0td5FdgwAC X-Google-Smtp-Source: APXvYqwKK+QsXsOrigPf5Vzcddlm1GWn4ouIdnrb8vXeJ7P0jW3FJ31myUBhJrIC1NEdFL3iiaRbbg== X-Received: by 2002:a17:902:a40a:: with SMTP id p10mr6399376plq.149.1570058181824; Wed, 02 Oct 2019 16:16:21 -0700 (PDT) Return-Path: Received: from localhost.localdomain ([2601:1c2:680:1319:692:26ff:feda:3a81]) by smtp.gmail.com with ESMTPSA id l7sm288791pjy.12.2019.10.02.16.16.19 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 02 Oct 2019 16:16:21 -0700 (PDT) From: John Stultz To: lkml Cc: John Stultz , Greg Kroah-Hartman , Rob Herring , Mark Rutland , Heikki Krogerus , Suzuki K Poulose , Chunfeng Yun , Yu Chen , Felipe Balbi , Hans de Goede , Andy Shevchenko , Jun Li , Valentin Schneider , linux-usb@vger.kernel.org, devicetree@vger.kernel.org Subject: [RFC][PATCH 0/3] dwc3 role-switch handling for HiKey960 Date: Wed, 2 Oct 2019 23:16:14 +0000 Message-Id: <20191002231617.3670-1-john.stultz@linaro.org> X-Mailer: git-send-email 2.17.1 I'm just trying to pick up parts of a patch previously by Yu Chen to get HiKey960 dev-board's USB functionality working. The current full patchset can be found here: https://git.linaro.org/people/john.stultz/android-dev.git/log/?id=12289c95c89e0e3173f8da1ebd3a29e52fd50a44 I don't have any real knowledge of the hardware other then the code, and what I can intuit from testing, but I tried to document the previously undocumented bindings as best I could and fixed up a few minor checkpatch issues. I'd greatly appreciate feedback or thoughts! thanks -john Cc: Greg Kroah-Hartman Cc: Rob Herring Cc: Mark Rutland Cc: Heikki Krogerus Cc: Suzuki K Poulose Cc: Chunfeng Yun Cc: Yu Chen Cc: Felipe Balbi Cc: Hans de Goede Cc: Andy Shevchenko Cc: Jun Li Cc: Valentin Schneider Cc: linux-usb@vger.kernel.org Cc: devicetree@vger.kernel.org John Stultz (1): dt-bindings: usb: generic: Add role-switch-default-host binding Yu Chen (2): usb: roles: Add usb role switch notifier. usb: dwc3: Registering a role switch in the DRD code. .../devicetree/bindings/usb/generic.txt | 5 ++ drivers/usb/dwc3/Kconfig | 1 + drivers/usb/dwc3/core.h | 6 ++ drivers/usb/dwc3/drd.c | 78 ++++++++++++++++++- drivers/usb/roles/class.c | 35 ++++++++- include/linux/usb/role.h | 16 ++++ 6 files changed, 139 insertions(+), 2 deletions(-) -- 2.17.1