From patchwork Fri Nov 25 13:05:09 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Ilpo_J=C3=A4rvinen?= X-Patchwork-Id: 628778 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 0E7B7C43217 for ; Fri, 25 Nov 2022 13:05:51 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230002AbiKYNFu (ORCPT ); Fri, 25 Nov 2022 08:05:50 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:36362 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229838AbiKYNFm (ORCPT ); Fri, 25 Nov 2022 08:05:42 -0500 Received: from mga03.intel.com (mga03.intel.com [134.134.136.65]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 869DB4C275; Fri, 25 Nov 2022 05:05:35 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1669381535; x=1700917535; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=3xoDJ24ls7xPY5orIQfBql47gNQpE19TZHADmQ5loEY=; b=SjocPMA3y6CguntltyOhfQ+2lxLcKLnh2YCDOAE5gREOyDVddsyUnp5w qB30+JVxErLRppIiAPDv8Ua+TGQMkVy4UfHca5kGV0V8sFvrQVfJbNjfx lWe+jQzh0fXh8YM1LtNKGcG3OdSsBFE35gSXRNKgR6Cd2pHHa4nuWgccG M8OolNua5xKaMJ1DLt2LPkwqB6VrVEDoa9c3Nu/XWzWKyS7mjIAPanYEL H59ETrWNk7FkwpIx+d8PJrWoCj9mtQ1Imj9pJoSfvqK4hcsYjHFTT7AiH wLDYscSq0u9KZqYbcGSisstJ1WBZpiDYc/S9CpzworezDIJDMGA8dyxcA g==; X-IronPort-AV: E=McAfee;i="6500,9779,10541"; a="316300802" X-IronPort-AV: E=Sophos;i="5.96,193,1665471600"; d="scan'208";a="316300802" Received: from fmsmga008.fm.intel.com ([10.253.24.58]) by orsmga103.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 25 Nov 2022 05:05:35 -0800 X-IronPort-AV: E=McAfee;i="6500,9779,10541"; a="706064050" X-IronPort-AV: E=Sophos;i="5.96,193,1665471600"; d="scan'208";a="706064050" Received: from dpotapen-mobl.ger.corp.intel.com (HELO ijarvine-MOBL2.ger.corp.intel.com) ([10.252.50.101]) by fmsmga008-auth.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 25 Nov 2022 05:05:33 -0800 From: =?utf-8?q?Ilpo_J=C3=A4rvinen?= To: Greg Kroah-Hartman , Jiri Slaby , linux-serial@vger.kernel.org, linux-kernel@vger.kernel.org Cc: =?utf-8?q?Ilpo_J=C3=A4rvinen?= Subject: [PATCH v2 6/6] serial: 8250_early: Convert literals to use defines Date: Fri, 25 Nov 2022 15:05:09 +0200 Message-Id: <20221125130509.8482-7-ilpo.jarvinen@linux.intel.com> X-Mailer: git-send-email 2.30.2 In-Reply-To: <20221125130509.8482-1-ilpo.jarvinen@linux.intel.com> References: <20221125130509.8482-1-ilpo.jarvinen@linux.intel.com> MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: linux-serial@vger.kernel.org Use existing defines for the serial register values in 8250_early. Signed-off-by: Ilpo Järvinen --- drivers/tty/serial/8250/8250_early.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/tty/serial/8250/8250_early.c b/drivers/tty/serial/8250/8250_early.c index f271becfc46c..0ebde0ab8167 100644 --- a/drivers/tty/serial/8250/8250_early.c +++ b/drivers/tty/serial/8250/8250_early.c @@ -136,11 +136,11 @@ static void __init init_port(struct earlycon_device *device) unsigned char c; unsigned int ier; - serial8250_early_out(port, UART_LCR, 0x3); /* 8n1 */ + serial8250_early_out(port, UART_LCR, UART_LCR_WLEN8); /* 8n1 */ ier = serial8250_early_in(port, UART_IER); serial8250_early_out(port, UART_IER, ier & UART_IER_UUE); /* no interrupt */ serial8250_early_out(port, UART_FCR, 0); /* no fifo */ - serial8250_early_out(port, UART_MCR, 0x3); /* DTR + RTS */ + serial8250_early_out(port, UART_MCR, UART_MCR_DTR | UART_MCR_RTS); if (port->uartclk) { divisor = DIV_ROUND_CLOSEST(port->uartclk, 16 * device->baud);