From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1756327AbbFPINY (ORCPT ); Tue, 16 Jun 2015 04:13:24 -0400 Received: from www.linutronix.de ([62.245.132.108]:42913 "EHLO Galois.linutronix.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752965AbbFPINT (ORCPT ); Tue, 16 Jun 2015 04:13:19 -0400 Date: Tue, 16 Jun 2015 10:12:51 +0200 (CEST) From: Thomas Gleixner To: Jiang Liu cc: bhelgaas@google.com, benh@kernel.crashing.org, mingo@kernel.org, rdunlap@infradead.org, yinghai@kernel.org, linux-kernel@vger.kernel.org, tony.luck@intel.com, ying.huang@intel.com, konrad.wilk@oracle.com, hpa@zytor.com, bp@alien8.de, linux-tip-commits@vger.kernel.org Subject: Re: [tip:x86/apic] genirq: Prevent crash in irq_move_irq() In-Reply-To: <557FD4A6.7040301@linux.intel.com> Message-ID: References: <1433145945-789-3-git-send-email-jiang.liu@linux.intel.com> <557FD4A6.7040301@linux.intel.com> User-Agent: Alpine 2.11 (DEB 23 2013-08-11) MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII X-Linutronix-Spam-Score: -1.0 X-Linutronix-Spam-Level: - X-Linutronix-Spam-Status: No , -1.0 points, 5.0 required, ALL_TRUSTED=-1,SHORTCIRCUIT=-0.0001,URIBL_BLOCKED=0.001 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, 16 Jun 2015, Jiang Liu wrote: > On 2015/6/16 15:31, tip-bot for Jiang Liu wrote: > > Commit-ID: 458526ec81d755dfaa17f3d863302afe6fbefca0 > > Gitweb: http://git.kernel.org/tip/458526ec81d755dfaa17f3d863302afe6fbefca0 > > Author: Jiang Liu > > AuthorDate: Mon, 1 Jun 2015 16:05:11 +0800 > > Committer: Thomas Gleixner > > CommitDate: Tue, 16 Jun 2015 09:23:28 +0200 > > > > genirq: Prevent crash in irq_move_irq() > > > > The functions irq_move_irq() and irq_move_masked_irq() expect that the > > caller passes the top-level irq_data to them when hierarchical > > irqdomains are enabled. But that's not true when called from > > apic_ack_edge(), which results in a null pointer dereference by > > idata->chip->irq_mask(idata). > > > > Instead of fixing callers to passing top-level irq_data, we rather > > change irq_move_irq()/irq_move_masked_irq() to accept any irq_data. > > > > Fixes: 52f518a3a7c 'x86/MSI: Use hierarchical irqdomains to manage MSI interrupts' > Hi Thomas, > This patch has dependency on patch "[Patch v3 01/36] genirq: > Enhance irq_data_to_desc() to support hierarchy irqdomain" in the > same patch set, otherwise irq_data_to_desc(idata) may return invalid > irq_desc and may cause memory crash. That's why you should not mix bug fixes with performance improvement series. Thanks, tglx