Re: [PATCH 1/2] tty: moxa: unwind tty driver if PCI registration fails
From: Myeonghun Pak
Date: Tue Aug 04 2026 - 10:05:12 EST
Hi Jiri and Greg,
Thanks for the review. I agree that removing the whole MOXA driver is
the better direction, which supersedes this patch. Please drop/ignore
this patch.
Best regards,
Myeonghun
2026년 8월 3일 (월) 오후 9:41, Greg Kroah-Hartman <gregkh@xxxxxxxxxxxxxxxxxxx>님이 작성:
>
> On Mon, Aug 03, 2026 at 08:06:58AM +0200, Jiri Slaby wrote:
> > On 31. 07. 26, 18:18, Myeonghun Pak wrote:
> > > moxa_init() registers the tty driver before registering the PCI driver.
> > > If pci_register_driver() fails, module initialization returns without
> > > unregistering the tty driver or dropping its reference. moxa_exit() is
> > > not called after a failed module initialization.
> > >
> > > Unregister the tty driver and drop its reference before returning the
> > > PCI registration error.
> > I think, we should remove the whole driver instead:
> > https://lore.kernel.org/all/2da84e36-7ac6-407d-8e08-edca82f4cbce@xxxxxxxxxx/
>
> I agree, I'll submit a patch to just drop it.
>
> thanks,
>
> greg k-h