From patchwork Mon Nov 8 19:01:59 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: jae.hyun.yoo@intel.com X-Patchwork-Id: 12608957 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 22C75C433EF for ; Mon, 8 Nov 2021 18:44:18 +0000 (UTC) Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id E7633613B3 for ; Mon, 8 Nov 2021 18:44:17 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.4.1 mail.kernel.org E7633613B3 Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=intel.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-Id:Date:Subject:Cc:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=rthQyJPbw5iJNnoQ2mp4CSj2DUe4UsEej35sZxzD0ig=; b=hn3Gl5+W9X5VFL Y9Raual9eXk5BuvQ4F9W17juNtVyeh2ny0dDPjbCBLqMj2HQFYJMgUXz42IQjP6iAurDXy+iKgO8P ncccnFUvCCDoa1phB1jCMkowN25qW0gwTiJckBzku1btpRReVJtlDWwuDKlly+/Y8vhbvd66boLyO jsVY1Dgz+QtK55mEu9VkqjAu1LbR4aprjicoFzDaXKAprnrLLwCm65LvPfZfOwrPbuX7+YUGxbfcL rTrapQDwRxSJOcRNAfnTpy9+I9+1OzTWnrJWKTzM3/7feOWh3g6zVPQs2KB6IbcFW/1fBN8M/GkAS xAnzuuqaEQkdr9ttwKTQ==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1mk9bk-00HBZB-8I; Mon, 08 Nov 2021 18:43:04 +0000 Received: from mga12.intel.com ([192.55.52.136]) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1mk9bA-00HBQ9-9c for linux-arm-kernel@lists.infradead.org; Mon, 08 Nov 2021 18:42:29 +0000 X-IronPort-AV: E=McAfee;i="6200,9189,10162"; a="212332012" X-IronPort-AV: E=Sophos;i="5.87,218,1631602800"; d="scan'208";a="212332012" Received: from orsmga008.jf.intel.com ([10.7.209.65]) by fmsmga106.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 08 Nov 2021 10:42:20 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.87,218,1631602800"; d="scan'208";a="503150693" Received: from maru.jf.intel.com ([10.54.51.77]) by orsmga008.jf.intel.com with ESMTP; 08 Nov 2021 10:42:20 -0800 From: jae.hyun.yoo@intel.com To: Rob Herring , Corey Minyard , Joel Stanley , Andrew Jeffery , Cedric Le Goater , Haiyue Wang , ChiaWei Wang , Jae Hyun Yoo Cc: devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-aspeed@lists.ozlabs.org, openipmi-developer@lists.sourceforge.net Subject: [PATCH v3 5/6] dt-bindings: ipmi: aspeed, kcs-bmc: add 'clocks' as a required property Date: Mon, 8 Nov 2021 11:01:59 -0800 Message-Id: <20211108190200.290957-6-jae.hyun.yoo@intel.com> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20211108190200.290957-1-jae.hyun.yoo@intel.com> References: <20211108190200.290957-1-jae.hyun.yoo@intel.com> MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20211108_104228_416706_AFEDC0B6 X-CRM114-Status: GOOD ( 12.35 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org From: Jae Hyun Yoo If LPC KCS driver is registered ahead of lpc-ctrl module, LPC KCS hardware block will be enabled without heart beating of LCLK until lpc-ctrl enables the LCLK. This issue causes improper handling on host interrupts when the host sends interrupts in that time frame. Then kernel eventually forcibly disables the interrupt with dumping stack and printing a 'nobody cared this irq' message out. To prevent this issue, all LPC sub drivers should enable LCLK individually so this patch adds 'clocks' property as one of required properties to enable the LCLK by the LPC KCS driver. Note: dtsi change in this patch series should be applied along with, and dtbs should be re-compiled after applying this series since it's adding a new required property otherwise the driver will not be probed correctly. Signed-off-by: Jae Hyun Yoo Reviewed-by: Rob Herring --- v2 -> v3: * Made commit message more descriptive. v1 -> v2: Changes sinve v1: * Added 'clocks' property into kcs-bmc bindings using 'aspeed,ast2400-kcs-bmc.yaml' because it's not merged into 'aspeed-lpc.yaml' yet. The bindings merging could be done using a separate patch later. .../devicetree/bindings/ipmi/aspeed,ast2400-kcs-bmc.yaml | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/Documentation/devicetree/bindings/ipmi/aspeed,ast2400-kcs-bmc.yaml b/Documentation/devicetree/bindings/ipmi/aspeed,ast2400-kcs-bmc.yaml index 4ff6fabfcb30..92ec0da047f4 100644 --- a/Documentation/devicetree/bindings/ipmi/aspeed,ast2400-kcs-bmc.yaml +++ b/Documentation/devicetree/bindings/ipmi/aspeed,ast2400-kcs-bmc.yaml @@ -71,9 +71,14 @@ properties: $ref: '/schemas/types.yaml#/definitions/uint32' description: The host CPU IO map address + clocks: + maxItems: 1 + description: Reference clock for the LPC controller + required: - compatible - interrupts + - clocks additionalProperties: false @@ -96,6 +101,7 @@ allOf: examples: - | + #include #include kcs3: kcs@24 { compatible = "aspeed,ast2600-kcs-bmc"; @@ -103,4 +109,5 @@ examples: aspeed,lpc-io-reg = <0xca2>; aspeed,lpc-interrupts = <11 IRQ_TYPE_LEVEL_LOW>; interrupts = <8>; + clocks = <&syscon ASPEED_CLK_GATE_LCLK>; };