[PATCH v3 0/3] MIPS: SiByte: Fix serial device regressions

"Maciej W. Rozycki" <[email protected]> Thu, 6 Aug 2026 11:54:06 +0100 (BST)
Newsgroups org.kernel.vger.linux-serial,org.kernel.vger.linux-kernel,org.kernel.vger.linux-mips
Message-ID <[email protected]>
Hi,

 In this v3 of the series compared to v2 changes 3/6 through 6/6 have been 
dropped as not meant for backporting, along with the relevant submission 
cc recipients.  Additionally the delay loop introduced with 1/6 has been 
fixed to work correctly early in boot.  The relevant parts of the original 
cover letter follow.

 Starting from commit 84a9582fd203 ("serial: core: Start managing serial 
controllers to enable runtime PM") the driver for the SiByte onchip DUART 
has stopped working due to a null pointer dereference in the serial core, 
which means a kernel crash at bootstrap if the driver has been enabled, as 
is usually the case for the system console.

 This patch series addresses the issue by switching the driver away from 
legacy probing to using platform devices.  A notable consequence of this 
is the serial console is only switched from the bootconsole handler that 
uses firmware calls over to our serial driver at the time the driver is 
being properly brought up.  This causes messages to be produced to the 
console between the device reset and console setup, which in turn causes 
the firmware still being called via the bootconsole handler to loop 
forever owing to the transmitter having been disabled.

 Therefore introductory change 2/3 is included to fix the issue by doing a 
rudimentary device setup right after reset, using parameters compatible 
with those used by the firmware (115200n8).  There is auxiliary change 1/3 
included as well that prevents message corruption from happening at reset, 
which becomes more prominent due to the change in timing, with the driver 
switch to the platform device, of messages produced to the console.

 See individual change descriptions for details.  Verified with a SWARM
(BCM91250A) system.

 Please apply.

 Previous iterations:

- v2 at: <https://lore.kernel.org/r/[email protected]/>.

- v1 at: <https://lore.kernel.org/r/[email protected]/>.

  Maciej