Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1299055

Re: [PATCH v6] serial: rewrite pxa2xx-uart to use 8250_core

Path csiph.com!eternal-september.org!feeder.eternal-september.org!aioe.org!bofh.it!news.nic.it!robomod
From Robert Jarzmik <robert.jarzmik@free.fr>
Newsgroups linux.kernel
Subject Re: [PATCH v6] serial: rewrite pxa2xx-uart to use 8250_core
Date Tue, 29 Dec 2015 18:00:02 +0100
Message-ID <qL5MS-35d-7@gated-at.bofh.it> (permalink)
References <qIWXo-57D-35@gated-at.bofh.it> <qJfQl-8ob-11@gated-at.bofh.it> <qL0ka-824-23@gated-at.bofh.it>
X-Me-Helo belgarion
X-Me-Auth amFyem1pay5yb2JlcnRAb3JhbmdlLmZy
X-Me-Date Tue, 29 Dec 2015 17:51:03 +0100
X-Me-IP 92.136.207.223
X-URL http://belgarath.falguerolles.org/
User-Agent Gnus/5.130008 (Ma Gnus v0.8) Emacs/24.4 (gnu/linux)
MIME-Version 1.0
Content-Type text/plain
Sender robomod@news.nic.it
List-ID <linux-kernel.vger.kernel.org>
X-Mailing-List linux-kernel@vger.kernel.org
Approved robomod@news.nic.it
Lines 64
Organization linux.* mail to news gateway
X-Original-Cc linux-kernel@vger.kernel.org, James Cameron <quozl@laptop.org>, Greg Kroah-Hartman <gregkh@linuxfoundation.org>, Russell King <linux@arm.linux.org.uk>, Jiri Slaby <jslaby@suse.com>, Andy Shevchenko <andriy.shevchenko@linux.intel.com>, Arnd Bergmann <arnd@arndb.de>, Joachim Eastwood <manabian@gmail.com>, Sebastian Andrzej Siewior <bigeasy@linutronix.de>, Scott Wood <scottwood@freescale.com>, Paul Gortmaker <paul.gortmaker@windriver.com>, Paul Burton <paul.burton@imgtec.com>, Mans Rullgard <mans@mansr.com>, Ralf Baechle <ralf@linux-mips.org>, Masahiro Yamada <yamada.masahiro@socionext.com>, Peter Hurley <peter@hurleysoftware.com>, "open list\:SERIAL DRIVERS" <linux-serial@vger.kernel.org>
X-Original-Date Tue, 29 Dec 2015 17:50:53 +0100
X-Original-Message-ID <8760zhfbbm.fsf@belgarion.home>
X-Original-References <1450897204-6839-1-git-send-email-ynvich@gmail.com> <1450970122-12869-1-git-send-email-ynvich@gmail.com> <20151229110643.GB19870@kuha.fi.intel.com>
X-Original-Sender linux-kernel-owner@vger.kernel.org
Xref csiph.com linux.kernel:1299055

Show key headers only | View raw


Heikki Krogerus <heikki.krogerus@linux.intel.com> writes:

> On Thu, Dec 24, 2015 at 06:15:14PM +0300, Sergei Ianovich wrote:
>> pxa2xx-uart was a separate uart platform driver. It was declaring
>> the same device names and numbers as 8250 driver. As a result,
>> it was impossible to use 8250 driver on PXA SoCs.
>> 
>> Upon closer examination pxa2xx-uart turned out to be a clone of
>> 8250_core driver.
>> 
>> Workaround for Erratum #19 according to Marvel(R) PXA270M Processor
>> Specification Update (April 19, 2010) is dropped. 8250_core reads
>> from FIFO immediately after checking DR bit in LSR.
>> 
>> The patch leaves the original SERIAL_PXA driver around. The original
>> driver is just marked DEPRECATED in Kconfig and C source. When
>> the original driver is considered safe to remove, no changes
>> to SERIAL_8250 will be necessary.
>> 
>> Compiling SERIAL_8250_CONSOLE and SERIAL_PXA_CONSOLE even without
>> SERIAL_8250_PXA breaks console for SERIAL_PXA. For this reasons, the new
>> and the original drivers are made mutually exclusive.
>> 
>> Signed-off-by: Sergei Ianovich <ynvich@gmail.com>
>> CC: Heikki Krogerus <heikki.krogerus@linux.intel.com>
>
> Reviewed-by: Heikki Krogerus <heikki.krogerus@linux.intel.com>
Tested-by: Robert Jarzmik <robert.jarzmik@free.fr>

The tests were done on lubbock(pxa25x), mainstone(pxa27x) and zylonite(pxa3xx)
boards.

I don't expect any breakage in PXA architecture. There might be issues with :
 - arch/arm/mach-pxa/capc7117.c
 - arch/arm/mach-pxa/viper.c
  -arch/arm/mach-pxa/zeus.c (very small probability for this one)
The mitigation plan if any concern arises is to fallback on the
CONFIG_SERIAL_PXA configuration.

I find a bit misleading this chunk, but I'm not very good at KConfig :
 config SERIAL_PXA
-       bool "PXA serial port support"
+       bool "PXA serial port support (DEPRECATED)"
        depends on ARCH_PXA || ARCH_MMP
        select SERIAL_CORE
+       select SERIAL_8250_PXA if SERIAL_8250=y
+       select SERIAL_PXA_NON8250 if !SERIAL_8250=y

What bothers me a bit is that selecting this option has a different effect
whether SERIAL_8250 is set or not. Somebody selecting the deprecated option
obviously wants the old driver, but will be provided the new one if his config
has SERIAL_8250 set. Maybe someone else can comment on this ...

This apart, from pxa perspective, it's good to go.

Cheers.

-- 
Robert
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Back to linux.kernel | Previous | NextPrevious in thread | Find similar | Unroll thread


Thread

[PATCH v5] serial: rewrite pxa2xx-uart to use 8250_core Sergei Ianovich <ynvich@gmail.com> - 2015-12-23 20:10 +0100
  Re: [PATCH v5] serial: rewrite pxa2xx-uart to use 8250_core kbuild test robot <lkp@intel.com> - 2015-12-24 10:20 +0100
  [PATCH v6] serial: rewrite pxa2xx-uart to use 8250_core Sergei Ianovich <ynvich@gmail.com> - 2015-12-24 16:20 +0100
    Re: [PATCH v6] serial: rewrite pxa2xx-uart to use 8250_core Heikki Krogerus <heikki.krogerus@linux.intel.com> - 2015-12-29 12:10 +0100
      Re: [PATCH v6] serial: rewrite pxa2xx-uart to use 8250_core Robert Jarzmik <robert.jarzmik@free.fr> - 2015-12-29 18:00 +0100

csiph-web