From patchwork Fri Jul 28 16:33:33 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Dave Gerlach X-Patchwork-Id: 9869123 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id 9F48A60382 for ; Fri, 28 Jul 2017 16:35:27 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id B2C4D28539 for ; Fri, 28 Jul 2017 16:35:27 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id A770C2888F; Fri, 28 Jul 2017 16:35:27 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-1.9 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,RCVD_IN_DNSWL_NONE autolearn=ham version=3.3.1 Received: from bombadil.infradead.org (bombadil.infradead.org [65.50.211.133]) (using TLSv1.2 with cipher AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id A28AC28539 for ; Fri, 28 Jul 2017 16:35:26 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:Cc:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:Message-ID:Date:Subject:To :From:Reply-To:Content-ID:Content-Description:Resent-Date:Resent-From: Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:In-Reply-To:References: List-Owner; bh=GCeF+9AwBRm1s8LZrwxX6JDYTodmwKLna31/iyE3KMQ=; b=KiN14TOjxjCtww pTOkGklhbH4yu10CIgaYdfRsJXSXsIkalUTkQUvzizRHAvB6lpjPC5U4sSd2yTMBP/TlnU69URMzt D9+Ss3y2KkzNGGp8xDyWAX77nzseaaZNvTMjFfwOukGd9bjAv17keuTGR01Ib5u/9FG3P5Z1ZXPqA UkKsOHZNieD0S4vPVjKT5Kzj3ZMFalK9ZxR/oML3pkflL+Y9tdoKbk/WzsgmTrNBhzhVxsYbRGhqq yvGBSNm22pgAioR1qUx4A2cCFrSI1pUHpJNv0zFShMEnsidSZs3V6X2wqbqd1uiNrRq4GTIMByDgO UaWb1XzlgHi6ZeFIoBsw==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.87 #1 (Red Hat Linux)) id 1db8EV-0007aq-DN; Fri, 28 Jul 2017 16:35:23 +0000 Received: from lelnx194.ext.ti.com ([198.47.27.80]) by bombadil.infradead.org with esmtps (Exim 4.87 #1 (Red Hat Linux)) id 1db8D6-0005SO-0d for linux-arm-kernel@lists.infradead.org; Fri, 28 Jul 2017 16:34:54 +0000 Received: from dflxv15.itg.ti.com ([128.247.5.124]) by lelnx194.ext.ti.com (8.15.1/8.15.1) with ESMTP id v6SGXYxP032609; Fri, 28 Jul 2017 11:33:34 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=ti.com; s=ti-com-17Q1; t=1501259614; bh=NhY0oO7euEe4nkgIK+wtGjRzlczNw+bl3/O19FdxEmc=; h=From:To:CC:Subject:Date; b=TahpVqFTK9CfaLNMfr+H9etn4ZMzjNlKgNwk1KlVvyg7G2eSSSi70dNn+ovtoa6AP aHRmlSiAYaNlSlxBOXzCJqmwtUe/EuTf9qs6y+DhLWG6gsluw4fCYoXTx8zrXG7F7r 5aPjdPOU3YVqOpVp/NdVwJIdRSTdVRMf2b0FbglQ= Received: from DLEE70.ent.ti.com (dlemailx.itg.ti.com [157.170.170.113]) by dflxv15.itg.ti.com (8.14.3/8.13.8) with ESMTP id v6SGXY9O026703; Fri, 28 Jul 2017 11:33:34 -0500 Received: from dlep32.itg.ti.com (157.170.170.100) by DLEE70.ent.ti.com (157.170.170.113) with Microsoft SMTP Server id 14.3.294.0; Fri, 28 Jul 2017 11:33:34 -0500 Received: from legion.dal.design.ti.com (legion.dal.design.ti.com [128.247.22.53]) by dlep32.itg.ti.com (8.14.3/8.13.8) with ESMTP id v6SGXY6d026148; Fri, 28 Jul 2017 11:33:34 -0500 Received: from localhost (uda0274052.dhcp.ti.com [128.247.59.203]) by legion.dal.design.ti.com (8.11.7p1+Sun/8.11.7) with ESMTP id v6SGXX314496; Fri, 28 Jul 2017 11:33:33 -0500 (CDT) From: Dave Gerlach To: Santosh Shilimkar Subject: [RESEND PATCH] soc: ti: ti_sci_pm_domains: Populate name for genpd Date: Fri, 28 Jul 2017 11:33:33 -0500 Message-ID: <20170728163333.704-1-d-gerlach@ti.com> X-Mailer: git-send-email 2.13.0 MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20170728_093356_413065_E84BA3FE X-CRM114-Status: UNSURE ( 7.18 ) X-CRM114-Notice: Please train this message. X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Dave Gerlach , Vignesh R , linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org X-Virus-Scanned: ClamAV using ClamSMTP Commit b6a1d093f96b ("PM / Domains: Extend generic power domain debugfs") now creates a debugfs directory for each genpd based on the name of the genpd. Currently no name is given to the genpd created by ti_sci_pm_domains driver so because of this we see a NULL pointer dereferences when it is accessed on boot when the debugfs entry creation is attempted. Give the genpd a name before registering it to avoid this. Fixes: 52835d59fc6c ("soc: ti: Add ti_sci_pm_domains driver") Signed-off-by: Dave Gerlach --- drivers/soc/ti/ti_sci_pm_domains.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/drivers/soc/ti/ti_sci_pm_domains.c b/drivers/soc/ti/ti_sci_pm_domains.c index b0b283810e72..de31b9389e2e 100644 --- a/drivers/soc/ti/ti_sci_pm_domains.c +++ b/drivers/soc/ti/ti_sci_pm_domains.c @@ -176,6 +176,8 @@ static int ti_sci_pm_domain_probe(struct platform_device *pdev) ti_sci_pd->dev = dev; + ti_sci_pd->pd.name = "ti_sci_pd"; + ti_sci_pd->pd.attach_dev = ti_sci_pd_attach_dev; ti_sci_pd->pd.detach_dev = ti_sci_pd_detach_dev;