Merge "disp: msm: dsi: fix bl->raw_bd NULL pointer dereference"

This commit is contained in:
qctecmdr
2024-05-15 01:20:51 -07:00
committed by Gerrit - the friendly Code Review server

View File

@@ -670,7 +670,7 @@ static u32 dsi_panel_get_brightness(struct dsi_backlight_config *bl)
switch (bl->type) { switch (bl->type) {
case DSI_BACKLIGHT_WLED: case DSI_BACKLIGHT_WLED:
/* Try to query the backlight level from the backlight device */ /* Try to query the backlight level from the backlight device */
if (bd->ops && bd->ops->get_brightness) if (bd && bd->ops && bd->ops->get_brightness)
cur_bl_level = bd->ops->get_brightness(bd); cur_bl_level = bd->ops->get_brightness(bd);
break; break;
case DSI_BACKLIGHT_DCS: case DSI_BACKLIGHT_DCS: