msm: mdss: fix possible overflow errors in panel_debug_base_reg_read
The panel_reg_buf is a dynamically allocated buffer of size reg_buf_len so checking sizeof(panel_reg_buf) is incorrect. Using scnprintf will ensure that len is at most reg_buf_len - 1 after all the prints. This allows sanity checks to be removed which were incorrectly skipping clock disable, resulting in an extra clock reference count. Change-Id: Ic3bb685c7b83eefef7bc207ad93d6a2a9e36fd33 Signed-off-by:Patrick Auchter <auchter@motorola.com> Signed-off-by:
Veera Sundaram Sankaran <veeras@codeaurora.org> (cherry picked from commit 89bede0751357bc24701b8ebfe326d3e6bb46683)
Loading
Please register or sign in to comment