Received: by 2002:a25:4158:0:0:0:0:0 with SMTP id o85csp880066yba; Thu, 18 Apr 2019 11:06:42 -0700 (PDT) X-Google-Smtp-Source: APXvYqy1Rm6y8Q6BjBGKagffzUmxKlf/vstoh3zQxS33zvHi3S9VODy8dzxtfUSAGJ89zbfPWqpC X-Received: by 2002:a17:902:7785:: with SMTP id o5mr97309025pll.33.1555610802065; Thu, 18 Apr 2019 11:06:42 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1555610802; cv=none; d=google.com; s=arc-20160816; b=pAt3Q/xzTjxrYPC7HDxebjdB8Fz9AhIaCDs3TSiqzPenbr2yM0+LhQW8fPNr1K5KRN HUtOByDevHjZ5+tIJ9Wqn+DzM7jmzSggCKM72Pmc3UhZd9UgdKdS5J+HIUOjkFsCWK/Q h6aJ4U/dY0GMMGZ5Yh2JB6FK58yycbz0EZbxPdx1ciaJmDD92z3lSWyMprv8kkxia4ey 21rivOTmp2McHZ+F6TV7CgQqap/eAWQpJuL+j/f03Cze7MoTXtjl4l0Zb2bKcoC5C+eY 67hjB7VHkOq6p+f+BM5vgUKGbRirO95iNRh7Z414+cD2XzZtpDFJ8VHYQnm6YwCXm8fk rMaQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=4xxRc6oNUnrNGhipWszNl5toqtH6eSgGnFtQB0C2jtA=; b=mqWr0dpgrlF8HSAhP2vq8DH/rPGDpN+EOJe6pHJA3320bQZx+Y9mTMdGVAMRePkekC rXIeYpRSEbCibBRwcYlwYs95hEsCV3umlpjgQgZlmrpV8mGVSEjKC8UOTn0gvfwS1ZIk NQTOcdQl8t6PG6nFCv05uVhdaZgxZLBcOrQGjE0I29FKCoKEEOLoQxEYWrvbh4xW8L5X Ip8DGIMYg8ffUllmdxyOPfinXl0XryqlOanYHZYO8ohsxyxMVrcLD2ieBU2MwpCpW7BH ad6w/4tQ9tafsZDKTobBvlLKrA3kuLgFq3YNznVr64nrlB9cjCsubtz6ETrF/yt/3ZD4 /YOw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=FL+el6K9; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id r184si2451309pgr.24.2019.04.18.11.06.27; Thu, 18 Apr 2019 11:06:42 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=FL+el6K9; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2391178AbfDRSEn (ORCPT + 99 others); Thu, 18 Apr 2019 14:04:43 -0400 Received: from mail.kernel.org ([198.145.29.99]:33738 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S2390766AbfDRSEl (ORCPT ); Thu, 18 Apr 2019 14:04:41 -0400 Received: from localhost (83-86-89-107.cable.dynamic.v4.ziggo.nl [83.86.89.107]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id DD3D5206B6; Thu, 18 Apr 2019 18:04:39 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1555610680; bh=ZVTWULgxHehvTa+KaN8dM8tNF2RV5AwEJYr+qthuFis=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=FL+el6K90M71QSHY3NdIbAAmf3TQl7z6rLAS/GAm+Y7Wz7ljZFtxMvB7NrzxehHId kfzE9j2KaBuZL4ewp0/Z1gzeWxtSDm+1bGAcq3PQAXHYeiEzR1Qaz3MkORSiTfKu7V 6DE6ZX/FDXW7YaFDFBwNorEwu6FZZTxtwoVvrfyM= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Michal Simek , Sasha Levin Subject: [PATCH 4.14 44/92] serial: uartps: console_setup() cant be placed to init section Date: Thu, 18 Apr 2019 19:57:02 +0200 Message-Id: <20190418160434.027770112@linuxfoundation.org> X-Mailer: git-send-email 2.21.0 In-Reply-To: <20190418160430.325165109@linuxfoundation.org> References: <20190418160430.325165109@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org [ Upstream commit 4bb1ce2350a598502b23088b169e16b43d4bc639 ] When console device is rebinded, console_setup() is called again. But marking it as __init means that function will be clear after boot is complete. If console device is binded again console_setup() is not found and error "Unable to handle kernel paging request at virtual address" is reported. Signed-off-by: Michal Simek Signed-off-by: Greg Kroah-Hartman Signed-off-by: Sasha Levin --- drivers/tty/serial/xilinx_uartps.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/tty/serial/xilinx_uartps.c b/drivers/tty/serial/xilinx_uartps.c index f438a2158006..b0da63737aa1 100644 --- a/drivers/tty/serial/xilinx_uartps.c +++ b/drivers/tty/serial/xilinx_uartps.c @@ -1270,7 +1270,7 @@ static void cdns_uart_console_write(struct console *co, const char *s, * * Return: 0 on success, negative errno otherwise. */ -static int __init cdns_uart_console_setup(struct console *co, char *options) +static int cdns_uart_console_setup(struct console *co, char *options) { struct uart_port *port = &cdns_uart_port[co->index]; int baud = 9600; -- 2.19.1