diff options
author | Dave Airlie <airlied@redhat.com> | 2012-03-06 13:21:43 +0000 |
---|---|---|
committer | Dave Airlie <airlied@redhat.com> | 2012-03-06 13:21:43 +0000 |
commit | a0dca7e1974bfca57d68c68ee7b3361214871570 (patch) | |
tree | 0065c144eb2f574b30769698dd493691202ce569 /hw | |
parent | 9fc1e1f605155c17228e46ecb0d5c08268eedd2a (diff) |
add entity deallocate
Diffstat (limited to 'hw')
-rw-r--r-- | hw/xfree86/common/xf86Bus.c | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/hw/xfree86/common/xf86Bus.c b/hw/xfree86/common/xf86Bus.c index c7c083c26..d83d8e677 100644 --- a/hw/xfree86/common/xf86Bus.c +++ b/hw/xfree86/common/xf86Bus.c @@ -305,6 +305,16 @@ xf86AllocateEntity(void) return xf86NumEntities - 1; } +void +xf86DeAllocateEntity(int index) +{ + int i; + + for (i = index; i < xf86NumEntities - 1; i++) + memcpy(&xf86Entities[i], &xf86Entities[i + 1], sizeof(EntityPtr)); + xf86Entities--; +} + Bool xf86IsEntityPrimary(int entityIndex) { |