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


Groups > linux.kernel > #1627407

[PATCH v2 0/2] Move uart_register_driver call to device probe for pl010 and sh-sci

Path csiph.com!news.mixmin.net!aioe.org!news.servidellagleba.it!bofh.it!news.nic.it!robomod
From Sjoerd Simons <sjoerd.simons@collabora.co.uk>
Newsgroups linux.kernel
Subject [PATCH v2 0/2] Move uart_register_driver call to device probe for pl010 and sh-sci
Date Thu, 20 Apr 2017 14:20:02 +0200
Message-ID <tyje1-o7-11@gated-at.bofh.it> (permalink)
X-Original-To linux-serial@vger.kernel.org
X-Mailer git-send-email 2.11.0
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 22
Organization linux.* mail to news gateway
X-Original-Cc linux-renesas-soc@vger.kernel.org, Greg Kroah-Hartman <gregkh@linuxfoundation.org>, linux-kernel@vger.kernel.org, Russell King <linux@armlinux.org.uk>, Jiri Slaby <jslaby@suse.com>
X-Original-Date Thu, 20 Apr 2017 14:12:59 +0200
X-Original-Message-ID <20170420121301.382-1-sjoerd.simons@collabora.co.uk>
X-Original-Sender linux-kernel-owner@vger.kernel.org
Xref csiph.com linux.kernel:1627407

Show key headers only | View raw


When testing on a Renesas board with the PL010 serial driver enabled
serial output broke. Turns out the minor device numbers for both
drivers happen to overlap, causing whichever driver happened to be the
second one to register to fail.

The attached patches move the uart_register_driver call to probe time
for both drivers avoiding the issue.

Changes in v2:
- Add locking to prevent issues when two probes run in parallel

Sjoerd Simons (2):
  serial: pl010: Move uart_register_driver call to device probe
  serial: sh-sci: Move uart_register_driver call to device probe

 drivers/tty/serial/amba-pl010.c | 31 +++++++++++++++++++++----------
 drivers/tty/serial/sh-sci.c     | 26 +++++++++++++++-----------
 2 files changed, 36 insertions(+), 21 deletions(-)

-- 
2.11.0

Back to linux.kernel | Previous | Next | Find similar | Unroll thread


Thread

[PATCH v2 0/2] Move uart_register_driver call to device probe for pl010 and sh-sci Sjoerd Simons <sjoerd.simons@collabora.co.uk> - 2017-04-20 14:20 +0200

csiph-web