From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 2549F13A863; Fri, 6 Dec 2024 15:16:07 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1733498167; cv=none; b=iFgYFpXciCzeqrZ5Z9M1LKNU/qRX8jsxUFcxI3j6Vtk0eoR+vwmhAx1Hui6hnAVEkh6j97KxaIp6PfFEUY3kqBve3e3sgNYxmejDwmxRDQOrs7XFF5JFKXc8Fb1jAbIVtKDHwxwEe4f8BFMvgx+pRrXzg9Sz0R3V0dJ27xVhXPs= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1733498167; c=relaxed/simple; bh=EEPhOxzBcp09CleXW4aRinXkbuYe+TJkF0g+yGgNxG4=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=JxFuY6Y8xs6FLRLKdtzLY3F49rcRlZyjcNqmkKgYjEjIW2eL3prhaNZB+aKvP4lkQIGyy9JYcEblsjlHUokVWNCOxWwrKRwCd4AMOKSG/UOQNQmYUVz039+eoawaDhSj6BJkYO95DjQtWc4rgPNA0t867UNZ9hPCcNlb/92hfRU= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b=wjpl2EIr; arc=none smtp.client-ip=10.30.226.201 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b="wjpl2EIr" Received: by smtp.kernel.org (Postfix) with ESMTPSA id 88431C4CED1; Fri, 6 Dec 2024 15:16:06 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1733498167; bh=EEPhOxzBcp09CleXW4aRinXkbuYe+TJkF0g+yGgNxG4=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=wjpl2EIrPJlbXCwV0K2yNoir2RjPZrUS0xDMnUyrWrUwUQjopoa+thtWZoej/8/t9 R9zxuXkNRq/Iyfwp6KYq/K/Na8/ZZea8mxCB/5+61Wv7UuNfG0BbPXf4w3AcIrViYA c+gp3oJNFEq8hG30UNz6qQE8Czvhr7+jgZ5GXIVc= From: Greg Kroah-Hartman To: stable@vger.kernel.org Cc: Greg Kroah-Hartman , patches@lists.linux.dev, Geert Uytterhoeven , stable , Claudiu Beznea Subject: [PATCH 6.6 504/676] Revert "serial: sh-sci: Clean sci_ports[0] after at earlycon exit" Date: Fri, 6 Dec 2024 15:35:23 +0100 Message-ID: <20241206143713.042640049@linuxfoundation.org> X-Mailer: git-send-email 2.47.1 In-Reply-To: <20241206143653.344873888@linuxfoundation.org> References: <20241206143653.344873888@linuxfoundation.org> User-Agent: quilt/0.67 X-stable: review X-Patchwork-Hint: ignore Precedence: bulk X-Mailing-List: stable@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit 6.6-stable review patch. If anyone has any objections, please let me know. ------------------ From: Greg Kroah-Hartman commit 718632467d88e98816fa01ab12681ef1c2aa56f8 upstream. This reverts commit 3791ea69a4858b81e0277f695ca40f5aae40f312. It was reported to cause boot-time issues, so revert it for now. Reported-by: Geert Uytterhoeven Fixes: 3791ea69a485 ("serial: sh-sci: Clean sci_ports[0] after at earlycon exit") Cc: stable Cc: Claudiu Beznea Signed-off-by: Greg Kroah-Hartman --- drivers/tty/serial/sh-sci.c | 28 ---------------------------- 1 file changed, 28 deletions(-) --- a/drivers/tty/serial/sh-sci.c +++ b/drivers/tty/serial/sh-sci.c @@ -3505,32 +3505,6 @@ sh_early_platform_init_buffer("earlyprin #ifdef CONFIG_SERIAL_SH_SCI_EARLYCON static struct plat_sci_port port_cfg __initdata; -static int early_console_exit(struct console *co) -{ - struct sci_port *sci_port = &sci_ports[0]; - struct uart_port *port = &sci_port->port; - unsigned long flags; - int locked = 1; - - if (port->sysrq) - locked = 0; - else if (oops_in_progress) - locked = uart_port_trylock_irqsave(port, &flags); - else - uart_port_lock_irqsave(port, &flags); - - /* - * Clean the slot used by earlycon. A new SCI device might - * map to this slot. - */ - memset(sci_ports, 0, sizeof(*sci_port)); - - if (locked) - uart_port_unlock_irqrestore(port, flags); - - return 0; -} - static int __init early_console_setup(struct earlycon_device *device, int type) { @@ -3549,8 +3523,6 @@ static int __init early_console_setup(st SCSCR_RE | SCSCR_TE | port_cfg.scscr); device->con->write = serial_console_write; - device->con->exit = early_console_exit; - return 0; } static int __init sci_early_console_setup(struct earlycon_device *device,