Received: by 2002:a05:6a10:6d10:0:0:0:0 with SMTP id gq16csp559594pxb; Fri, 22 Apr 2022 06:53:29 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwzkZN3emGdInvjuH8E47XgTVTEVU5+sZjqTz3hcG7+M2LPVm2Xx5hDd7DTIEW7Dv0OmwpA X-Received: by 2002:a05:6402:e9f:b0:41c:df21:b113 with SMTP id h31-20020a0564020e9f00b0041cdf21b113mr5084625eda.217.1650635609628; Fri, 22 Apr 2022 06:53:29 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1650635609; cv=none; d=google.com; s=arc-20160816; b=PaF3P5z+iNX2OaJxiZjQttwXAWIEh0XbdHtH/YALq+BGnbeI+3X2c71hJIkQTkwh+R I+kJu9PFEYvwzbKocHv+YPTv45grOm4GAOKwQB5SFQVOuKCUQ2BgowlIEcr5TvPdk03B ZCUHDE3xuR8kiXtIXGQKmdvIjq2MP1kzdra+UPaHVDan0QR3W3/ZAYP5WRGK/vh9nfPq +LIvnA56D/F0ADWWeyUpHgSCUczlQ6/4HM1UlVo/AURfrf+FgvKCyRd2DLQab9j89nZj Kavo4kDH9BcPFcQcPhRyJP+oTulpbh4v8AaR9lmrSin75YuYMI9pkDqx1OdduvaqMTih c7Yw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :message-id:date:subject:cc:to:from:dkim-signature; bh=lawfx27xta4vfR+4MosfdO7oG8Hnj+YwEmI/W9otsus=; b=VjsN1DhseboAMJgk5ulldvZDRPxLIXQPAMxyyQfaqs+BIgEBDQw2J4j9/AJWvce4xD e+dMrrS1LJMTCYBTcuS+8H8gTdr5PEvgBs+Gj1G+5hI8esS03njazJq4q7OaKFjd5q+S B8Myhjj4YpQAlhUT4anYlfRhcerlRGwroqOd2o+b/G55dA4OJz9HCGrEK8TEebztGVn8 1U3bvx+5bt82DS+Zsu9mV3QdvkrPQFTbIhTCLojp1W9+1ZqneQZHKcqV9XoH1Ud/vs2T 6W5RK1XJJv/vx/aUTx63sQA3VI7Aa23JQgK6TY5QYh5OnGfbJ6e7oS+6sE5QGr3rbZcR mbxA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20210112 header.b=GxVa8lq0; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id by4-20020a0564021b0400b00423d82f2656si645664edb.179.2022.04.22.06.53.05; Fri, 22 Apr 2022 06:53:29 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20210112 header.b=GxVa8lq0; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1355913AbiDTOI2 (ORCPT + 99 others); Wed, 20 Apr 2022 10:08:28 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:54758 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229694AbiDTOI0 (ORCPT ); Wed, 20 Apr 2022 10:08:26 -0400 Received: from mail-pg1-x534.google.com (mail-pg1-x534.google.com [IPv6:2607:f8b0:4864:20::534]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id C157E3E0DD for ; Wed, 20 Apr 2022 07:05:40 -0700 (PDT) Received: by mail-pg1-x534.google.com with SMTP id i63so1697071pge.11 for ; Wed, 20 Apr 2022 07:05:40 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=lawfx27xta4vfR+4MosfdO7oG8Hnj+YwEmI/W9otsus=; b=GxVa8lq0hY3BT7fav05p0SMUyezgEY1uIy+ZgBDa4XsugOwBffXhDQFr0P/vMBVjD7 QVnDqaz9KiXDgjfFaldOiKsWg05ZvCb7dHm+GjZZfcYEjDaXhMnKtxVLVfeAR/2yb3h2 uFruHDNkNflM9LEwUzwISQmnjWoaPfodfDT2x738I2zQyHkQUCcdqBYZXzLHDFoPLOjs uW8IB98LbxCnWy/h3CutN2oTgYFFtZvgHFDVHj7Vb8Fg+9HvRuMtNjqqz5zWgoFb1dqn 3fgQjJ8ounYpaudnkKyqjbSsvSW1MCupJGYrHQURJ+CMZeeqzptZdiEhv8x/WjvmOTyU 0JfA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=lawfx27xta4vfR+4MosfdO7oG8Hnj+YwEmI/W9otsus=; b=B/7Zne24nf6pYZ5TUm6T91bySemmlfU9dKLf2lBtvupcjKoVRx6BymoyjaRB+nmZ/m z9Dbgto4geviVtMhtB8vhSHQSQfo2wi2Yfly0ZcRC6iUn2P6PoEnEIy82T04vTkrV2gd PcZFl099YlKVOVSZp+OquLFZnKUYJAK7b0+QnqTcc6yl8Jy6EFhKajm2NsfpiftGsZkF Py4T+zjlsBsrWotrlL7/n2TS2ihlwtk233KK+L0bhN6RlVydMLytnB5+KvEbyj3MYdds qFhyn/n8n4PHalSfR4S8UbpMpAvwjZrnkEKj4oIEbrJjh69DOpshob7eiU1ZsvuS6vqn Os3A== X-Gm-Message-State: AOAM5305/DVFWG0BUqNjhn58ulWCbLg5aakCTxhobSBVzoC/HVOKYhsj UDtJ9yBUIlEgtIyXGZyRIOM8A1csIQ== X-Received: by 2002:a63:482:0:b0:3aa:5637:e33a with SMTP id 124-20020a630482000000b003aa5637e33amr4832486pge.536.1650463540097; Wed, 20 Apr 2022 07:05:40 -0700 (PDT) Received: from piliu.users.ipa.redhat.com ([209.132.188.80]) by smtp.gmail.com with ESMTPSA id br10-20020a056a00440a00b0050a777cd10csm10959178pfb.91.2022.04.20.07.05.28 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 20 Apr 2022 07:05:39 -0700 (PDT) From: Pingfan Liu To: linux-kernel@vger.kernel.org Cc: Pingfan Liu , Alexander Gordeev , Baokun Li , Bartosz Golaszewski , Borislav Petkov , =?UTF-8?q?C=C3=A9dric=20Le=20Goater?= , Christian Borntraeger , Dave Hansen , Dongli Zhang , Florian Fainelli , Frederic Weisbecker , Heiko Carstens , "H. Peter Anvin" , Ingo Molnar , "Jason A. Donenfeld" , "Maciej W. Rozycki" , Marc Zyngier , Mark Rutland , Miguel Ojeda , Nathan Chancellor , Nick Desaulniers , Oleksandr Natalenko , Peter Zijlstra , Qais Yousef , "Rafael J. Wysocki" , Randy Dunlap , Sebastian Andrzej Siewior , Steven Price , Sven Schnelle , Thomas Gleixner , Tom Rix , Valentin Schneider , Vasily Gorbik , Wolfram Sang , Yuan ZhaoXiong , YueHaibing Subject: [PATCH 0/9] trival fix or improvement about irq_desc access Date: Wed, 20 Apr 2022 22:05:12 +0800 Message-Id: <20220420140521.45361-1-kernelfans@gmail.com> X-Mailer: git-send-email 2.31.1 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,FREEMAIL_FROM, RCVD_IN_DNSWL_NONE,SPF_HELO_NONE,SPF_PASS autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org When I went through the access of irq_to_desc(), I found the following trival issue or improvement can be done. [1-4/9]: clean up or small improvement [5-6/9]: bugfix for access to irq_desc under releasable context [7/9]: clean up [8-9/9]: bugfix for irq debugfs Cc: Alexander Gordeev Cc: Baokun Li Cc: Bartosz Golaszewski Cc: Borislav Petkov Cc: "Cédric Le Goater" Cc: Christian Borntraeger Cc: Dave Hansen Cc: Dongli Zhang Cc: Florian Fainelli Cc: Frederic Weisbecker Cc: Heiko Carstens Cc: "H. Peter Anvin" Cc: Ingo Molnar Cc: "Jason A. Donenfeld" Cc: "Maciej W. Rozycki" Cc: Marc Zyngier Cc: Mark Rutland Cc: Miguel Ojeda Cc: Nathan Chancellor Cc: Nick Desaulniers Cc: Oleksandr Natalenko Cc: Peter Zijlstra Cc: Qais Yousef Cc: "Rafael J. Wysocki" Cc: Randy Dunlap Cc: Sebastian Andrzej Siewior Cc: Steven Price Cc: Sven Schnelle Cc: Thomas Gleixner Cc: Tom Rix Cc: Valentin Schneider Cc: Vasily Gorbik Cc: Wolfram Sang Cc: Yuan ZhaoXiong Cc: YueHaibing To: linux-kernel@vger.kernel.org Pingfan Liu (9): irq/irqdesc: put the lock at the exact place in irq_sysfs_init() irq/irqdesc: change the name of delete_irq_desc() to irq_delete_desc() irq/manage: remove some unreferenced code s390/irq: utilize RCU instead of irq_lock_sparse() in show_msi_interrupt() x86/irq: place for_each_active_irq() in rcu read section pm/irq: make for_each_irq_desc() safe of irq_desc release irq: remove needless lock in takedown_cpu() irq: make irq_lock_sparse() independent of CONFIG_SPARSE_IRQ irq/irqdesc: rename sparse_irq_lock to bitmap_lock .clang-format | 1 - arch/s390/kernel/irq.c | 11 ++++---- arch/x86/kernel/apic/io_apic.c | 3 +++ include/linux/irq.h | 1 - include/linux/irqdesc.h | 10 +++----- include/linux/irqnr.h | 3 --- kernel/cpu.c | 15 ++++------- kernel/irq/cpuhotplug.c | 4 +-- kernel/irq/debugfs.c | 4 +-- kernel/irq/irqdesc.c | 47 +++++++++++++++++----------------- kernel/irq/manage.c | 15 ----------- kernel/irq/pm.c | 3 +++ 12 files changed, 47 insertions(+), 70 deletions(-) -- 2.31.1