.. | .. |
---|
98 | 98 | if (!state->planes) |
---|
99 | 99 | goto fail; |
---|
100 | 100 | |
---|
| 101 | + /* |
---|
| 102 | + * Because drm_atomic_state can be committed asynchronously we need our |
---|
| 103 | + * own reference and cannot rely on the on implied by drm_file in the |
---|
| 104 | + * ioctl call. |
---|
| 105 | + */ |
---|
| 106 | + drm_dev_get(dev); |
---|
101 | 107 | state->dev = dev; |
---|
102 | 108 | |
---|
103 | 109 | DRM_DEBUG_ATOMIC("Allocated atomic state %p\n", state); |
---|
.. | .. |
---|
257 | 263 | void __drm_atomic_state_free(struct kref *ref) |
---|
258 | 264 | { |
---|
259 | 265 | struct drm_atomic_state *state = container_of(ref, typeof(*state), ref); |
---|
260 | | - struct drm_mode_config *config = &state->dev->mode_config; |
---|
| 266 | + struct drm_device *dev = state->dev; |
---|
| 267 | + struct drm_mode_config *config = &dev->mode_config; |
---|
261 | 268 | |
---|
262 | 269 | drm_atomic_state_clear(state); |
---|
263 | 270 | |
---|
.. | .. |
---|
269 | 276 | drm_atomic_state_default_release(state); |
---|
270 | 277 | kfree(state); |
---|
271 | 278 | } |
---|
| 279 | + |
---|
| 280 | + drm_dev_put(dev); |
---|
272 | 281 | } |
---|
273 | 282 | EXPORT_SYMBOL(__drm_atomic_state_free); |
---|
274 | 283 | |
---|
.. | .. |
---|
1010 | 1019 | drm_printf(p, "connector[%u]: %s\n", connector->base.id, connector->name); |
---|
1011 | 1020 | drm_printf(p, "\tcrtc=%s\n", state->crtc ? state->crtc->name : "(null)"); |
---|
1012 | 1021 | drm_printf(p, "\tself_refresh_aware=%d\n", state->self_refresh_aware); |
---|
| 1022 | + drm_printf(p, "\tmax_requested_bpc=%d\n", state->max_requested_bpc); |
---|
1013 | 1023 | |
---|
1014 | 1024 | if (connector->connector_type == DRM_MODE_CONNECTOR_WRITEBACK) |
---|
1015 | 1025 | if (state->writeback_job && state->writeback_job->fb) |
---|