@@ -2105,12 +2105,12 @@ static bool dcn30_internal_validate_bw(
21052105
21062106 if (split [i ]) {
21072107 if (odm ) {
2108- if (split [i ] == 4 && old_pipe -> next_odm_pipe -> next_odm_pipe )
2108+ if (split [i ] == 4 && old_pipe -> next_odm_pipe && old_pipe -> next_odm_pipe -> next_odm_pipe )
21092109 old_index = old_pipe -> next_odm_pipe -> next_odm_pipe -> pipe_idx ;
21102110 else if (old_pipe -> next_odm_pipe )
21112111 old_index = old_pipe -> next_odm_pipe -> pipe_idx ;
21122112 } else {
2113- if (split [i ] == 4 && old_pipe -> bottom_pipe -> bottom_pipe &&
2113+ if (split [i ] == 4 && old_pipe -> bottom_pipe && old_pipe -> bottom_pipe -> bottom_pipe &&
21142114 old_pipe -> bottom_pipe -> bottom_pipe -> plane_state == old_pipe -> plane_state )
21152115 old_index = old_pipe -> bottom_pipe -> bottom_pipe -> pipe_idx ;
21162116 else if (old_pipe -> bottom_pipe &&
@@ -2150,10 +2150,12 @@ static bool dcn30_internal_validate_bw(
21502150 goto validate_fail ;
21512151 newly_split [pipe_4to1 -> pipe_idx ] = true;
21522152
2153- if (odm && old_pipe -> next_odm_pipe -> next_odm_pipe -> next_odm_pipe )
2153+ if (odm && old_pipe -> next_odm_pipe && old_pipe -> next_odm_pipe -> next_odm_pipe
2154+ && old_pipe -> next_odm_pipe -> next_odm_pipe -> next_odm_pipe )
21542155 old_index = old_pipe -> next_odm_pipe -> next_odm_pipe -> next_odm_pipe -> pipe_idx ;
2155- else if (!odm && old_pipe -> bottom_pipe -> bottom_pipe -> bottom_pipe &&
2156- old_pipe -> bottom_pipe -> bottom_pipe -> bottom_pipe -> plane_state == old_pipe -> plane_state )
2156+ else if (!odm && old_pipe -> bottom_pipe && old_pipe -> bottom_pipe -> bottom_pipe &&
2157+ old_pipe -> bottom_pipe -> bottom_pipe -> bottom_pipe &&
2158+ old_pipe -> bottom_pipe -> bottom_pipe -> bottom_pipe -> plane_state == old_pipe -> plane_state )
21572159 old_index = old_pipe -> bottom_pipe -> bottom_pipe -> bottom_pipe -> pipe_idx ;
21582160 else
21592161 old_index = -1 ;
0 commit comments