From 99ed0877ac1a2326dfc66907af948631356c8574 Mon Sep 17 00:00:00 2001 From: Florent Kermarrec Date: Wed, 18 Sep 2019 10:47:54 +0200 Subject: [PATCH] csr: add description to CSRStorage/CSRStatus attributes (thanks xobs) --- litex/soc/interconnect/csr.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/litex/soc/interconnect/csr.py b/litex/soc/interconnect/csr.py index e3d2f1ae..228290fa 100644 --- a/litex/soc/interconnect/csr.py +++ b/litex/soc/interconnect/csr.py @@ -280,6 +280,7 @@ class CSRStatus(_CompoundCSR): size = self.fields.get_size() reset = self.fields.get_reset() _CompoundCSR.__init__(self, size, name) + self.description = description self.status = Signal(self.size, reset=reset) for field in fields: self.comb += self.status[field.offset:field.offset + field.size].eq(getattr(self.fields, field.name)) @@ -350,6 +351,7 @@ class CSRStorage(_CompoundCSR): size = self.fields.get_size() reset = self.fields.get_reset() _CompoundCSR.__init__(self, size, name) + self.description = description self.storage = Signal(self.size, reset=reset) self.atomic_write = atomic_write self.re = Signal() -- 2.30.2