From a9d9e2743db3b6963ead335d0de20714a4c51d66 Mon Sep 17 00:00:00 2001 From: Mohit Wani Date: Tue, 21 Apr 2020 12:10:21 -0700 Subject: [PATCH 1/5] Object model updates for AHB and AXI --- .../diplomaticobjectmodel/model/OMPorts.scala | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/src/main/scala/diplomaticobjectmodel/model/OMPorts.scala b/src/main/scala/diplomaticobjectmodel/model/OMPorts.scala index 5a1bc5b47c..37310a5719 100644 --- a/src/main/scala/diplomaticobjectmodel/model/OMPorts.scala +++ b/src/main/scala/diplomaticobjectmodel/model/OMPorts.scala @@ -41,17 +41,17 @@ trait AMBA extends OMProtocol case class AXI4( specification: Option[OMSpecification], - _types: Seq[String] = Seq("AXI4", "AMBA", "OMProtocol") + _types: Seq[String] = Seq("AXI", "AMBA", "OMProtocol") ) extends AMBA case class AXI4_Lite( specification: Option[OMSpecification], - val _types: Seq[String] = Seq("AXI4_Lite", "AMBA", "OMProtocol") + val _types: Seq[String] = Seq("AXI", "AMBA", "OMProtocol") ) extends AMBA case class AHB_Lite( specification: Option[OMSpecification], - val _types: Seq[String] = Seq("AHB_Lite", "AMBA", "OMProtocol") + val _types: Seq[String] = Seq("AHB", "AMBA", "OMProtocol") ) extends AMBA case class AHB( @@ -125,15 +125,15 @@ case class SystemPort( object OMPortMaker { val protocolSpecifications = Map[ProtocolType, String]( - AHBProtocol -> "AMBA 3 AHB-Lite Protocol", - AXI4Protocol -> "AMBA 3 AXI4-Lite Protocol", - APBProtocol -> "AMBA 3 APB Protocol", + AHBProtocol -> "AHB Protocol", + AXI4Protocol -> "AXI Protocol", + APBProtocol -> "APB Protocol", TLProtocol -> "TileLink specification" ) val protocolSpecificationVersions = Map[ProtocolType, String]( - AHBProtocol -> "1.0", - AXI4Protocol -> "1.0", + AHBProtocol -> "3", + AXI4Protocol -> "4", APBProtocol -> "1.0", TLProtocol -> "1.8" ) From 8b1b785bf583c51058c93a03db111d3143170f62 Mon Sep 17 00:00:00 2001 From: Mohit Wani Date: Tue, 21 Apr 2020 18:20:14 -0700 Subject: [PATCH 2/5] reverting type for AHB --- src/main/scala/diplomaticobjectmodel/model/OMPorts.scala | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/main/scala/diplomaticobjectmodel/model/OMPorts.scala b/src/main/scala/diplomaticobjectmodel/model/OMPorts.scala index 37310a5719..ab972bfe34 100644 --- a/src/main/scala/diplomaticobjectmodel/model/OMPorts.scala +++ b/src/main/scala/diplomaticobjectmodel/model/OMPorts.scala @@ -51,7 +51,7 @@ case class AXI4_Lite( case class AHB_Lite( specification: Option[OMSpecification], - val _types: Seq[String] = Seq("AHB", "AMBA", "OMProtocol") + val _types: Seq[String] = Seq("AHB_Lite", "AMBA", "OMProtocol") ) extends AMBA case class AHB( From fc3edef893200e6c7fcbc292976c406206cb857e Mon Sep 17 00:00:00 2001 From: Mohit Wani Date: Tue, 21 Apr 2020 19:55:56 -0700 Subject: [PATCH 3/5] revering back AXI type changes --- src/main/scala/diplomaticobjectmodel/model/OMPorts.scala | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/main/scala/diplomaticobjectmodel/model/OMPorts.scala b/src/main/scala/diplomaticobjectmodel/model/OMPorts.scala index ab972bfe34..2f0b9f1434 100644 --- a/src/main/scala/diplomaticobjectmodel/model/OMPorts.scala +++ b/src/main/scala/diplomaticobjectmodel/model/OMPorts.scala @@ -41,12 +41,12 @@ trait AMBA extends OMProtocol case class AXI4( specification: Option[OMSpecification], - _types: Seq[String] = Seq("AXI", "AMBA", "OMProtocol") + _types: Seq[String] = Seq("AXI4", "AMBA", "OMProtocol") ) extends AMBA case class AXI4_Lite( specification: Option[OMSpecification], - val _types: Seq[String] = Seq("AXI", "AMBA", "OMProtocol") + val _types: Seq[String] = Seq("AXI4_Lite", "AMBA", "OMProtocol") ) extends AMBA case class AHB_Lite( From ed06bba19d73e96a7a027e990619de8176c8918a Mon Sep 17 00:00:00 2001 From: Mohit Wani Date: Thu, 23 Apr 2020 16:58:16 -0700 Subject: [PATCH 4/5] Fixes for FREQ_48 --- .../diplomaticobjectmodel/model/OMPorts.scala | 35 +++++++++++-------- 1 file changed, 20 insertions(+), 15 deletions(-) diff --git a/src/main/scala/diplomaticobjectmodel/model/OMPorts.scala b/src/main/scala/diplomaticobjectmodel/model/OMPorts.scala index 2f0b9f1434..f3a80a2362 100644 --- a/src/main/scala/diplomaticobjectmodel/model/OMPorts.scala +++ b/src/main/scala/diplomaticobjectmodel/model/OMPorts.scala @@ -124,12 +124,17 @@ case class SystemPort( _types: Seq[String] = Seq("SystemPort", "OutboundPort", "OMPort", "OMDevice", "OMComponent", "OMCompoundType")) extends OutboundPort object OMPortMaker { - val protocolSpecifications = Map[ProtocolType, String]( - AHBProtocol -> "AHB Protocol", - AXI4Protocol -> "AXI Protocol", - APBProtocol -> "APB Protocol", - TLProtocol -> "TileLink specification" - ) + val protocolSpecifications: (ProtocolType, SubProtocolType) => String = { + case (AHBProtocol, AHBLiteSubProtocol) => "AHB Lite Protocol" + case (AHBProtocol, AHBFullSubProtocol) => "AHB Full Protocol" + case (AXI4Protocol, AXI4SubProtocol) => "AXI Protocol" + case (AXI4Protocol, AXI4LiteSubProtocol) => "AXI Lite Protocol" + case (APBProtocol, APBSubProtocol) => "APB Protocol" + case (TLProtocol, TL_UHSubProtocol) => "TileLink specification" + case (TLProtocol, TL_ULSubProtocol) => "TileLink specification" + case (TLProtocol, TL_CSubProtocol) => "TileLink specification" + case _ => "Invalid Protocol" + } val protocolSpecificationVersions = Map[ProtocolType, String]( AHBProtocol -> "3", @@ -138,7 +143,7 @@ object OMPortMaker { TLProtocol -> "1.8" ) - def specVersion(protocol: ProtocolType, version: String): Option[OMSpecification] = Some(OMSpecification(protocolSpecifications(protocol), version)) + def specVersion(protocol: ProtocolType, subProtocol: SubProtocolType, version: String): Option[OMSpecification] = Some(OMSpecification(protocolSpecifications(protocol, subProtocol), version)) val portNames = Map[PortType, String]( SystemPortType -> "System Port", @@ -158,14 +163,14 @@ object OMPortMaker { val documentationName = portNames(portType) val omProtocol = (protocol, subProtocol) match { - case (AXI4Protocol, AXI4SubProtocol) => AXI4(specification = specVersion(protocol, version)) - case (AXI4Protocol, AXI4LiteSubProtocol) => AXI4_Lite(specification = specVersion(protocol, version)) - case (AHBProtocol, AHBLiteSubProtocol) => AHB_Lite(specification = specVersion(protocol, version)) - case (AHBProtocol, AHBFullSubProtocol) => AHB(specification = specVersion(protocol, version)) - case (APBProtocol, APBSubProtocol) => APB(specification = specVersion(protocol, version)) - case (TLProtocol, TL_UHSubProtocol) => TL_UH(specification = specVersion(protocol, version)) - case (TLProtocol, TL_ULSubProtocol) => TL_UL(specification = specVersion(protocol, version)) - case (TLProtocol, TL_CSubProtocol) => TL_C(specification = specVersion(protocol, version)) + case (AXI4Protocol, AXI4SubProtocol) => AXI4(specification = specVersion(protocol, subProtocol, version)) + case (AXI4Protocol, AXI4LiteSubProtocol) => AXI4_Lite(specification = specVersion(protocol, subProtocol, version)) + case (AHBProtocol, AHBLiteSubProtocol) => AHB_Lite(specification = specVersion(protocol, subProtocol, version)) + case (AHBProtocol, AHBFullSubProtocol) => AHB(specification = specVersion(protocol, subProtocol, version)) + case (APBProtocol, APBSubProtocol) => APB(specification = specVersion(protocol, subProtocol, version)) + case (TLProtocol, TL_UHSubProtocol) => TL_UH(specification = specVersion(protocol, subProtocol, version)) + case (TLProtocol, TL_ULSubProtocol) => TL_UL(specification = specVersion(protocol, subProtocol, version)) + case (TLProtocol, TL_CSubProtocol) => TL_C(specification = specVersion(protocol, subProtocol, version)) case _ => throw new IllegalArgumentException(s"protocol $protocol, subProtocol $subProtocol") } From fdda0cafb696388329382c94ed5d97e0d89bd4f1 Mon Sep 17 00:00:00 2001 From: Mohit Wani <38992045+mhtwn@users.noreply.github.com> Date: Mon, 27 Apr 2020 11:17:09 -0700 Subject: [PATCH 5/5] Update OMPorts.scala --- src/main/scala/diplomaticobjectmodel/model/OMPorts.scala | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/main/scala/diplomaticobjectmodel/model/OMPorts.scala b/src/main/scala/diplomaticobjectmodel/model/OMPorts.scala index f3a80a2362..9420163b9c 100644 --- a/src/main/scala/diplomaticobjectmodel/model/OMPorts.scala +++ b/src/main/scala/diplomaticobjectmodel/model/OMPorts.scala @@ -130,9 +130,9 @@ object OMPortMaker { case (AXI4Protocol, AXI4SubProtocol) => "AXI Protocol" case (AXI4Protocol, AXI4LiteSubProtocol) => "AXI Lite Protocol" case (APBProtocol, APBSubProtocol) => "APB Protocol" - case (TLProtocol, TL_UHSubProtocol) => "TileLink specification" - case (TLProtocol, TL_ULSubProtocol) => "TileLink specification" - case (TLProtocol, TL_CSubProtocol) => "TileLink specification" + case (TLProtocol, TL_UHSubProtocol) => "TileLink Protocol" + case (TLProtocol, TL_ULSubProtocol) => "TileLink Protocol" + case (TLProtocol, TL_CSubProtocol) => "TileLink Protocol" case _ => "Invalid Protocol" }