From nobody Mon Apr 13 05:39:40 2026 Received: from cstnet.cn (smtp25.cstnet.cn [159.226.251.25]) (using TLSv1.2 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 6844926B755 for ; Mon, 9 Mar 2026 09:13:48 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=159.226.251.25 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1773047631; cv=none; b=mygMIBWvf/cRMapI4G380LeHrHj95AqiBMleRWrfl3FF88PxBFqv3njhywpaELY4ny2xYMpXs1/Vvk6eSy7tKw/N1W75f8xRhSC2Y5DIBPfuw0h0SgXLfF82pTynBZKBrxWorwyHI9at/+5FNJeTQ8pW8qJCoJpUAB69Jl1Pb9k= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1773047631; c=relaxed/simple; bh=DUNcUFaboBbNwDiPFR8kcVQ7ckHYp9PJP0nmaIBhwj4=; h=From:To:Cc:Subject:Date:Message-Id:MIME-Version; b=MavbMM3sMLfQzpf8cM9zWRp09oqrVdM3TIEk8Mlfx5w1pXmxLi94q1SXt/UIP8Qbc90Rk34VBWEXNkVdjgZdXLF+z4ti+ZXXUpeaamWpEKYOgg2NS+83zUmElODVxoSAJPZyh1INEyc0O88i1qfM1bimHdd64ouJFp3NAfL/9VQ= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=isrc.iscas.ac.cn; spf=pass smtp.mailfrom=isrc.iscas.ac.cn; arc=none smtp.client-ip=159.226.251.25 Authentication-Results: smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=isrc.iscas.ac.cn Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=isrc.iscas.ac.cn Received: from localhost.localdomain (unknown [210.73.43.101]) by APP-05 (Coremail) with SMTP id zQCowAAntwpKj65p6erxCQ--.45509S2; Mon, 09 Mar 2026 17:13:46 +0800 (CST) From: Pengpeng Hou To: Corey Minyard Cc: openipmi-developer@lists.sourceforge.net, linux-kernel@vger.kernel.org, Pengpeng Hou Subject: [PATCH] ipmi: scope ipmi_si_irq_handler() to CONFIG_ACPI Date: Mon, 9 Mar 2026 09:13:32 +0000 Message-Id: <20260309091332.720315-1-pengpeng.hou@isrc.iscas.ac.cn> X-Mailer: git-send-email 2.25.1 Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable X-CM-TRANSID: zQCowAAntwpKj65p6erxCQ--.45509S2 X-Coremail-Antispam: 1UD129KBjvJXoW7CryrJF17CFy8AFWkCFy7trb_yoW8XF1xpF 48A34q9r48GF1jg3y0v34rua95X3s8W34rtrW7A34DuFs0qa4FgF1a9a4aqryDGFyjgF43 tFnavw1fuF18Ca7anT9S1TB71UUUUU7qnTZGkaVYY2UrUUUUjbIjqfuFe4nvWSU5nxnvy2 9KBjDU0xBIdaVrnRJUUUkS14x267AKxVWUJVW8JwAFc2x0x2IEx4CE42xK8VAvwI8IcIk0 rVWrJVCq3wAFIxvE14AKwVWUJVWUGwA2ocxC64kIII0Yj41l84x0c7CEw4AK67xGY2AK02 1l84ACjcxK6xIIjxv20xvE14v26r1j6r1xM28EF7xvwVC0I7IYx2IY6xkF7I0E14v26r4j 6F4UM28EF7xvwVC2z280aVAFwI0_Jr0_Gr1l84ACjcxK6I8E87Iv6xkF7I0E14v26r4j6r 4UJwAS0I0E0xvYzxvE52x082IY62kv0487Mc02F40EFcxC0VAKzVAqx4xG6I80ewAv7VC0 I7IYx2IY67AKxVWUXVWUAwAv7VC2z280aVAFwI0_Gr0_Cr1lOx8S6xCaFVCjc4AY6r1j6r 4UM4x0Y48IcxkI7VAKI48JM4x0x7Aq67IIx4CEVc8vx2IErcIFxwCY02Avz4vE14v_GFWl 42xK82IYc2Ij64vIr41l4I8I3I0E4IkC6x0Yz7v_Jr0_Gr1lx2IqxVAqx4xG67AKxVWUJV WUGwC20s026x8GjcxK67AKxVWUGVWUWwC2zVAF1VAY17CE14v26r126r1DMIIYrxkI7VAK I48JMIIF0xvE2Ix0cI8IcVAFwI0_Jr0_JF4lIxAIcVC0I7IYx2IY6xkF7I0E14v26r4j6F 4UMIIF0xvE42xK8VAvwI8IcIk0rVWUJVWUCwCI42IY6I8E87Iv67AKxVWUJVW8JwCI42IY 6I8E87Iv6xkF7I0E14v26r4j6r4UJbIYCTnIWIevJa73UjIFyTuYvjfU1zuWDUUUU X-CM-SenderInfo: pshqw1hhqjhx1rx6x21ufox2xfdvhtffof0/ Content-Type: text/plain; charset="utf-8" In current linux.git (1954c4f01220), ipmi_si_irq_handler() is defined and declared unconditionally. However, its only in-tree caller is the ACPI GPE helper in drivers/char/ipmi/ipmi_si_platform.c, which lives inside #ifdef CONFIG_ACPI. Match the helper declaration and definition to that scope by wrapping them in #ifdef CONFIG_ACPI. This fixes the config-scope mismatch and reduces unnecessary code footprint for non-ACPI systems. Signed-off-by: Pengpeng Hou --- diff --git a/drivers/char/ipmi/ipmi_si.h b/drivers/char/ipmi/ipmi_si.h --- a/drivers/char/ipmi/ipmi_si.h +++ b/drivers/char/ipmi/ipmi_si.h @@ int ipmi_si_add_smi(struct si_sm_io *io); +#ifdef CONFIG_ACPI irqreturn_t ipmi_si_irq_handler(int irq, void *data); +#endif void ipmi_irq_start_cleanup(struct si_sm_io *io); int ipmi_std_irq_setup(struct si_sm_io *io); void ipmi_irq_finish_setup(struct si_sm_io *io); diff --git a/drivers/char/ipmi/ipmi_si_intf.c b/drivers/char/ipmi/ipmi_si_i= ntf.c --- a/drivers/char/ipmi/ipmi_si_intf.c +++ b/drivers/char/ipmi/ipmi_si_intf.c @@ spin_unlock_irqrestore(&(smi_info->si_lock), flags); } =20 +#ifdef CONFIG_ACPI irqreturn_t ipmi_si_irq_handler(int irq, void *data) { struct smi_info *smi_info =3D data; unsigned long flags; @@ =20 return IRQ_HANDLED; } +#endif =20 static unsigned int ipmi_shift_irq_cleanup(unsigned int cleanup_period, struct si_sm_io *io) {