@@ -1078,19 +1078,20 @@ int drm_atomic_set_property(struct drm_atomic_state *state,
10781078 }
10791079
10801080 if (async_flip ) {
1081- /* check if the prop does a nop change */
1082- if ((prop != config -> prop_fb_id &&
1083- prop != config -> prop_in_fence_fd &&
1084- prop != config -> prop_fb_damage_clips )) {
1085- ret = drm_atomic_plane_get_property (plane , plane_state ,
1086- prop , & old_val );
1087- ret = drm_atomic_check_prop_changes (ret , old_val , prop_value , prop );
1088- }
1081+ /* no-op changes are always allowed */
1082+ ret = drm_atomic_plane_get_property (plane , plane_state ,
1083+ prop , & old_val );
1084+ ret = drm_atomic_check_prop_changes (ret , old_val , prop_value , prop );
10891085
1090- /* ask the driver if this non-primary plane is supported */
1091- if (plane -> type != DRM_PLANE_TYPE_PRIMARY ) {
1092- ret = - EINVAL ;
1086+ /* fail everything that isn't no-op or a pure flip */
1087+ if (ret && prop != config -> prop_fb_id &&
1088+ prop != config -> prop_in_fence_fd &&
1089+ prop != config -> prop_fb_damage_clips ) {
1090+ break ;
1091+ }
10931092
1093+ if (ret && plane -> type != DRM_PLANE_TYPE_PRIMARY ) {
1094+ /* ask the driver if this non-primary plane is supported */
10941095 if (plane_funcs && plane_funcs -> atomic_async_check )
10951096 ret = plane_funcs -> atomic_async_check (plane , state , true);
10961097
0 commit comments