From nobody Tue Nov 26 03:50:38 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of groups.io designates 66.175.222.12 as permitted sender) client-ip=66.175.222.12; envelope-from=bounce+27952+61060+1787277+3901457@groups.io; helo=web01.groups.io; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of groups.io designates 66.175.222.12 as permitted sender) smtp.mailfrom=bounce+27952+61060+1787277+3901457@groups.io; arc=fail (BodyHash is different from the expected one); dmarc=fail(p=none dis=none) header.from=oss.nxp.com Received: from web01.groups.io (web01.groups.io [66.175.222.12]) by mx.zohomail.com with SMTPS id 1591781682817287.1046262643862; Wed, 10 Jun 2020 02:34:42 -0700 (PDT) Return-Path: X-Received: by 127.0.0.2 with SMTP id 3vqVYY1788612xHV7tEFlurL; Wed, 10 Jun 2020 02:34:42 -0700 X-Received: from EUR01-VE1-obe.outbound.protection.outlook.com (EUR01-VE1-obe.outbound.protection.outlook.com [40.107.14.71]) by mx.groups.io with SMTP id smtpd.web11.801.1591737689962251368 for ; Tue, 09 Jun 2020 14:21:30 -0700 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=A5hrLm0CgXSxWijv1R/423OFoJ/Lq+nSszw6knh2ISkXsaB7mmmplnp85IYiEyNCKqENP20e8qFTsMMSA1n0dRxipOqEk3ZaYVrxaiBgrgJTn4qJYMeRpc9E9lmMQ73p+NIC5Hb7ztpllP3L3dLaUgM4TIYUCVvFnKlg6xkbC0i9wvjr2KHESdSjULgXoifsCY66eXTfwrm+9njdJOUBTZKyLX9cSpCVnQSOxU5rnMkvYMKBXHkY1tFtTesETDkYUk/c9kn2nSzye8bvPXaqYS0rcOsQ/ZXZHQAinMKUa/DffrCpklJo0JVnKOwbklMXSXmVjMEtGDwHWIFm8FpQ0w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=WpIuAjf29MXTbDFEus3fx0i6FeMOqiABJr1nHOuDI40=; b=lQp+CMNkHMl95buhQFLeNgEjABno9pjcaWJNAmP4FmkT5Y+2J9A0d+6F/cuiYkU3in4FfGNQT2NyHoxl/zYaJsVBcZjqP2r1HNWWtF1jsTolknF/0kAuvk/5O/Z4wB9TxtaCOMxKabJFc/5JLmUVk9XGuD+mRdp3SJdzjDlNqbVIuqt8uSH5Xnv9LngrjZKewcYi2x+rfSsOqEmdgjAPH4uCAsiUrBx/uERR15Gth75zuNoCdrYXBfo6sCVKovH64X5hnzbTOXIJ9JzVRzCZ+Py0rwn9FxfKKHSsNY6cOwq6f53/LIkxvdC/+sZi4t3WqBMHqrBIqG8MmW042Dpn5g== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=oss.nxp.com; dmarc=pass action=none header.from=oss.nxp.com; dkim=pass header.d=oss.nxp.com; arc=none X-Received: from VE1PR04MB6702.eurprd04.prod.outlook.com (2603:10a6:803:123::13) by VE1PR04MB6350.eurprd04.prod.outlook.com (2603:10a6:803:122::27) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.3066.19; Tue, 9 Jun 2020 21:21:27 +0000 X-Received: from VE1PR04MB6702.eurprd04.prod.outlook.com ([fe80::81c4:97a6:7592:f225]) by VE1PR04MB6702.eurprd04.prod.outlook.com ([fe80::81c4:97a6:7592:f225%7]) with mapi id 15.20.3088.018; Tue, 9 Jun 2020 21:21:26 +0000 From: Wasim Khan To: devel@edk2.groups.io, meenakshi.aggarwal@nxp.com, V.Sethi@nxp.com, ard.biesheuvel@arm.com, leif@nuviainc.com CC: Wasim Khan Subject: [edk2-devel] [PATCH edk2-platforms 4/8] Silicon/NXP: LS1043A: Add SocGetSvr API Date: Wed, 10 Jun 2020 02:50:55 +0530 Message-ID: <1591737659-8051-5-git-send-email-wasim.khan@oss.nxp.com> In-Reply-To: <1591737659-8051-1-git-send-email-wasim.khan@oss.nxp.com> References: <1591737659-8051-1-git-send-email-wasim.khan@oss.nxp.com> X-ClientProxiedBy: BMXPR01CA0039.INDPRD01.PROD.OUTLOOK.COM (2603:1096:b00:c::25) To VE1PR04MB6702.eurprd04.prod.outlook.com (2603:10a6:803:123::13) MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 X-Received: from wasimk-VirtualBox.nxp.com (157.37.179.16) by BMXPR01CA0039.INDPRD01.PROD.OUTLOOK.COM (2603:1096:b00:c::25) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256) id 15.20.3088.18 via Frontend Transport; Tue, 9 Jun 2020 21:21:24 +0000 X-Originating-IP: [157.37.179.16] X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-HT: Tenant X-MS-Office365-Filtering-Correlation-Id: b513f099-5c48-4bdc-0ce7-08d80cbb115a X-MS-TrafficTypeDiagnostic: VE1PR04MB6350: X-MS-Exchange-SharedMailbox-RoutingAgent-Processed: True X-MS-Exchange-Transport-Forked: True X-Microsoft-Antispam-PRVS: X-MS-Oob-TLC-OOBClassifiers: OLM:1107; X-MS-Exchange-SenderADCheck: 1 X-Microsoft-Antispam-Message-Info: sxxOFFv//QsJcKhGQQ1AzGEJsLgG2qi8Y0IrJ//ySABQ3/WQ8jxbYUFQqDt3A7Y13C1rt4bfZrffwnLDzBdMDJy5LRxW4QHGCQRhro/x5IO1PhG9cn06bSmakmov2h+iIEYvpOF/AI0TvAmhtgE/3QyEY7UbOcgoXm9190e7eyX7DCBAtV4o2Vpk9dCzSRNgZiMsfsLZf4Mg6XjtMRtpUbygdSa7gW8OBz7DcgQedEmDuuYGXoOGwmlUSLjymiWHCH6ZFw3FnCd3zd1t+Uk2QUgcOBukEPuTlY/rxx3j/jDtUM2OdQ4HZ0q7B2XQa0Rqu7b6szRxzgOMlBxKvKLnIw== X-MS-Exchange-AntiSpam-MessageData: r43adaUO7Yx9w7UehD7Nj1uJAZ5hRBdDUIazyKN8PZcybZkG2r8o6Xl1fSu7TsBx7ax/Ii413dkvvHwJwMpXcDKbpeMnpGOJ4+tdH3BtPrOYdcH4MaHPc/EpWx3gEiZxZXQnS5xHijI29dyjloRrHcrZJnl4VxGC9XAlM0aW0i3jVmAM6SJ4er1algKH7P7HV5dZgNE6rP7hc7D1Aasv8VhM5dqadkHNyH+OkXTkL6YGaRK89XvHz+Cj8QBt+dz/xxxwwSUEwN5lQQ6Rk6z+GDNx2Hp6cH25nmPu1M+muWQKvYVTcUqCbBAJm1Sfj/KMPLaEzF8TZQV4VT7InchIy3qzPZQW30a09nM7uzBwN2WNK4L5KJAO9jMpnOOt7/d2NkNgILWlFxIQn4iV2c7yvqYkCadsE/MhRGqlbQ4toe5Fmr6d0UvcApFW5bbEVvh14YHXjpJhvAYN50Et4WxVf4Nh4Q8KCHg1jFxBk+lWrKLNkGPItgbI3R/wrm0yaALa X-OriginatorOrg: oss.nxp.com X-MS-Exchange-CrossTenant-Network-Message-Id: b513f099-5c48-4bdc-0ce7-08d80cbb115a X-MS-Exchange-CrossTenant-OriginalArrivalTime: 09 Jun 2020 21:21:26.5715 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 686ea1d3-bc2b-4c6f-a92c-d99c5c301635 X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: 0dXzadzVjrvxR0gHpwNq0tYnK1tzM7d4Eo0YtcW6asGnEXLdXWLD9Ar6vQAfgJ7aM3OakPGGDHi/OhlkIdl0Ew== X-MS-Exchange-Transport-CrossTenantHeadersStamped: VE1PR04MB6350 Precedence: Bulk List-Unsubscribe: Sender: devel@edk2.groups.io List-Id: Mailing-List: list devel@edk2.groups.io; contact devel+owner@edk2.groups.io Reply-To: devel@edk2.groups.io,wasim.khan@oss.nxp.com X-Gm-Message-State: 4U9SA3293U8aILW1OlZo6Psrx1787277AA= Content-Transfer-Encoding: quoted-printable DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=groups.io; q=dns/txt; s=20140610; t=1591781682; bh=uLBx6Qhlsx2GIRsJHRztTCn8sB3n55VMHOyYeCpEy7g=; h=CC:Content-Type:Date:From:Reply-To:Subject:To; b=XYdDCfhrSNAfjHMSNO1r+u5TJO7w8CAXBHxwdEeGNr1CZRQnLAcUpNIfxmt1imB0yAl mN2bg3Ojx5PvVCjUdm4PKnnt2IYSIpnbtmEeJdRiWJ7WrKqqn2CvHyPwQ4rkR1Iwpqad2 5zbaXoX34d322AAeTFzHbxl8Dtgoe+3mE8g= X-ZohoMail-DKIM: pass (identity @groups.io) Content-Type: text/plain; charset="utf-8" From: Wasim Khan Add SocGetSvr API to get the System Version Register(SVR) Signed-off-by: Wasim Khan --- Silicon/NXP/Include/Library/SocLib.h | 7 +++++++ Silicon/NXP/LS1043A/Library/SocLib/SocLib.c | 14 ++++++++++++++ 2 files changed, 21 insertions(+) diff --git a/Silicon/NXP/Include/Library/SocLib.h b/Silicon/NXP/Include/Lib= rary/SocLib.h index 7b25107e4746..b770671c1331 100644 --- a/Silicon/NXP/Include/Library/SocLib.h +++ b/Silicon/NXP/Include/Library/SocLib.h @@ -49,4 +49,11 @@ SocInit ( VOID ); =20 +/** + Function to get System Version Register(SVR) of SoC +**/ +UINT32 +SocGetSvr ( + VOID + ); #endif // SOC_LIB_H__ diff --git a/Silicon/NXP/LS1043A/Library/SocLib/SocLib.c b/Silicon/NXP/LS10= 43A/Library/SocLib/SocLib.c index 39fb4c14e0b9..3ebbf7df4476 100644 --- a/Silicon/NXP/LS1043A/Library/SocLib/SocLib.c +++ b/Silicon/NXP/LS1043A/Library/SocLib/SocLib.c @@ -64,6 +64,20 @@ SocGetClock ( } =20 /** + Function to get SoC's System Version Register(SVR) + **/ +UINT32 +SocGetSvr ( + VOID + ) +{ + LS1043A_DEVICE_CONFIG *DeviceConfig; + + DeviceConfig =3D (LS1043A_DEVICE_CONFIG *)LS1043A_DCFG_ADDRESS; + return DcfgRead32 ((UINTN)&DeviceConfig->Svr); +} + +/** Function to initialize SoC specific constructs **/ VOID --=20 2.7.4 -=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D- Groups.io Links: You receive all messages sent to this group. View/Reply Online (#61060): https://edk2.groups.io/g/devel/message/61060 Mute This Topic: https://groups.io/mt/74793017/1787277 Group Owner: devel+owner@edk2.groups.io Unsubscribe: https://edk2.groups.io/g/devel/unsub [importer@patchew.org] -=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-