1
0

Merge pull request #1180 from freechipsproject/addrwregdesc

Allow rwReg to pass name and description to RegField for documentation.
This commit is contained in:
Albert Huntington 2018-01-08 09:44:44 -08:00 committed by GitHub
commit 7fc8337cdb
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -100,12 +100,12 @@ object RegField
// This RegField wraps an explicit register
// (e.g. Black-Boxed Register) to create a R/W register.
def rwReg(n: Int, bb: SimpleRegIO) : RegField =
def rwReg(n: Int, bb: SimpleRegIO, name: String = "", description: String = "") : RegField =
RegField(n, bb.q, RegWriteFn((valid, data) => {
bb.en := valid
bb.d := data
Bool(true)
}))
}), name, description)
// Create byte-sized read-write RegFields out of a large UInt register.
// It is updated when any of the bytes are written. Because the RegFields