Received: by 2002:a25:23cc:0:0:0:0:0 with SMTP id j195csp1081184ybj; Thu, 7 May 2020 14:27:59 -0700 (PDT) X-Google-Smtp-Source: APiQypI5pV9uFNekY8L6jOlZdhqASmYBQsb7xnt5CZ1b4OlnjQarkK53iHTLHElQCQfmQedD/b88 X-Received: by 2002:a17:906:9450:: with SMTP id z16mr13608050ejx.166.1588886878960; Thu, 07 May 2020 14:27:58 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1588886878; cv=none; d=google.com; s=arc-20160816; b=wnnMMkRtFGn0s4e6c9q1RP6OIXSxdP1vp1PsqxzafgjhxYh86Fpr/tqsoAwF5wRuR+ Z8BQ4x7J678Hihbhajd5Ab8ezQH+KbcYUssajfkxNFA1pyWijz+qGmitYhefCknlflhI xzY/0b7o/qmcfUVg8IlqC0eXCbLEoOfLsr5n8zTuI/B1e0zjy8JyjA2jzvbLWDTRQMsv xbVufEq3D4vnzhGpPk/Xw6r5+/IHX+cv5YaaioZXrjpiNp7RWolN8+db0cyF4LxUxFRH SLdu61l8WGGAVbrDaFNakdi+HZ9A9BUNbrbH0vW5D/WcG+0CV6QySwLAir5xcRyyKKMO M1HQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-transfer-encoding:content-disposition:mime-version :references:message-id:subject:cc:to:from:date; bh=K7FLuLa0riRzqWp0HCLGz5AHRrVP/a/bm/eojB48wDI=; b=ySETrNzQivUf9x2GWE9yTt2D2lKoekS4Z1SxibrNP4tYC1T31HLhwcvPEopelZkpuo IutOhvpJGjrVGUBbw3TvGxp9vSo8XTU1CyaWNwh3OmrdTrx+SxsfP4/J2o6GFN22rlS5 193kwoHJETKsO1a02m3epf0trOF3GHeL0dHi8ZLkFlSq5wectMJ6fgWITJSl3ePpMT9n hn7dsaAhFDFVMe37WPOAemMlZUOTfSXmIcp+SbVVX4+HHeLbUy6tZerUDBH7oOw2WtW3 v54zAymVj+W53P+bzpDmLKUKFlQl/8Y9U24y5dvR1y1PK6gi/l8cJt/fVoj2p5jbnFOr cAVA== ARC-Authentication-Results: i=1; mx.google.com; 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 f11si3803068ejb.492.2020.05.07.14.27.35; Thu, 07 May 2020 14:27:58 -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; 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 S1726538AbgEGVXt (ORCPT + 99 others); Thu, 7 May 2020 17:23:49 -0400 Received: from mail-ot1-f67.google.com ([209.85.210.67]:40810 "EHLO mail-ot1-f67.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726218AbgEGVXt (ORCPT ); Thu, 7 May 2020 17:23:49 -0400 Received: by mail-ot1-f67.google.com with SMTP id i27so5795998ota.7; Thu, 07 May 2020 14:23:48 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:content-transfer-encoding :in-reply-to:user-agent; bh=K7FLuLa0riRzqWp0HCLGz5AHRrVP/a/bm/eojB48wDI=; b=rWG8E54SsgFYVZi39rVIsxE9iNkOMjz82rH1Cef8wi577SNJAxDJ0ZLIaZLqlmTib/ e9Nm9SrzXuNe/J0NEMhIRt/PlHJlyeMpQR5Bs4tPt2WDC4dCqFOxXvISbDHX4j8c6qph 0kjvzs7hx8v54d8MQuUkFyx64seeMtLXtOjAZNFUBhcdrYA9HSVeqBi4m5Fu+fIsBlw6 kbV3V6T8V1wKcH+F9Jgr73M6cg73JzlJp/qpf0qimiEHKCrzxCHS2vFiPFemaL+WjyjE jKJs/EC1/YgY/FeoCx7omyWL0+AZEf3Ny9LzG12zxt4Qt1anx4OwQ0r9ubHBzvtZXP6d gqMg== X-Gm-Message-State: AGi0PubsNVcUXKKiCzYGVNqkuccAgCPhTO00Vya5w7b99TFTu5rKf5yR KsOxUXiYHrbX5E6sgAMjcQ== X-Received: by 2002:a05:6830:22dc:: with SMTP id q28mr11590164otc.221.1588886628336; Thu, 07 May 2020 14:23:48 -0700 (PDT) Received: from rob-hp-laptop (24-155-109-49.dyn.grandenetworks.net. [24.155.109.49]) by smtp.gmail.com with ESMTPSA id 85sm1693266oie.17.2020.05.07.14.23.47 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 07 May 2020 14:23:47 -0700 (PDT) Received: (nullmailer pid 22453 invoked by uid 1000); Thu, 07 May 2020 21:23:47 -0000 Date: Thu, 7 May 2020 16:23:47 -0500 From: Rob Herring To: Pali =?iso-8859-1?Q?Roh=E1r?= Cc: Jason Cooper , Andrew Lunn , Gregory Clement , Sebastian Hesselbarth , Thomas Petazzoni , Lorenzo Pieralisi , Andrew Murray , Bjorn Helgaas , Remi Pommarel , Marek =?iso-8859-1?Q?Beh=FAn?= , Tomasz Maciej Nowak , Xogium , devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-pci@vger.kernel.org Subject: Re: [PATCH v4 07/12] PCI: aardvark: Add PHY support Message-ID: <20200507212347.GA22382@bogus> References: <20200430080625.26070-1-pali@kernel.org> <20200430080625.26070-8-pali@kernel.org> MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <20200430080625.26070-8-pali@kernel.org> User-Agent: Mutt/1.10.1 (2018-07-13) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, 30 Apr 2020 10:06:20 +0200, =?UTF-8?q?Pali=20Roh=C3=A1r?= wrote: > From: Marek Beh?n > > With recent proposed changes for U-Boot it is possible that bootloader > won't initialize the PHY for this controller (currently the PHY is > initialized regardless whether PCI is used in U-Boot, but with these > proposed changes the PHY is initialized only on request). > > Since the mvebu-a3700-comphy driver by Miqu?l Raynal supports enabling > PCIe PHY, and since Linux' functionality should be independent on what > bootloader did, add code for enabling generic PHY if found in device OF > node. > > The mvebu-a3700-comphy driver does PHY powering via SMC calls to ARM > Trusted Firmware. The corresponding code in ARM Trusted Firmware skips > one register write which U-Boot does not: step 7 ("Enable TX"), see [1]. > Instead ARM Trusted Firmware expects PCIe driver to do this step, > probably because the register is in PCIe controller address space, > instead of PHY address space. We therefore add this step into the > advk_pcie_setup_hw function. > > [1] https://git.trustedfirmware.org/TF-A/trusted-firmware-a.git/tree/drivers/marvell/comphy/phy-comphy-3700.c?h=v2.3-rc2#n836 > > Signed-off-by: Marek Beh?n > Cc: Miqu?l Raynal > --- > drivers/pci/controller/pci-aardvark.c | 69 +++++++++++++++++++++++++++ > 1 file changed, 69 insertions(+) > Reviewed-by: Rob Herring