From patchwork Wed Feb 19 06:24:36 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Tushar Behera X-Patchwork-Id: 24930 Return-Path: X-Original-To: linaro@patches.linaro.org Delivered-To: linaro@patches.linaro.org Received: from mail-pd0-f199.google.com (mail-pd0-f199.google.com [209.85.192.199]) by ip-10-151-82-157.ec2.internal (Postfix) with ESMTPS id 0E73A20468 for ; Wed, 19 Feb 2014 06:31:04 +0000 (UTC) Received: by mail-pd0-f199.google.com with SMTP id fp1sf38834839pdb.6 for ; Tue, 18 Feb 2014 22:31:04 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:delivered-to:from:to:cc:subject :date:message-id:in-reply-to:references:sender:precedence:list-id :x-original-sender:x-original-authentication-results:mailing-list :list-post:list-help:list-archive:list-unsubscribe; bh=RXLz8LazDZJ2hIpDQ2AtFHoJpe5OSjX4KE9Pz4KEOQ4=; b=e3RfLXYiRywxFVP5UluCZ6x5aNCtngrb2+MGYnSZZF59hKdVP0ma/WsQ77CLlBBZkE 1dYgbie8Gi52NehZhYg5E6O5/SjuAr+HT0Nn13bRfuLxr8KWuFIYFbpN1hu8HZsAoE5s zQutfXuOXpGSCtsUGVcdlAZA0OYurQNdgQmGcWl7EH98HIBSzGkHa+Bx4Z7AW6nm9QzP iXtZ0SVRDXi0ZfaphPi1mT6zDqQA+RFh/MV+lRQaXbguVIgyvdUCaPcvQvaM5qUZWiQ5 gIeTZn3NakWzaYIcrkDco6EkhowoONdCTaxwA6deEZre1Bv/P9LiWyiCXoJOR33eyJ0Y JbZA== X-Gm-Message-State: ALoCoQkev68Z17PDIPk5by/WnDZ23+6VVqwEp/o0+e3pRwqLbtltKgBROfn5cA8ffQQFrukRp+41 X-Received: by 10.66.144.170 with SMTP id sn10mr73508pab.43.1392791464252; Tue, 18 Feb 2014 22:31:04 -0800 (PST) MIME-Version: 1.0 X-BeenThere: patchwork-forward@linaro.org Received: by 10.140.102.244 with SMTP id w107ls1629083qge.26.gmail; Tue, 18 Feb 2014 22:31:04 -0800 (PST) X-Received: by 10.221.30.14 with SMTP id sa14mr858050vcb.44.1392791464148; Tue, 18 Feb 2014 22:31:04 -0800 (PST) Received: from mail-vc0-f171.google.com (mail-vc0-f171.google.com [209.85.220.171]) by mx.google.com with ESMTPS id n15si6416829vcy.102.2014.02.18.22.31.04 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Tue, 18 Feb 2014 22:31:04 -0800 (PST) Received-SPF: neutral (google.com: 209.85.220.171 is neither permitted nor denied by best guess record for domain of patch+caf_=patchwork-forward=linaro.org@linaro.org) client-ip=209.85.220.171; Received: by mail-vc0-f171.google.com with SMTP id le5so14391367vcb.30 for ; Tue, 18 Feb 2014 22:31:04 -0800 (PST) X-Received: by 10.52.248.138 with SMTP id ym10mr20531433vdc.18.1392791464062; Tue, 18 Feb 2014 22:31:04 -0800 (PST) X-Forwarded-To: patchwork-forward@linaro.org X-Forwarded-For: patch@linaro.org patchwork-forward@linaro.org Delivered-To: patch@linaro.org Received: by 10.220.174.196 with SMTP id u4csp274258vcz; Tue, 18 Feb 2014 22:31:03 -0800 (PST) X-Received: by 10.66.149.7 with SMTP id tw7mr209499pab.72.1392791463243; Tue, 18 Feb 2014 22:31:03 -0800 (PST) Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id to9si20746448pbc.215.2014.02.18.22.31.02; Tue, 18 Feb 2014 22:31:02 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752069AbaBSGad (ORCPT + 27 others); Wed, 19 Feb 2014 01:30:33 -0500 Received: from mail-pb0-f51.google.com ([209.85.160.51]:51386 "EHLO mail-pb0-f51.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751708AbaBSGaP (ORCPT ); Wed, 19 Feb 2014 01:30:15 -0500 Received: by mail-pb0-f51.google.com with SMTP id un15so17727163pbc.24 for ; Tue, 18 Feb 2014 22:30:15 -0800 (PST) X-Received: by 10.67.14.231 with SMTP id fj7mr177134pad.115.1392791415277; Tue, 18 Feb 2014 22:30:15 -0800 (PST) Received: from linaro.sisodomain.com ([115.113.119.130]) by mx.google.com with ESMTPSA id yd4sm62135719pbc.13.2014.02.18.22.30.11 for (version=TLSv1.1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Tue, 18 Feb 2014 22:30:14 -0800 (PST) From: Tushar Behera To: linux-kernel@vger.kernel.org, linux-samsung-soc@vger.kernel.org Cc: mturquette@linaro.org Subject: [PATCH RESEND 2/2] clk: clk-s2mps11: Add support for clocks in S5M8767 MFD Date: Wed, 19 Feb 2014 11:54:36 +0530 Message-Id: <1392791076-28301-3-git-send-email-tushar.behera@linaro.org> X-Mailer: git-send-email 1.7.9.5 In-Reply-To: <1392791076-28301-1-git-send-email-tushar.behera@linaro.org> References: <1392791076-28301-1-git-send-email-tushar.behera@linaro.org> Sender: linux-kernel-owner@vger.kernel.org Precedence: list List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-Removed-Original-Auth: Dkim didn't pass. X-Original-Sender: tushar.behera@linaro.org X-Original-Authentication-Results: mx.google.com; spf=neutral (google.com: 209.85.220.171 is neither permitted nor denied by best guess record for domain of patch+caf_=patchwork-forward=linaro.org@linaro.org) smtp.mail=patch+caf_=patchwork-forward=linaro.org@linaro.org Mailing-list: list patchwork-forward@linaro.org; contact patchwork-forward+owners@linaro.org X-Google-Group-Id: 836684582541 List-Post: , List-Help: , List-Archive: List-Unsubscribe: , Since clock operation within S2MPS11 and S5M8767 are similar, we can support both the devices within a single driver. Signed-off-by: Tushar Behera Reviewed-by: Tomasz Figa Reviewed-by: Yadwinder Singh Brar --- drivers/clk/Kconfig | 6 ++++-- drivers/clk/clk-s2mps11.c | 5 +++++ 2 files changed, 9 insertions(+), 2 deletions(-) diff --git a/drivers/clk/Kconfig b/drivers/clk/Kconfig index 7641965..da1b416 100644 --- a/drivers/clk/Kconfig +++ b/drivers/clk/Kconfig @@ -65,10 +65,12 @@ config COMMON_CLK_SI570 clock generators. config COMMON_CLK_S2MPS11 - tristate "Clock driver for S2MPS11 MFD" + tristate "Clock driver for S2MPS11/S5M8767 MFD" depends on MFD_SEC_CORE ---help--- - This driver supports S2MPS11 crystal oscillator clock. + This driver supports S2MPS11/S5M8767 crystal oscillator clock. These + multi-function devices have 3 fixed-rate oscillators, clocked at + 32KHz each. config CLK_TWL6040 tristate "External McPDM functional clock from twl6040" diff --git a/drivers/clk/clk-s2mps11.c b/drivers/clk/clk-s2mps11.c index 6f587bc..5088755 100644 --- a/drivers/clk/clk-s2mps11.c +++ b/drivers/clk/clk-s2mps11.c @@ -27,6 +27,7 @@ #include #include #include +#include #include #define s2mps11_name(a) (a->hw.init->name) @@ -175,6 +176,9 @@ static int s2mps11_clk_probe(struct platform_device *pdev) case S2MPS11X: s2mps11_reg = S2MPS11_REG_RTC_CTRL; break; + case S5M8767X: + s2mps11_reg = S5M8767_REG_CTRL1; + break; default: dev_err(&pdev->dev, "Invalid device type\n"); return -EINVAL; @@ -254,6 +258,7 @@ static int s2mps11_clk_remove(struct platform_device *pdev) static const struct platform_device_id s2mps11_clk_id[] = { { "s2mps11-clk", S2MPS11X}, + { "s5m8767-clk", S5M8767X}, { }, }; MODULE_DEVICE_TABLE(platform, s2mps11_clk_id);