mirror of
https://github.com/enjoy-digital/litex.git
synced 2025-01-04 09:52:26 -05:00
generic_platform: add a method to delete a constraint
This commit is contained in:
parent
000aabf85b
commit
0278d3eee8
1 changed files with 8 additions and 0 deletions
|
@ -190,6 +190,11 @@ class ConstraintManager:
|
|||
def add_extension(self, io):
|
||||
self.available.extend(io)
|
||||
|
||||
def delete(self, signal):
|
||||
for res, obj in self.matched:
|
||||
if obj == signal:
|
||||
self.matched.remove((res, obj))
|
||||
|
||||
def request(self, name, number=None, loose=False):
|
||||
resource = _lookup(self.available, name, number, loose)
|
||||
if resource is None:
|
||||
|
@ -313,6 +318,9 @@ class GenericPlatform:
|
|||
def request(self, *args, **kwargs):
|
||||
return self.constraint_manager.request(*args, **kwargs)
|
||||
|
||||
def delete(self, *args, **kwargs):
|
||||
return self.constraint_manager.delete(*args, **kwargs)
|
||||
|
||||
def request_all(self, *args, **kwargs):
|
||||
return self.constraint_manager.request_all(*args, **kwargs)
|
||||
|
||||
|
|
Loading…
Reference in a new issue