All of lore.kernel.org
 help / color / mirror / Atom feed
From: Noam Camus <noamca@mellanox.com>
To: Thomas Gleixner <tglx@linutronix.de>
Cc: "robh+dt@kernel.org" <robh+dt@kernel.org>,
	"mark.rutland@arm.com" <mark.rutland@arm.com>,
	"daniel.lezcano@linaro.org" <daniel.lezcano@linaro.org>,
	"devicetree@vger.kernel.org" <devicetree@vger.kernel.org>,
	"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>
Subject: RE: [PATCH v3 2/3] clocksource: update "fn" at CLOCKSOURCE_OF_DECLARE() of nps400 timer
Date: Tue, 1 Nov 2016 09:07:38 +0000	[thread overview]
Message-ID: <DB6PR0501MB251840D45FC427B1A7B7572AAAA10@DB6PR0501MB2518.eurprd05.prod.outlook.com> (raw)
In-Reply-To: <alpine.DEB.2.20.1610311137290.8160@nanos>

> From: Thomas Gleixner [mailto:tglx@linutronix.de] 
> Sent: Monday, October 31, 2016 7:40 PM

>>  
>>  static unsigned long nps_timer_rate;
>> +static int nps_get_timer_clk(struct device_node *node,
>
>Please don't glue variables and functions together w/o a new line. That's horrible to read.
Will be fixed in V4

>> +static int __init nps_setup_clocksource(struct device_node *node)
>>  {
>>  	int ret, cluster;
>> +	struct clk *clk;
>>  
>>  	for (cluster = 0; cluster < NPS_CLUSTER_NUM; cluster++)
>>  		nps_msu_reg_low_addr[cluster] =
>>  			nps_host_reg((cluster << NPS_CLUSTER_OFFSET),
>>  				 NPS_MSU_BLKID, NPS_MSU_TICK_LOW);
>>  
>> -	ret = clk_prepare_enable(clk);
>> -	if (ret) {
>> -		pr_err("Couldn't enable parent clock\n");
>> -		return ret;
>> -	}
>> -
>> -	nps_timer_rate = clk_get_rate(clk);
>> +	nps_get_timer_clk(node, &nps_timer_rate, clk);

>Why are you ignoring the return code? It was handled before your change ...
Will be fixed in V4

Regards,
Noam

WARNING: multiple messages have this Message-ID (diff)
From: Noam Camus <noamca-VPRAkNaXOzVWk0Htik3J/w@public.gmane.org>
To: Thomas Gleixner <tglx-hfZtesqFncYOwBW4kG4KsQ@public.gmane.org>
Cc: "robh+dt-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org"
	<robh+dt-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org>,
	"mark.rutland-5wv7dgnIgG8@public.gmane.org"
	<mark.rutland-5wv7dgnIgG8@public.gmane.org>,
	"daniel.lezcano-QSEj5FYQhm4dnm+yROfE0A@public.gmane.org"
	<daniel.lezcano-QSEj5FYQhm4dnm+yROfE0A@public.gmane.org>,
	"devicetree-u79uwXL29TY76Z2rM5mHXA@public.gmane.org"
	<devicetree-u79uwXL29TY76Z2rM5mHXA@public.gmane.org>,
	"linux-kernel-u79uwXL29TY76Z2rM5mHXA@public.gmane.org"
	<linux-kernel-u79uwXL29TY76Z2rM5mHXA@public.gmane.org>
Subject: RE: [PATCH v3 2/3] clocksource: update "fn" at CLOCKSOURCE_OF_DECLARE() of nps400 timer
Date: Tue, 1 Nov 2016 09:07:38 +0000	[thread overview]
Message-ID: <DB6PR0501MB251840D45FC427B1A7B7572AAAA10@DB6PR0501MB2518.eurprd05.prod.outlook.com> (raw)
In-Reply-To: <alpine.DEB.2.20.1610311137290.8160@nanos>

> From: Thomas Gleixner [mailto:tglx-hfZtesqFncYOwBW4kG4KsQ@public.gmane.org] 
> Sent: Monday, October 31, 2016 7:40 PM

>>  
>>  static unsigned long nps_timer_rate;
>> +static int nps_get_timer_clk(struct device_node *node,
>
>Please don't glue variables and functions together w/o a new line. That's horrible to read.
Will be fixed in V4

>> +static int __init nps_setup_clocksource(struct device_node *node)
>>  {
>>  	int ret, cluster;
>> +	struct clk *clk;
>>  
>>  	for (cluster = 0; cluster < NPS_CLUSTER_NUM; cluster++)
>>  		nps_msu_reg_low_addr[cluster] =
>>  			nps_host_reg((cluster << NPS_CLUSTER_OFFSET),
>>  				 NPS_MSU_BLKID, NPS_MSU_TICK_LOW);
>>  
>> -	ret = clk_prepare_enable(clk);
>> -	if (ret) {
>> -		pr_err("Couldn't enable parent clock\n");
>> -		return ret;
>> -	}
>> -
>> -	nps_timer_rate = clk_get_rate(clk);
>> +	nps_get_timer_clk(node, &nps_timer_rate, clk);

>Why are you ignoring the return code? It was handled before your change ...
Will be fixed in V4

Regards,
Noam
--
To unsubscribe from this list: send the line "unsubscribe devicetree" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

  reply	other threads:[~2016-11-01  9:22 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-10-31  7:37 [PATCH v3 0/3] Add clockevet for timer-nps driver to NPS400 SoC Noam Camus
2016-10-31  7:37 ` Noam Camus
2016-10-31  7:37 ` [PATCH v3 1/3] soc: Support for NPS HW scheduling Noam Camus
2016-10-31  7:37   ` Noam Camus
2016-10-31  7:37 ` [PATCH v3 2/3] clocksource: update "fn" at CLOCKSOURCE_OF_DECLARE() of nps400 timer Noam Camus
2016-10-31  7:37   ` Noam Camus
2016-10-31 17:39   ` Thomas Gleixner
2016-11-01  9:07     ` Noam Camus [this message]
2016-11-01  9:07       ` Noam Camus
2016-10-31  7:37 ` [PATCH v3 3/3] clocksource: Add clockevent support to NPS400 driver Noam Camus
2016-10-31  7:37   ` Noam Camus
2016-10-31 18:12   ` Thomas Gleixner
2016-10-31 18:12     ` Thomas Gleixner
2016-11-01  9:03     ` Noam Camus
2016-11-01 18:45       ` Thomas Gleixner

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=DB6PR0501MB251840D45FC427B1A7B7572AAAA10@DB6PR0501MB2518.eurprd05.prod.outlook.com \
    --to=noamca@mellanox.com \
    --cc=daniel.lezcano@linaro.org \
    --cc=devicetree@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mark.rutland@arm.com \
    --cc=robh+dt@kernel.org \
    --cc=tglx@linutronix.de \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.