From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751437AbdKVMsU (ORCPT ); Wed, 22 Nov 2017 07:48:20 -0500 Received: from vulcan.natalenko.name ([104.207.131.136]:17790 "EHLO vulcan.natalenko.name" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751216AbdKVMsS (ORCPT ); Wed, 22 Nov 2017 07:48:18 -0500 DMARC-Filter: OpenDMARC Filter v1.3.2 vulcan.natalenko.name B780D29A141 Authentication-Results: vulcan.natalenko.name; dmarc=fail (p=none dis=none) header.from=natalenko.name From: Oleksandr Natalenko To: Hans de Goede Cc: platform-driver-x86@vger.kernel.org, linux-kernel@vger.kernel.org Subject: Re: Failed IRQ assignment for INT0002 on Braswell Date: Wed, 22 Nov 2017 13:48:16 +0100 Message-ID: <2100487.obXIbN4R9M@natalenko.name> In-Reply-To: <3c09b28b-6ca5-cd1c-f5c0-f7be73f1c1b4@redhat.com> References: <1902393.IdeYHqtVB8@natalenko.name> <3c09b28b-6ca5-cd1c-f5c0-f7be73f1c1b4@redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset="UTF-8" ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=natalenko.name; s=arc-20170712; t=1511354897; h=from:subject:date:message-id:to:cc:mime-version:content-type:content-transfer-encoding:in-reply-to:references; bh=qxgvh6qRG58PIwXu5KKCT0yFtw8OafQhVjKpjN2TBGs=; b=FRP3+CShKnAQMTuaSxYeNSudNKS47EFnTTRm6owOjJdelDETjPvODWqgZj1N40uu/XSkYX fo5wYu188lrDvcJKTXxUycD8hV2WvgSkwrlexQXLhCSP84S8Ym9qB3YcvY0to9ZekRNeys WyegxLZzfgshEoJeR8NtgdMlJN6jKjU= ARC-Seal: i=1; s=arc-20170712; d=natalenko.name; t=1511354897; a=rsa-sha256; cv=none; b=ZJfG3Nel0/qbKR7tMnZlsiDdxlvyeV5/mCPhRsgBjLLmEsEHlnUs9byChRl0HnmYUFj0sFKnMvdtB73JdTR4qE7xWJHtkg4v9XTRM3SFFmwoy8PQKubZt+ldb1EdZXjhvbgUQNIs4acvie774ByD10mhjWcPOIqgfH1sm21Di/A= ARC-Authentication-Results: i=1; auth=pass smtp.auth=oleksandr@natalenko.name smtp.mailfrom=oleksandr@natalenko.name Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Transfer-Encoding: 8bit X-MIME-Autoconverted: from quoted-printable to 8bit by nfs id vAMCmOKL002532 Hi, Hans. On středa 22. listopadu 2017 11:48:50 CET Hans de Goede wrote: > /* snip */ > This should be fixed by: > > https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/ke > rnel/irq?id=382bd4de61827dbaaf5fb4fb7b1f4be4a86505e7 > > Which is in 4.13, but the trigger-type does not seem to be the problem in > your case, the problem likely is the ONESHOT flag: > > #define IRQF_ONESHOT 0x00002000 > > Which appears to be set in the flags for the acpi irq handler: > > kernel: genirq: Flags mismatch irq 9. 00010084 (INT0002) vs. 00002080 > > (acpi) > But that irq is requested here: > > https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/tree/driv > ers/acpi/osl.c#n570 > > > > if (request_irq(irq, acpi_irq, IRQF_SHARED, "acpi", acpi_irq)) { > printk(KERN_ERR PREFIX "SCI (IRQ%d) allocation failed\n", irq); > ... > > And IRQF_ONESHOT is not passed, so I do not understand where the 00002000 in > the acpi irq handler flags is coming from ... Well, looks like I know where this flag comes from. I boot this machine with "threadirqs", and IRQF_ONESHOT description says: === 52 * IRQF_ONESHOT - Interrupt is not reenabled after the hardirq handler finished. 53 * Used by threaded interrupts which need to keep the 54 * irq line disabled until the threaded handler has been run. === If I boot the machine without "threadirqs", looks like the device is set up okay. The only message I get in the kernel log is: === kernel: acpi INT0002:00: Device [GPED] is in always present list === Grepping for IRQ 9: === kernel: ACPI: INT_SRC_OVR (bus 0 bus_irq 9 global_irq 9 high level) kernel: ACPI: IRQ9 used by override. === and 9th interrupt shows this device: === 9: 0 0 0 0 IO-APIC 9-fasteoi acpi, INT0002 === Any idea why "threadirqs" makes this fail? Thanks. Regards, Oleksandr