Received: by 2002:a05:6a10:22f:0:0:0:0 with SMTP id 15csp618006pxk; Thu, 3 Sep 2020 08:21:44 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwZuPPG/KXP/taqqrJCNS+CCxzcBZx+tFO2V78vpxmaBKty+qSLFChjBIWd/7w9u1YsvjFq X-Received: by 2002:a50:d942:: with SMTP id u2mr3849162edj.0.1599146504059; Thu, 03 Sep 2020 08:21:44 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1599146504; cv=none; d=google.com; s=arc-20160816; b=H17/gM6Ij8Z4sEG5WMbdMmq7X4YH55AUZysTW3PCMYZsPK/MMDFld/0Nk2yvFY8pTV jvXyf1h6zGsyoyGynxePftAeCdxWxp23dOlWX4u4hbGydW2Cp063jwq7ys3mVlLNuPVW 5Vos8aOmlrPcUS8BX5KPXrldzaBqcKBbKWe7n1dCUDjpWdYis3w0XFBYwm8eIRxTgZEB MlynZldJV60QGiAhK9+lDAxe5RpsBbXw1v1hYWNBYDi8WMcXQ63BaE+rzhk0QBuDNXe0 rI0ajpu9BjLPKFMNHTrEXD7TITK08zD/XNHpd4XOKEY+Yvb/RQYNJuHhLUtAC6CDlHqR 1CbQ== 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:cc:to:subject :message-id:date:from:in-reply-to:references:mime-version :dkim-signature; bh=vSTdiuU7UW8q2OVQi9q+98jV2wni9irf58KIjeuCLZE=; b=wgxU5H2Za+/ozvP9YKhnw+lkODrvIioUBwsNop93wZVNcFBL33YzOmcmq7gwqGcUhL 07uFlBbgT6NnLHVLheOKbrmwTxXGiu6me38plpQEm4XPVc1YNZOQvN1YwF30j+T0izoK QZ454JfxvQ93uIahXwpatioIqT4C/BN2nkqv85RWuLQx3ZcGwUW7DHibyVFtDk6iDrAA 3S13gIw3MfUh+jcw9SASXq012rZSTjHApPTwaf4zC57jXVSzt475UWSSptNyu0Q8sv4n XHiWsDy8h153c4C5lPWQqa8P+l6ThdLIV+AB/KraDCVFEFp4BTQaCE03ITvvpbA3w76Y cQ/w== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=l23jQ5rF; 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=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id x2si1976664edj.273.2020.09.03.08.21.21; Thu, 03 Sep 2020 08:21:44 -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=@gmail.com header.s=20161025 header.b=l23jQ5rF; 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=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729108AbgICPUb (ORCPT + 99 others); Thu, 3 Sep 2020 11:20:31 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:35976 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728548AbgICL1B (ORCPT ); Thu, 3 Sep 2020 07:27:01 -0400 Received: from mail-yb1-xb42.google.com (mail-yb1-xb42.google.com [IPv6:2607:f8b0:4864:20::b42]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id EB2F1C061246; Thu, 3 Sep 2020 04:18:28 -0700 (PDT) Received: by mail-yb1-xb42.google.com with SMTP id h20so1939061ybj.8; Thu, 03 Sep 2020 04:18:28 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc:content-transfer-encoding; bh=vSTdiuU7UW8q2OVQi9q+98jV2wni9irf58KIjeuCLZE=; b=l23jQ5rFCiIyga1ZOrbBcnNyWnB9gGbwRMVitiYAhAKXGULvVU1UksrMHHDstOCrli L/MsoQI3hPI1M6BSun/jbMy0j7qljuwZplYaXKFETuH7yEduLZZv3sb4nUDnWsKjqs6H X+ucJJFhk96Alf4w4WeUVcsklvBI5i4mIETEx48aydiOCb4ynwBV6NUWyYQeGuMxo227 Ap/8BZ/yYPSnQENMXdjvelgOeIHCTYjCQdXBQU+elhlBYhd35+KaTbfJLFXOEdFf/x4U vIbQ+VtBD5P1XUMM34xhXOmHVyWiEDwa5mS4w3ny/ndWa0XoO6hdDMM2TSsiorBkU9Bk e9hw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc:content-transfer-encoding; bh=vSTdiuU7UW8q2OVQi9q+98jV2wni9irf58KIjeuCLZE=; b=O1bMFNDhrl1tGlJJXWswytqahTBOCmk8aO50D8nxkQhomSAws7nNwn1/qGkydpzIbn nUJmFM1YrigN/b1Tem+WOh5wTPEBi/f3JFlmwwX137M1vu+Fw8ckGmYReBQVcG3zM/Fk +RrNfZRRDbQziAtL8dMLb9m7GIHaDSzM65K13bMzvVSSxNcAcH4cKAvmiLFSttbwExbR vymOwZ/19tmOvPvGKYqpTxRca0hGdKYlTc5phqSsszGpROisgYYUZtAqzdFOZaOn5unR OGphqIEqgcSqBMtZScUTWVKXutG5/C8aTeknFlKUOh4nQd4+Oaxj8ztTzkRbVsCBFNPE aEWQ== X-Gm-Message-State: AOAM531iXyS8/WSxty0VYnxA08e4BjubYtwmXTF7pbhH/vs74OXHp3W5 0waupDdXQXKK6v++xa0+burKHirnM2Lu1DYv49g= X-Received: by 2002:a25:dc0c:: with SMTP id y12mr1834334ybe.395.1599131908024; Thu, 03 Sep 2020 04:18:28 -0700 (PDT) MIME-Version: 1.0 References: <20200825162718.5838-1-prabhakar.mahadev-lad.rj@bp.renesas.com> <20200825162718.5838-2-prabhakar.mahadev-lad.rj@bp.renesas.com> In-Reply-To: From: "Lad, Prabhakar" Date: Thu, 3 Sep 2020 12:18:01 +0100 Message-ID: Subject: Re: [PATCH 1/4] ARM: dts: r8a7742-iwg21d-q7: Enable PCIe Controller To: Geert Uytterhoeven Cc: Lad Prabhakar , Magnus Damm , Rob Herring , Linux-Renesas , "open list:OPEN FIRMWARE AND FLATTENED DEVICE TREE BINDINGS" , Linux Kernel Mailing List Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi Geert, Thank you for the review. On Thu, Sep 3, 2020 at 11:18 AM Geert Uytterhoeven w= rote: > > Hi Prabhakar, > > On Tue, Aug 25, 2020 at 6:28 PM Lad Prabhakar > wrote: > > Enable PCIe Controller and set PCIe bus clock frequency. > > > > Signed-off-by: Lad Prabhakar > > Reviewed-by: Chris Paterson > > Reviewed-by: Geert Uytterhoeven > i.e. will queue in renesas-devel for v5.10. > > One thing to double-check below. > > > --- a/arch/arm/boot/dts/r8a7742-iwg21d-q7.dts > > +++ b/arch/arm/boot/dts/r8a7742-iwg21d-q7.dts > > @@ -238,6 +238,18 @@ > > /* status =3D "okay"; */ > > }; > > > > +&pcie_bus_clk { > > + clock-frequency =3D <100000000>; > > +}; > > + > > +&pciec { > > + /* SW2[6] determines which connector is activated > > + * ON =3D PCIe X4 (connector-J7) > > + * OFF =3D mini-PCIe (connector-J26) > > The table on page 14 says it's the other way around. > > According to the CBTL02042ABQ datasheet, PCIe_SEL =3D low > selects the first channel (PCIe x4), while PCIe_SEL =3D high selects the > second channel (mini-PCIe). > Enabling the switch ties the signal low, so the table must be wrong. > Referring to [1] page 3: SEL =3D LOW: A=E2=86=94B SEL =3D HIGH: A=E2=86=94C And as per the schematic iW-PREJD-CS-01-R2.0-REL1.5.pdf channel B is J7 (PCIe X 4) and channel C is J26 (mini PCIe slot). Enabling the switch SW2[6] (ON) ties SEL to LOW -> channel B is J7 (PCIe X = 4) Disabling the switch SW2[6] (OFF) ties SEL to HIGH -> channel C is J26 (mini PCIe) Also iW-PREJD-CS-01-R2.0-REL1.5.pdf page 14 (General purpose table DIP Switch) mentions the above. [1] https://www.mouser.co.uk/datasheet/2/302/CBTL02042A_CBTL02042B-1126164.= pdf Cheers, Prabhakar > > + */ > > + status =3D "okay"; > > +}; > > + > > &pfc { > > avb_pins: avb { > > groups =3D "avb_mdio", "avb_gmii"; > > Gr{oetje,eeting}s, > > Geert > > -- > Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@linux-m6= 8k.org > > In personal conversations with technical people, I call myself a hacker. = But > when I'm talking to journalists I just say "programmer" or something like= that. > -- Linus Torvalds