diff options
author | David Herrmann <dh.herrmann@gmail.com> | 2014-08-29 06:12:42 -0400 |
---|---|---|
committer | Dave Airlie <airlied@redhat.com> | 2014-09-10 03:42:17 -0400 |
commit | 1e444be0ef1bda2b180ecdedfa4c5d32bf236a5d (patch) | |
tree | 711321e9be107eb0ee0220176cbe912b14864e76 /drivers/gpu/drm/drm_pci.c | |
parent | d0a39164b6adad0cec5046b6aad6b590cc9466cc (diff) |
drm: drop unused drm_master->unique_size
This field is unused and there is really no reason to optimize
unique-allocations. Drop it.
Signed-off-by: David Herrmann <dh.herrmann@gmail.com>
Reviewed-by: Thierry Reding <treding@nvidia.com>
Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Signed-off-by: Dave Airlie <airlied@redhat.com>
Diffstat (limited to 'drivers/gpu/drm/drm_pci.c')
-rw-r--r-- | drivers/gpu/drm/drm_pci.c | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/drivers/gpu/drm/drm_pci.c b/drivers/gpu/drm/drm_pci.c index 8efea6b4602b..e266927bb9f1 100644 --- a/drivers/gpu/drm/drm_pci.c +++ b/drivers/gpu/drm/drm_pci.c | |||
@@ -138,7 +138,6 @@ static int drm_pci_set_busid(struct drm_device *dev, struct drm_master *master) | |||
138 | return -ENOMEM; | 138 | return -ENOMEM; |
139 | 139 | ||
140 | master->unique_len = strlen(master->unique); | 140 | master->unique_len = strlen(master->unique); |
141 | master->unique_size = master->unique_len + 1; | ||
142 | return 0; | 141 | return 0; |
143 | } | 142 | } |
144 | 143 | ||
@@ -149,8 +148,7 @@ int drm_pci_set_unique(struct drm_device *dev, | |||
149 | int domain, bus, slot, func, ret; | 148 | int domain, bus, slot, func, ret; |
150 | 149 | ||
151 | master->unique_len = u->unique_len; | 150 | master->unique_len = u->unique_len; |
152 | master->unique_size = u->unique_len + 1; | 151 | master->unique = kmalloc(master->unique_len + 1, GFP_KERNEL); |
153 | master->unique = kmalloc(master->unique_size, GFP_KERNEL); | ||
154 | if (!master->unique) { | 152 | if (!master->unique) { |
155 | ret = -ENOMEM; | 153 | ret = -ENOMEM; |
156 | goto err; | 154 | goto err; |