Received: by 2002:a05:6a10:f3d0:0:0:0:0 with SMTP id a16csp4623346pxv; Tue, 6 Jul 2021 05:34:21 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzZ3Mth50wpkSLmbvpk8c2/PPudZwiax3jwggjZfT6fCisBLtWsR6PV/zLQ4yANApmqyl/Z X-Received: by 2002:a17:906:d1ce:: with SMTP id bs14mr18703903ejb.183.1625574861032; Tue, 06 Jul 2021 05:34:21 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1625574861; cv=none; d=google.com; s=arc-20160816; b=JIQG75Qz+pxIO6RgbLRXdUvOal4TwR299d1Lr+qIterTslf/0+c3u36lqMnIxOQIsp bnXsbkYEhsFPzMO7GxKyjORaB/QmxTHeVLiQhuUjO3itAPF/CIDRQ/gLsfoyxZV6vBDn yoFOcVG237czT5vccBURIt9sVTX8wspTLmA3Qw9s0KaNncmBLcXuGNWyxmoVys00R5Gv oot3n9xHbxEMsPORm2F7S4jBDFdEPajT9flBZVN87TQ7N441DYoHcZOV10GpJ6PVvNRi /Tz5+C458hya3ZodGWS/gY0RX66K3Gs8n5KLJhJTJeizjDvKRv1zxl9Y7DmAWK1W6hbJ kgXQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :message-id:date:subject:cc:to:from:dkim-signature; bh=d1YnTYQv6NLHCmwREZSGQGckyqofDc2k4LaeaBEvwJE=; b=V3KRZwgSS78ys8W9kQQ4PaLrOveBT1RTIb4PhTDC06luxc1xurwRqV4EWV3T6f+tFt +6tp8eQQS31YCmUjzceQ+zXNVPUpTL6XbLVDP58CzFRePbRXEr6oOYhsul+0u/vR1IpY X/kN0iOOQXnIfz9shxPYSGGYXw+C4fI1JP/kFSoVmPkRJOuXN20xtqbhEKtKsZ/g4jVe 00RPUK9ICLui3dE0QhdU35RdMbrDF6UJHQtRfcRI28czCjdifT8iBKCTfEnIvc9wnLBD /SQG6EMhkDXDGt+cmgtgi/QP92I8NEEuVacZgfKrQpmi6OhwyT8mNYoZ+MmB6EcgZtb9 Be4g== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=RXfwtOXb; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id g7si8735162ejt.645.2021.07.06.05.33.51; Tue, 06 Jul 2021 05:34:21 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=RXfwtOXb; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1343983AbhGFM3f (ORCPT + 99 others); Tue, 6 Jul 2021 08:29:35 -0400 Received: from mail.kernel.org ([198.145.29.99]:45046 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S242161AbhGFMZt (ORCPT ); Tue, 6 Jul 2021 08:25:49 -0400 Received: by mail.kernel.org (Postfix) with ESMTPSA id 6324C622E9; Tue, 6 Jul 2021 12:23:10 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1625574190; bh=wz4Bic0LSPWmrCj80ELZl2dM0eChPNGuIIo785wRWDw=; h=From:To:Cc:Subject:Date:From; b=RXfwtOXbimz822euPvZ9jCYUkxtuTtUsicRgUhnDJ/VlBQFDfty6hxF87aW0Tf7Gw GgGsvbXHPxBQEvWzc8021HYoSBJtcFtAb5OFuSaAoLGiXufB3IvOMxM+nB0XjcaOmp 9xXfYA4uRF+lH6MrDeL61na0vPyl0XK4/M7JtpLfFXatgY3SEQazITSz3eIIOs5sl8 qf/jyDqkE80a6QyL7LYofiV53/f5dtV187FLgxktsjIZoDR0KeCedMK0FTJI4AvP6F Ps08ZgTnkwu4i9cDTGQCS7wWg5O2t0IEY3XHI8wkafg3uVgoRYh+n8VC8SJltZ0GXM 4sACa0d+6YT6Q== Received: by mail.kernel.org with local (Exim 4.94.2) (envelope-from ) id 1m0k6W-004qMk-4w; Tue, 06 Jul 2021 14:23:08 +0200 From: Mauro Carvalho Chehab To: Rob Herring Cc: linuxarm@huawei.com, mauro.chehab@huawei.com, Mauro Carvalho Chehab , =?UTF-8?q?Krzysztof=20Wilczy=C5=84ski?= , Binghui Wang , Xiaowei Song , devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, linux-pci@vger.kernel.org, linux-phy@lists.infradead.org Subject: [PATCH RFC 0/1] Move PHY out of pcie-kirin driver Date: Tue, 6 Jul 2021 14:23:05 +0200 Message-Id: X-Mailer: git-send-email 2.31.1 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Sender: Mauro Carvalho Chehab Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org During the review of the Kirin 970 PCIe patch series, it was pointed that the pcie-kirin driver has PHY logic mixed inside it: https://lore.kernel.org/lkml/CAL_JsqK7_hAw4aacHyiqJWE6zSWiMez5695+deaCSHfeWuX-XA@mail.gmail.com/ Probably due to that, support for those devices weren't added upstream. Before trying to re-send it again, let's split the existing PHY code for Kirin 960 (Hisi3660) from the driver. Please notice that this change will alter the device tree, as a new PHY descriptor will be needed, and the PHY properties from the pcie nodes will need to switch. This patch doesn't change the documentation yet, but it does change the DTS file. If this change is OK, I'll resend this patch together with the documentation changes. Tested on a Hikey 960. After the patch, the PCI bridge is properly displayed: $ lspci 00:00.0 PCI bridge: Huawei Technologies Co., Ltd. Device 3660 (rev 01) Unfortunately, currently I can't test if the bridge is working as this bridge supports only non-SATA M.2 devices. I'm acquiring one for tests, but it will take a couple weeks to arrive. Mauro Carvalho Chehab (1): PCI: dwc: pcie-kirin: split PHY interface from the driver arch/arm64/boot/dts/hisilicon/hi3660.dtsi | 24 +- drivers/pci/controller/dwc/pcie-kirin.c | 195 +++------------- drivers/phy/hisilicon/Kconfig | 10 + drivers/phy/hisilicon/Makefile | 1 + drivers/phy/hisilicon/phy-hi3660-pcie.c | 261 ++++++++++++++++++++++ 5 files changed, 321 insertions(+), 170 deletions(-) create mode 100644 drivers/phy/hisilicon/phy-hi3660-pcie.c -- 2.31.1