tty: n_smux: Add support for ldisc removal during SSR

If subsystem restart (SSR) is in progress and the line discipline is
removed, then the platform devices may get removed twice leading to a
kernel panic.

Add conditional logic to properly handle platform device removal if line
discipline is removed while a subsystem restart is in progress.

CRs-Fixed: 386491
Change-Id: I1ddc89175509e333098f849b0f76e09660644573
Signed-off-by: Eric Holmberg <eholmber@codeaurora.org>
1 file changed