From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-0.7 required=3.0 tests=BAYES_00,DKIM_ADSP_CUSTOM_MED, FREEMAIL_FORGED_FROMDOMAIN,FREEMAIL_FROM,HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS autolearn=no autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 5DD46C433DB for ; Fri, 12 Feb 2021 16:44:16 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 2F27464E89 for ; Fri, 12 Feb 2021 16:44:16 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231470AbhBLQns (ORCPT ); Fri, 12 Feb 2021 11:43:48 -0500 Received: from mga09.intel.com ([134.134.136.24]:8334 "EHLO mga09.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229674AbhBLQmz (ORCPT ); Fri, 12 Feb 2021 11:42:55 -0500 IronPort-SDR: /tMxmehfdHZ5ebAVnSh1O/PTYzXI9skL+tgMC+b9sBh+tfwbDMtGsUTpBk/ZLzXPBgbyA+Yj9v 4+0xmIYsKlKA== X-IronPort-AV: E=McAfee;i="6000,8403,9893"; a="182571478" X-IronPort-AV: E=Sophos;i="5.81,174,1610438400"; d="scan'208";a="182571478" Received: from fmsmga008.fm.intel.com ([10.253.24.58]) by orsmga102.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 12 Feb 2021 08:42:09 -0800 IronPort-SDR: EcxFHH/BHttIGhGD3tq9so/TUKuc48rvwPvtTVxe9iY+uTw2a1M6AGdkEwxUd3P60PgTb2qIFK br+GX8pXVa+w== X-IronPort-AV: E=Sophos;i="5.81,174,1610438400"; d="scan'208";a="381504813" Received: from smile.fi.intel.com (HELO smile) ([10.237.68.40]) by fmsmga008-auth.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 12 Feb 2021 08:42:06 -0800 Received: from andy by smile with local (Exim 4.94) (envelope-from ) id 1lAbW6-004XZ9-TX; Fri, 12 Feb 2021 18:42:02 +0200 Date: Fri, 12 Feb 2021 18:42:02 +0200 From: Andy Shevchenko To: linux-gpio@vger.kernel.org, Mika Westerberg Cc: Linus Walleij , Imre Deak Subject: Re: Replace raw_spin_lock_irqsave with raw_spin_lock Message-ID: References: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: Organization: Intel Finland Oy - BIC 0357606-4 - Westendinkatu 7, 02160 Espoo Precedence: bulk List-ID: X-Mailing-List: linux-gpio@vger.kernel.org On Fri, Feb 12, 2021 at 06:35:30PM +0200, Andy Shevchenko wrote: > Hi, Mika! > > There is an interesting discussion [1] going on about necessity of the > _irqsave/_irqrestore variants of spin lock in the IRQ handler. > > It appears that in our driver(s) we have also such variants of spin locks in > use. Do you have any idea why is it so? Okay, this is me, who did it in a copy'n'paste manner in the commit e64fbfa51e8f ("pinctrl: intel: Protect IO in few call backs by lock"). > A bonus question, why do we use _NO_THREAD flag explicitly as per Thomas [2] > this won't work well with RT kernels? Okay, this part is explained in the commit 1a7d1cb81eb2 ("pinctrl: intel: Prevent force threading of the interrupt handler"). > [1]: https://lore.kernel.org/linux-gpio/1612774577-55943-1-git-send-email-luojiaxing@huawei.com/T/#u > [2]: https://lore.kernel.org/linux-i2c/87zh2s8buh.fsf@nanos.tec.linutronix.de/ -- With Best Regards, Andy Shevchenko