Definitions for the TileLink packets.
Base class of TileLink edges.
class TLEdge(
client: TLClientPortParameters,
manager: TLManagerPortParameters)
extends TLEdgeParameters(client, manager)
-
isAligned
(address: UInt, lgSize: UInt) => Bool
Whetheraddress
is aligned to1 << lgSize
. -
mask
(address: UInt, lgSize: UInt) => UInt
Generate mask for a TileLink transaction. -
staticHasData
(TLChannel) => Option[Boolean]
Compile time analysis, return whether data is needed for a channel.
Yes:Some(true)
;
No:Some(false)
;
Unknown:None
. -
isRequest
(TLChannel) => Bool
Whether the transaction is a request (Put, AMO, Get, Hint, Acquire, Probe, Release or Grant). -
isResponse
(TLChannel) => Bool
Whether the transaction is a response (AccessAck, ProbeAck, HintAck, Grant, ReleaseAck, GrantAck). -
hasData
(TLChannel) => Bool
Whether the transaction has data. See the "type of TileLink transactions." -
Helper functions to get transaction fields
opcode, param, size, data, and source
(TLDataChannel) => UInt
mask, full_mask, and address
(TLAddrChannel) => UInt
addr_hi
(UInt) => UInt
or(TLAddrChannel) => UInt
MSBs of an address (to a beat). -
addr_lo
(UInt) => UInt
or(TLAddrChannel) => UInt
LSBs of an address (inside a beat). -
numBeats
(TLChannel) => UInt
Number of beats of this transaction. -
numBeats1
(TLChannel) => UInt
Number of beats - 1. (AXI style) -
Helpers for counting beats
firstlastHelper
(TLChannel, fire:Bool) => (first:Bool, last:Bool, done: Bool, count:UInt)
first, last and done
(TLChannel, fire:Bool) => Bool
(DecoupledIO[TLChannel]) => Bool
(ValidIO[TLChannel]) => Bool
firstlast
(TLChannel, fire:Bool) => (first:Bool, last:Bool, done: Bool)
(DecoupledIO[TLChannel]) => (first:Bool, last:Bool, done: Bool)
(ValidIO[TLChannel]) => (first:Bool, last:Bool, done: Bool)
count
(TLChannel, fire:Bool) => (first:Bool, last:Bool, done: Bool, count:UInt)
(DecoupledIO[TLChannel]) => (first:Bool, last:Bool, done: Bool, count:UInt)
(ValidIO[TLChannel]) => (first:Bool, last:Bool, done: Bool, count:UInt)
addr_inc
(TLChannel, fire:Bool) => (first:Bool, last:Bool, done: Bool, addr:UInt)
(DecoupledIO[TLChannel]) => (first:Bool, last:Bool, done: Bool, addr:UInt)
(ValidIO[TLChannel]) => (first:Bool, last:Bool, done: Bool, addr:UInt)
The return valueaddr
is the address inside a burst (addr = count << log2Ceil(beatBytes)
)
Packet generator for downwards channels (A/C/E).
class TLEdgeOut(
client: TLClientPortParameters,
manager: TLManagerPortParameters)
extends TLEdge(client, manager)
Arguments:
name | type | description |
---|---|---|
fromSrc | UInt | source identifier |
toAddr | UInt | target address |
lgSize | UInt | transaction size in log2 bytes |
growPerm | UInt | parameter for Acquire |
shrinkPerm | UInt | parameter for Release |
reportPerm | UInt | parameter for ProbeAck |
param | UInt | parameter for Hint |
data | UInt | payload |
mask | UInt | write byte mask |
atomic | UInt | type of atomic packets |
error | Bool | error acknowledgement |
Return value:
name | type | description |
---|---|---|
legal | Boolean | transaction type is supported and the target address is legal |
packetA | TLBundleA | generated packet for channel A |
packetC | TLBundleC | generated packet for channel C |
packetE | TLBundleE | generated packet for channel E |
-
Packet generators for channel A
Acquire
(fromSrc, toAddr, lgSize, growPerm) => (legal, packetA)
Get(fromSrc, toAddr, lgSize) => (legal, packetA)
Put(fromSrc, toAddr, lgSize, data) => (legal, packetA)
Put(fromSrc, toAddr, lgSize, data, mask) => (legal, packetA)
Arithmetic(fromSrc, toAddr, lgSize, data, atomic) => (legal, packetA)
Logical(fromSrc, toAddr, lgSize, data, atomic) => (legal, packetA)
Hint(fromSrc, toAddr, lgSize, param) => (legal, packetA)
-
Packet generators for channel C
Release
(fromSrc, toAddr, lgSize, shrinkPerm) => (legal, packetC)
(fromSrc, toAddr, lgSize, shrinkPerm, data) => (legal, packetC)
ProbeAck
(b: TLBundleB, reportPerm) => packetC
(b: TLBundleB, reportPerm, data: UInt) => packetC
(fromSrc, toAddr, lgSize, reportPerm) => packetC
(fromSrc, toAddr, lgSize, reportPerm, data) => packetC
AccessAck
(b: TLBundleB) => packetC
(b: TLBundleB, data: UInt) => packetC
(b: TLBundleB, error: Bool) => packetC
(b: TLBundleB, data, error) => packetC
(fromSrc, toAddr, lgSize) => packetC
(fromSrc, toAddr, lgSize, data) => packetC
(fromSrc, toAddr, lgSize, error) => packetC
(fromSrc, toAddr, lgSize, data, error) => packetC
HintAck(b: TLBundleB) => packetC
HintAck(fromSrc, toAddr, lgSize) => packetC
-
Packet generators for Channel E
GrantAck
(b: TLBundleD) => packetE
GrantAck(toSink: UInt) => packetE
Packet generator for upwards channels (B/D).
class TLEdgeIn(
client: TLClientPortParameters,
manager: TLManagerPortParameters)
extends TLEdge(client, manager)
Arguments:
name | type | description |
---|---|---|
fromAddr | UInt | source address |
fromSink | UInt | sink identifier |
toSrc | UInt | target identifier |
lgSize | UInt | transaction size in log2 bytes |
capPerm | UInt | parameter for Probe/Grant |
param | UInt | parameter for Hint |
data | UInt | payload |
mask | UInt | write byte mask |
atomic | UInt | type of atomic packets |
error | Bool | error acknowledgement |
Return value:
name | type | description |
---|---|---|
legal | Boolean | transaction type is supported and the target address is legal |
packetB | TLBundleB | generated packet for channel B |
packetD | TLBundleD | generated packet for channel D |
-
Packet generators for channel B
Probe
(fromAddr, toSrc, lgSize, capPerm) => (legal, packetB)
Get(fromAddr, toSrc, lgSize) => (legal, packetB)
Put(fromAddr, toSrc, lgSize, data) => (legal, packetB)
Put(fromAddr, toSrc, lgSize, data, mask) => (legal, packetB)
Arithmetic(fromAddr, toSrc, lgSize, data, atomic) => (legal, packetB)
Logical(fromAddr, toSrc, lgSize, data, atomic) => (legal, packetB)
Hint(fromAddr, toSrc, lgSize, param) => (legal, packetB)
-
Packet generators for channel D
Grant
(fromSink, toSrc, lgSize, capPerm) => packetD
(fromSink, toSrc, lgSize, capPerm, error) => packetD
(fromSink, toSrc, lgSize, capPerm, data) => packetD
(fromSink, toSrc, lgSize, capPerm, data, error) => packetD
ReleaseAck
(c: TLBundleC) => packetD
(toSrc, lgSize) => packetD
AccessAck
(a: TLBundleA) => packetD
(a: TLBundleA, data) => packetD
(a: TLBundleA, error) => packetD
(a: TLBundleA, data, error) => packetD
(toSrc, lgSize) => packetD
(toSrc, lgSize, data) => packetD
(toSrc, lgSize, error) => packetD
(toSrc, lgSize, data, error) => packetD
HintAck
(a:TLBundleA) => packetD
HintAck(toSrc, lgSize) => packetD
Last updated: 07/08/2017
CC BY-NC-SA 4.0, © (2017) Wei Song
Apache 2.0, © (2016-2017) SiFive, Inc
BSD, © (2012-2014, 2016) The Regents of the University of California (Regents)