From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received-SPF: Pass (sender SPF authorized) identity=mailfrom; client-ip=2a00:1450:4864:20::342; helo=mail-wm1-x342.google.com; envelope-from=leif.lindholm@linaro.org; receiver=edk2-devel@lists.01.org Received: from mail-wm1-x342.google.com (mail-wm1-x342.google.com [IPv6:2a00:1450:4864:20::342]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by ml01.01.org (Postfix) with ESMTPS id F0ECC211B76BE for ; Mon, 21 Jan 2019 03:32:38 -0800 (PST) Received: by mail-wm1-x342.google.com with SMTP id f188so10347455wmf.5 for ; Mon, 21 Jan 2019 03:32:38 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to:user-agent; bh=7wdVBAIvc0ehyGtqXJqTPntm8cRM1cv59dkgmy/pF6A=; b=EmWtjYPMk9z9oJdAWyRtO5yvfm7jJiNcm9sdtH81sIAe1ZOrg+wBigJYGUg06JzWdH tc9LeCVvI5TXQqT5Gt4c80BOZg7kC2rszDd0XoutGwlaOCaE4NEcSbDNKSGHyCkQxnn0 s0ZVZkkJrqJFkB3dWJsj7iPBFiijRHtox5BFA= 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:in-reply-to:user-agent; bh=7wdVBAIvc0ehyGtqXJqTPntm8cRM1cv59dkgmy/pF6A=; b=otyPIZRD1ggIMmWNFmkeXHrSh//TGt51ByHiP7Sxro8GcN2OVCfwvAgQmWkYe+tkGu WL77fi6XTsUNZfbXyQ+2cx4YkpCN7cIkA2rfp4x08KlpjRwbBeNlk+gh5lRbtulPmiyv /UPpMMAAB7EMQ0NaWairHGyNM6mAsm/GReQXCIZGEy2t7E6lJWVy+RRZQTpmVI2mTchq AZ8zsNjaVqlQ3TMmsJNmeDoh9RInoum2rfJWr3aBIIwx5w3BwABaknHig7gN1gLO1hI8 Ulew4Tw6fpoC+4tTQ3ta03TaeaPKtIeRrwBGBti7g+CvGUA/NDDCglwHxYM5k+QH2zkK DAzw== X-Gm-Message-State: AJcUukdiWUOiyaTUjbeEjwxZPAIbxPArwtHX3WDYx+u6f73sSHVbRMOH MCh6Rv7/C3Qb7ltzqxIo/RUnNA== X-Google-Smtp-Source: ALg8bN5lNPLb7xFj/kdcSs7/Py/xaJ8AOjdqp7gXM7JaKXXV/tQHhcDTUulZvQd9u/41DTeS/GJl9Q== X-Received: by 2002:a1c:d752:: with SMTP id o79mr8276676wmg.100.1548070356137; Mon, 21 Jan 2019 03:32:36 -0800 (PST) Received: from bivouac.eciton.net (bivouac.eciton.net. [2a00:1098:0:86:1000:23:0:2]) by smtp.gmail.com with ESMTPSA id y138sm58081409wmc.16.2019.01.21.03.32.35 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Mon, 21 Jan 2019 03:32:35 -0800 (PST) Date: Mon, 21 Jan 2019 11:32:33 +0000 From: Leif Lindholm To: Marcin Wojtas Cc: edk2-devel@lists.01.org, ard.biesheuvel@linaro.org, nadavh@marvell.com, jsd@semihalf.com, jaz@semihalf.com, kostap@marvell.com Message-ID: <20190121113233.lnlarpvi5c5tug4k@bivouac.eciton.net> References: <1548067931-18618-1-git-send-email-mw@semihalf.com> <1548067931-18618-3-git-send-email-mw@semihalf.com> MIME-Version: 1.0 In-Reply-To: <1548067931-18618-3-git-send-email-mw@semihalf.com> User-Agent: NeoMutt/20170113 (1.7.2) Subject: Re: [platforms: PATCH 2/3] Marvell/Library: ArmadaSoCDescLib: Add North Bridge description X-BeenThere: edk2-devel@lists.01.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: EDK II Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 21 Jan 2019 11:32:39 -0000 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline On Mon, Jan 21, 2019 at 11:52:10AM +0100, Marcin Wojtas wrote: > From: Grzegorz Jaszczyk > > For upcomming patch there is need to get AP806 base, provide required > getter function for it. > > Contributed-under: TianoCore Contribution Agreement 1.1 > Signed-off-by: Marcin Wojtas > --- > Silicon/Marvell/Armada7k8k/Library/Armada7k8kSoCDescLib/Armada7k8kSoCDescLib.h | 1 + > Silicon/Marvell/Include/Library/ArmadaSoCDescLib.h | 10 ++++++++++ > Silicon/Marvell/Armada7k8k/Library/Armada7k8kSoCDescLib/Armada7k8kSoCDescLib.c | 17 +++++++++++++++++ > 3 files changed, 28 insertions(+) > > diff --git a/Silicon/Marvell/Armada7k8k/Library/Armada7k8kSoCDescLib/Armada7k8kSoCDescLib.h b/Silicon/Marvell/Armada7k8k/Library/Armada7k8kSoCDescLib/Armada7k8kSoCDescLib.h > index bfc8639..6caee6c 100644 > --- a/Silicon/Marvell/Armada7k8k/Library/Armada7k8kSoCDescLib/Armada7k8kSoCDescLib.h > +++ b/Silicon/Marvell/Armada7k8k/Library/Armada7k8kSoCDescLib/Armada7k8kSoCDescLib.h > @@ -22,6 +22,7 @@ > // Common macros > // > #define MV_SOC_CP_BASE(Cp) (0xF2000000 + ((Cp) * 0x2000000)) > +#define MV_SOC_AP806_BASE 0xF0000000 > #define MV_SOC_AP806_COUNT 1 > > // > diff --git a/Silicon/Marvell/Include/Library/ArmadaSoCDescLib.h b/Silicon/Marvell/Include/Library/ArmadaSoCDescLib.h > index 26b075a..7aec9be 100644 > --- a/Silicon/Marvell/Include/Library/ArmadaSoCDescLib.h > +++ b/Silicon/Marvell/Include/Library/ArmadaSoCDescLib.h > @@ -20,6 +20,16 @@ > #include > > // > +// North Bridge description > +// > +EFI_STATUS > +EFIAPI > +ArmadaSoCAp8xxBaseGet ( > + IN OUT UINT64 *ApBase, > + IN UINTN ApIndex > + ); > + > +// > // ComPhy SoC description > // > typedef struct { > diff --git a/Silicon/Marvell/Armada7k8k/Library/Armada7k8kSoCDescLib/Armada7k8kSoCDescLib.c b/Silicon/Marvell/Armada7k8k/Library/Armada7k8kSoCDescLib/Armada7k8kSoCDescLib.c > index 5b72c20..089ac2d 100644 > --- a/Silicon/Marvell/Armada7k8k/Library/Armada7k8kSoCDescLib/Armada7k8kSoCDescLib.c > +++ b/Silicon/Marvell/Armada7k8k/Library/Armada7k8kSoCDescLib/Armada7k8kSoCDescLib.c > @@ -30,6 +30,23 @@ > As I said, I was going to get stricter about adding function description comments - please add one here. (And clone it to ArmadaSoCDescLib.h, for the obious place to go look for a template when implementing a variant for a new platform.) > EFI_STATUS > EFIAPI > +ArmadaSoCAp8xxBaseGet ( > + IN OUT UINT64 *ApBase, > + IN UINTN ApIndex > + ) > +{ > + if (ApIndex != 0) { This test should be using ARMADA7K8K_AP806_INDEX, and that definition should be added to this patch. > + DEBUG ((DEBUG_ERROR, "%a: Only one AP806 in A7K/A8K SoC\n", __FUNCTION__)); > + return EFI_INVALID_PARAMETER; > + } > + > + *ApBase = MV_SOC_AP806_BASE; > + > + return EFI_SUCCESS; > +} > + > +EFI_STATUS > +EFIAPI > ArmadaSoCDescComPhyGet ( > IN OUT MV_SOC_COMPHY_DESC **ComPhyDesc, > IN OUT UINTN *DescCount > -- > 2.7.4 >