Loading drivers/tty/serial/msm_smd_tty.c +6 −1 Original line number Diff line number Diff line Loading @@ -492,6 +492,7 @@ exit: static void smd_tty_remove_driver(struct smd_tty_info *info) { struct smd_tty_pfdriver *smd_tty_pfdriverp; bool found_item = false; if (!info) { pr_err("%s on a NULL device\n", __func__); Loading @@ -504,6 +505,7 @@ static void smd_tty_remove_driver(struct smd_tty_info *info) list_for_each_entry(smd_tty_pfdriverp, &smd_tty_pfdriver_list, list) { if (!strcmp(smd_tty_pfdriverp->driver.driver.name, info->ch_name)) { found_item = true; SMD_TTY_INFO("%s:%s Platform driver cnt:%d\n", __func__, info->ch_name, smd_tty_pfdriverp->ref_cnt); Loading @@ -514,8 +516,11 @@ static void smd_tty_remove_driver(struct smd_tty_info *info) break; } } if (!found_item) SMD_TTY_ERR("%s:%s No item found in list.\n", __func__, info->ch_name); if (smd_tty_pfdriverp->ref_cnt == 0) { if (found_item && smd_tty_pfdriverp->ref_cnt == 0) { platform_driver_unregister(&smd_tty_pfdriverp->driver); smd_tty_pfdriverp->driver.probe = NULL; list_del(&smd_tty_pfdriverp->list); Loading Loading
drivers/tty/serial/msm_smd_tty.c +6 −1 Original line number Diff line number Diff line Loading @@ -492,6 +492,7 @@ exit: static void smd_tty_remove_driver(struct smd_tty_info *info) { struct smd_tty_pfdriver *smd_tty_pfdriverp; bool found_item = false; if (!info) { pr_err("%s on a NULL device\n", __func__); Loading @@ -504,6 +505,7 @@ static void smd_tty_remove_driver(struct smd_tty_info *info) list_for_each_entry(smd_tty_pfdriverp, &smd_tty_pfdriver_list, list) { if (!strcmp(smd_tty_pfdriverp->driver.driver.name, info->ch_name)) { found_item = true; SMD_TTY_INFO("%s:%s Platform driver cnt:%d\n", __func__, info->ch_name, smd_tty_pfdriverp->ref_cnt); Loading @@ -514,8 +516,11 @@ static void smd_tty_remove_driver(struct smd_tty_info *info) break; } } if (!found_item) SMD_TTY_ERR("%s:%s No item found in list.\n", __func__, info->ch_name); if (smd_tty_pfdriverp->ref_cnt == 0) { if (found_item && smd_tty_pfdriverp->ref_cnt == 0) { platform_driver_unregister(&smd_tty_pfdriverp->driver); smd_tty_pfdriverp->driver.probe = NULL; list_del(&smd_tty_pfdriverp->list); Loading