From patchwork Wed Nov 24 11:57:19 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Greg Kroah-Hartman X-Patchwork-Id: 12636723 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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id EA793C4332F for ; Wed, 24 Nov 2021 12:08:54 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S242796AbhKXMMC (ORCPT ); Wed, 24 Nov 2021 07:12:02 -0500 Received: from mail.kernel.org ([198.145.29.99]:33504 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S242563AbhKXMJ7 (ORCPT ); Wed, 24 Nov 2021 07:09:59 -0500 Received: by mail.kernel.org (Postfix) with ESMTPSA id BC231610E6; Wed, 24 Nov 2021 12:05:46 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1637755547; bh=0wATiQxK/PELoTDrmyyKDTMZwmyhzwmp5iHD7Zc9jhM=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=iLoP31fKVOCQ5A6QP/3cC4LqT+oYwER2TJzYZFdgEShgRG2YQYajGZBTS1Hmn1Lz1 m5zUZpiX1uEixw02SygjKIV0hzVuVS3H8Axfu8pAMtYP30xxAnxoJAb/XnXt1YFLpX jJD9tx3aw0i7X06hm6QoHcOc2EXQf74DvyEIJBBM= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Randy Dunlap , kernel test robot , "Russell King (Oracle)" , Artur Rojek , Paul Cercueil , linux-mips@vger.kernel.org, Jonathan Cameron , Lars-Peter Clausen , linux-iio@vger.kernel.org, Florian Fainelli , Andy Shevchenko , Russell King , bcm-kernel-feedback-list@broadcom.com, Jonas Gorski , Jonathan Cameron , Thomas Bogendoerfer , Sasha Levin Subject: [PATCH 4.4 136/162] mips: bcm63xx: add support for clk_get_parent() Date: Wed, 24 Nov 2021 12:57:19 +0100 Message-Id: <20211124115702.687341359@linuxfoundation.org> X-Mailer: git-send-email 2.34.0 In-Reply-To: <20211124115658.328640564@linuxfoundation.org> References: <20211124115658.328640564@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: linux-iio@vger.kernel.org From: Randy Dunlap [ Upstream commit e8f67482e5a4bc8d0b65d606d08cb60ee123b468 ] BCM63XX selects HAVE_LEGACY_CLK but does not provide/support clk_get_parent(), so add a simple implementation of that function so that callers of it will build without errors. Fixes these build errors: mips-linux-ld: drivers/iio/adc/ingenic-adc.o: in function `jz4770_adc_init_clk_div': ingenic-adc.c:(.text+0xe4): undefined reference to `clk_get_parent' mips-linux-ld: drivers/iio/adc/ingenic-adc.o: in function `jz4725b_adc_init_clk_div': ingenic-adc.c:(.text+0x1b8): undefined reference to `clk_get_parent' Fixes: e7300d04bd08 ("MIPS: BCM63xx: Add support for the Broadcom BCM63xx family of SOCs." ) Signed-off-by: Randy Dunlap Reported-by: kernel test robot Suggested-by: Russell King (Oracle) Cc: Artur Rojek Cc: Paul Cercueil Cc: linux-mips@vger.kernel.org Cc: Jonathan Cameron Cc: Lars-Peter Clausen Cc: linux-iio@vger.kernel.org Cc: Florian Fainelli Cc: Andy Shevchenko Cc: Russell King Cc: bcm-kernel-feedback-list@broadcom.com Cc: Jonas Gorski Reviewed-by: Andy Shevchenko Acked-by: Jonathan Cameron Acked-by: Russell King (Oracle) Acked-by: Florian Fainelli Signed-off-by: Thomas Bogendoerfer Signed-off-by: Sasha Levin --- arch/mips/bcm63xx/clk.c | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/arch/mips/bcm63xx/clk.c b/arch/mips/bcm63xx/clk.c index 637565284732d..ef268c9aac80d 100644 --- a/arch/mips/bcm63xx/clk.c +++ b/arch/mips/bcm63xx/clk.c @@ -333,6 +333,12 @@ void clk_disable(struct clk *clk) EXPORT_SYMBOL(clk_disable); +struct clk *clk_get_parent(struct clk *clk) +{ + return NULL; +} +EXPORT_SYMBOL(clk_get_parent); + unsigned long clk_get_rate(struct clk *clk) { return clk->rate;