Received: by 2002:a05:6500:1b8f:b0:1fa:5c73:8e2d with SMTP id df15csp482693lqb; Wed, 29 May 2024 01:13:08 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCX681fNhy3zEhhlnZno3R5mfhPGpp4XKWfCztRUWLrPHFsZomHth6S42ddnzOp3osipZHW+N/9DmbSm7bYoELkkY5oU51PqOrk0yRkKVg== X-Google-Smtp-Source: AGHT+IHbGEsP/xx4YmoCBatV62slScOz4hCsscPZhcSmcmRJ3+UjjeAygsbQ4w/JoX/bXwelB/Ba X-Received: by 2002:a05:622a:3:b0:43a:ed55:f5c4 with SMTP id d75a77b69052e-43fb0e53b8amr170732331cf.6.1716970388479; Wed, 29 May 2024 01:13:08 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1716970388; cv=pass; d=google.com; s=arc-20160816; b=nUHhs1mwLd1Fkw8d9X5/jhOJHJa8KGqdduzEGRSqPJrNxwkXawoV57yX6CFduiYgzH qDNoZLoClL44QmhNgh9bBdIxLxZb37WmztGdx0p0NmrgAob1z9CBh4Cyw6zMhT85zN1G /xAsG5rtQURVaW+NK4aEPJvv2TXNtmK/i7gFre5NbE02+IR5A1T/O4mBx9FgKtSu/Zpd 2Rq0d+SDS8l+tyauiMwn8KPCZBAuJQ/THT90fJoIgDRKV9MdHc5BOM5cpW0mlo41+GZW 5gAY2Q7CqwJuNN7bAQ3Fg7j5VNXKHNM7SkoaIJCGhzmMUwLWt68TAuvRR+BjYu1rRwFt DMvw== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:references:in-reply-to:message-id :date:subject:cc:to:from; bh=r6MLD8b7snuD/jqAjjsKs/Uoe9fdQauZOWLvRlQgGVE=; fh=NCl8CixGeTFE2HqgWDW+UlfZpmTMmLot3MlKffw+YoQ=; b=xeP4Uz1J1jpJcACWeLbAT2rCMv3r0qpNgLt82eAT4mNhSLcUKFBUKn9yPC2zaEQENU xdFxOaHecDGGbH8F2wfjGJ+wbrq8pAqzX3t3R25L/MXzD+jd6KPTRz59G8rQT/g6CHXH IZwvcGfyxiqaZpZqVN25Kgkngq/FF7z6uUSR9YglQPvXb4EFe8cJNw1TrYFtwr/N357W WXVbGQQkoOeEi2YDhhj6cr7EUJts4wSD4z5O/CYLd9B1wQlRaCysFi6QGxrjc2kzC7Tk diVaPlRbumJiPNMaVr4V8pj22dZQAAIw4R4OwfJpq+6sbAGHGY4RD8KlD4zJ3sYYNOru wT7w==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; arc=pass (i=1); spf=pass (google.com: domain of linux-kernel+bounces-193658-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.199.223 as permitted sender) smtp.mailfrom="linux-kernel+bounces-193658-linux.lists.archive=gmail.com@vger.kernel.org" Return-Path: Received: from ny.mirrors.kernel.org (ny.mirrors.kernel.org. [147.75.199.223]) by mx.google.com with ESMTPS id d75a77b69052e-43fb18a68fcsi119622311cf.345.2024.05.29.01.13.08 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 29 May 2024 01:13:08 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-193658-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.199.223 as permitted sender) client-ip=147.75.199.223; Authentication-Results: mx.google.com; arc=pass (i=1); spf=pass (google.com: domain of linux-kernel+bounces-193658-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.199.223 as permitted sender) smtp.mailfrom="linux-kernel+bounces-193658-linux.lists.archive=gmail.com@vger.kernel.org" Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ny.mirrors.kernel.org (Postfix) with ESMTPS id 6D18D1C25720 for ; Wed, 29 May 2024 08:07:17 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 7A0101802A8; Wed, 29 May 2024 08:02:08 +0000 (UTC) Received: from sakura.ysato.name (ik1-413-38519.vs.sakura.ne.jp [153.127.30.23]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 39DFE17DE24; Wed, 29 May 2024 08:02:06 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=153.127.30.23 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1716969727; cv=none; b=OIjpj3PxG9rE+cBuTtJKge+sfi7hZzB704jSQBOyMrXuZgyP8JRmq3NFyS9ewceSoYPXPNuRH72Pm2keGqukp55oiE2TJC58y1mt8lbwCWV5dpr8stlnRStz3sUe4u4vsgF5zAq6fw/PeAqgQlkuMJHCRmZrZ+8uGoTY7QN0foo= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1716969727; c=relaxed/simple; bh=c6luz8u71CE/VdNLS8yhPrrY+gC+8ZkQ6lJ/yJUeP7I=; h=From:To:Cc:Subject:Date:Message-Id:In-Reply-To:References: MIME-Version; b=oeC9SH8+0zZpb6p8GFSQ/5b3ZSr/Tdl9ctVw0dZ4GH8Wy0zEWdHRb3crMq1haRfByNA1F72gYjaZh3+Ix8l4bp5PPL9ty71vbEzrPZZQUZlC2TUV1Pt2Q3Bbg+DS76aSNrDS3YuNrwtZR0yl8hDWc8Mt3Jsr63J/QDhRhyDl8n4= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=users.sourceforge.jp; spf=fail smtp.mailfrom=users.sourceforge.jp; arc=none smtp.client-ip=153.127.30.23 Authentication-Results: smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=users.sourceforge.jp Authentication-Results: smtp.subspace.kernel.org; spf=fail smtp.mailfrom=users.sourceforge.jp Received: from SIOS1075.ysato.name (al128006.dynamic.ppp.asahi-net.or.jp [111.234.128.6]) by sakura.ysato.name (Postfix) with ESMTPSA id 35E141C0E59; Wed, 29 May 2024 17:02:04 +0900 (JST) From: Yoshinori Sato To: linux-sh@vger.kernel.org Cc: Yoshinori Sato , Damien Le Moal , Niklas Cassel , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Geert Uytterhoeven , Michael Turquette , Stephen Boyd , David Airlie , Daniel Vetter , Maarten Lankhorst , Maxime Ripard , Thomas Zimmermann , Thomas Gleixner , Bjorn Helgaas , Lorenzo Pieralisi , =?UTF-8?q?Krzysztof=20Wilczy=C5=84ski?= , Greg Kroah-Hartman , Jiri Slaby , Magnus Damm , Daniel Lezcano , Rich Felker , John Paul Adrian Glaubitz , Lee Jones , Helge Deller , Heiko Stuebner , Neil Armstrong , Chris Morgan , Sebastian Reichel , Linus Walleij , Arnd Bergmann , Masahiro Yamada , Baoquan He , Andrew Morton , Guenter Roeck , Kefeng Wang , Stephen Rothwell , Azeem Shaikh , Guo Ren , Max Filippov , Jernej Skrabec , Herve Codina , Andy Shevchenko , Anup Patel , Jacky Huang , Hugo Villeneuve , Jonathan Corbet , Wolfram Sang , =?UTF-8?q?Uwe=20Kleine-K=C3=B6nig?= , Christophe JAILLET , Sam Ravnborg , Javier Martinez Canillas , Sergey Shtylyov , Laurent Pinchart , linux-ide@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-renesas-soc@vger.kernel.org, linux-clk@vger.kernel.org, dri-devel@lists.freedesktop.org, linux-pci@vger.kernel.org, linux-serial@vger.kernel.org, linux-fbdev@vger.kernel.org Subject: [DO NOT MERGE v8 20/36] serial: sh-sci: fix SH4 OF support. Date: Wed, 29 May 2024 17:01:06 +0900 Message-Id: <57525900a4876323467612d73eded183315c1680.1716965617.git.ysato@users.sourceforge.jp> X-Mailer: git-send-email 2.39.2 In-Reply-To: References: Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit - Separated RZ's earlycon initialization from normal SCIF. - fix earlyprintk hung (NULL pointer reference). - fix SERIAL_SH_SCI_EARLYCON enablement Signed-off-by: Yoshinori Sato Reviewed-by: Geert Uytterhoeven --- drivers/tty/serial/Kconfig | 2 +- drivers/tty/serial/sh-sci.c | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/drivers/tty/serial/Kconfig b/drivers/tty/serial/Kconfig index 4fdd7857ef4d..eeb22b582470 100644 --- a/drivers/tty/serial/Kconfig +++ b/drivers/tty/serial/Kconfig @@ -664,7 +664,7 @@ config SERIAL_SH_SCI_EARLYCON depends on SERIAL_SH_SCI=y select SERIAL_CORE_CONSOLE select SERIAL_EARLYCON - default ARCH_RENESAS + default ARCH_RENESAS || SUPERH config SERIAL_SH_SCI_DMA bool "DMA support" if EXPERT diff --git a/drivers/tty/serial/sh-sci.c b/drivers/tty/serial/sh-sci.c index f738980a8b2c..068f483401e3 100644 --- a/drivers/tty/serial/sh-sci.c +++ b/drivers/tty/serial/sh-sci.c @@ -2723,7 +2723,7 @@ static int sci_remap_port(struct uart_port *port) if (port->membase) return 0; - if (port->dev->of_node || (port->flags & UPF_IOREMAP)) { + if (dev_of_node(port->dev) || (port->flags & UPF_IOREMAP)) { port->membase = ioremap(port->mapbase, sport->reg_size); if (unlikely(!port->membase)) { dev_err(port->dev, "can't remap port#%d\n", port->line); @@ -3551,8 +3551,8 @@ static int __init hscif_early_console_setup(struct earlycon_device *device, OF_EARLYCON_DECLARE(sci, "renesas,sci", sci_early_console_setup); OF_EARLYCON_DECLARE(scif, "renesas,scif", scif_early_console_setup); -OF_EARLYCON_DECLARE(scif, "renesas,scif-r7s9210", rzscifa_early_console_setup); -OF_EARLYCON_DECLARE(scif, "renesas,scif-r9a07g044", rzscifa_early_console_setup); +OF_EARLYCON_DECLARE(rzscifa, "renesas,scif-r7s9210", rzscifa_early_console_setup); +OF_EARLYCON_DECLARE(rzscifa, "renesas,scif-r9a07g044", rzscifa_early_console_setup); OF_EARLYCON_DECLARE(scifa, "renesas,scifa", scifa_early_console_setup); OF_EARLYCON_DECLARE(scifb, "renesas,scifb", scifb_early_console_setup); OF_EARLYCON_DECLARE(hscif, "renesas,hscif", hscif_early_console_setup); -- 2.39.2