At the current point where ret is being checked for non-zero it has not changed since it was initialized to zero, hence the check and the label unref are redundant and can be removed.
Unified · Split
| @@ -198,8 +198,6 @@ static int vc4_drm_bind(struct device *dev) · 197 unmodified lines | ||
| 198 | 198 | vc4_bo_cache_init(drm); |
| 199 | 199 | |
| 200 | 200 | drm_mode_config_init(drm); |
| 201 | − if (ret) | |
| 202 | − goto unref; | |
| 203 | 201 | |
| 204 | 202 | vc4_gem_init(drm); |
| 205 | 203 | |
| @@ -233,7 +231,6 @@ unbind_all: · 27 unmodified lines | ||
| 233 | 231 | component_unbind_all(dev, drm); |
| 234 | 232 | gem_destroy: |
| 235 | 233 | vc4_gem_destroy(drm); |
| 236 | −unref: | |
| 237 | 234 | drm_dev_unref(drm); |
| 238 | 235 | vc4_bo_cache_destroy(drm); |
| 239 | 236 | return ret; |