Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754450AbdCMSjb (ORCPT ); Mon, 13 Mar 2017 14:39:31 -0400 Received: from dougal.metanate.com ([90.155.101.14]:1878 "EHLO metanate.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1754169AbdCMSin (ORCPT ); Mon, 13 Mar 2017 14:38:43 -0400 From: John Keeping To: Heiko Stuebner Cc: Linus Walleij , linux-gpio@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-rockchip@lists.infradead.org, linux-kernel@vger.kernel.org, John Keeping Subject: [RFC PATCH 0/4] pinctrl: rockchip: PREEMPT_RT_FULL fixes Date: Mon, 13 Mar 2017 18:38:09 +0000 Message-Id: <20170313183813.3582-1-john@metanate.com> X-Mailer: git-send-email 2.12.0.377.gf910686b23.dirty Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1373 Lines: 27 As described in Documentation/gpio/driver.txt, we should not be using sleepable APIs in the irqchip implementation. Since this includes the regmap API, this patch series ends up moving the mux setup for IRQs into an irq_bus_sync_unlock() handler which may result in the IRQ being configured before the port has been muxed as a GPIO. I've marked the series as RFC because I'm not sure if this is the best way to accomplish this or if there is another approach that is cleaner. Also, the first patch may not be correct on RK3399 because I originally wrote the patch for RK3288 on top of v4.4 where all drive updates only affect a single register. We don't need locking in this case because regmap_update_bits() takes a lock on the regmap internally, but if these two registers need to be updated atomically then another lock will be required here - slock cannot be used if it is converted to a raw spinlock since with full RT preemption the regmap's spinlock may sleep. John Keeping (4): pinctrl: rockchip: remove unnecessary locking pinctrl: rockchip: convert to raw spinlock pinctrl: rockchip: split out verification of mux settings pinctrl: rockchip: avoid hardirq-unsafe functions in irq_chip drivers/pinctrl/pinctrl-rockchip.c | 140 +++++++++++++++++++++++-------------- 1 file changed, 86 insertions(+), 54 deletions(-) -- 2.12.0.377.gf910686b23.dirty