public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH] Power: charger-manager: Fixed coding style
@ 2014-01-06 15:46 Jesper Falk
  2014-01-10  0:30 ` Chanwoo Choi
  0 siblings, 1 reply; 3+ messages in thread
From: Jesper Falk @ 2014-01-06 15:46 UTC (permalink / raw)
  To: anton; +Cc: dwmw2, linux-kernel, Jesper Falk

Removed apaces before semicolon and fixed brackets on if statements

Signed-off-by: Jesper Falk <jesperfalk94@gmail.com>
---
 drivers/power/charger-manager.c | 19 ++++++++-----------
 1 file changed, 8 insertions(+), 11 deletions(-)

diff --git a/drivers/power/charger-manager.c b/drivers/power/charger-manager.c
index 7287c0e..4c5a848 100644
--- a/drivers/power/charger-manager.c
+++ b/drivers/power/charger-manager.c
@@ -327,7 +327,7 @@ static int try_charger_enable(struct charger_manager *cm, bool enable)
 		cm->charging_start_time = ktime_to_ms(ktime_get());
 		cm->charging_end_time = 0;
 
-		for (i = 0 ; i < desc->num_charger_regulators ; i++) {
+		for (i = 0; i < desc->num_charger_regulators; i++) {
 			if (desc->charger_regulators[i].externally_control)
 				continue;
 
@@ -345,7 +345,7 @@ static int try_charger_enable(struct charger_manager *cm, bool enable)
 		cm->charging_start_time = 0;
 		cm->charging_end_time = ktime_to_ms(ktime_get());
 
-		for (i = 0 ; i < desc->num_charger_regulators ; i++) {
+		for (i = 0; i < desc->num_charger_regulators; i++) {
 			if (desc->charger_regulators[i].externally_control)
 				continue;
 
@@ -1476,20 +1476,17 @@ static int charger_manager_probe(struct platform_device *pdev)
 	 * The following two do not need to be errors.
 	 * Users may intentionally ignore those two features.
 	 */
-	if (desc->fullbatt_uV == 0) {
+	if (desc->fullbatt_uV == 0)
 		dev_info(&pdev->dev, "Ignoring full-battery voltage threshold as it is not supplied\n");
-	}
 	if (!desc->fullbatt_vchkdrop_ms || !desc->fullbatt_vchkdrop_uV) {
 		dev_info(&pdev->dev, "Disabling full-battery voltage drop checking mechanism as it is not supplied\n");
 		desc->fullbatt_vchkdrop_ms = 0;
 		desc->fullbatt_vchkdrop_uV = 0;
 	}
-	if (desc->fullbatt_soc == 0) {
+	if (desc->fullbatt_soc == 0)
 		dev_info(&pdev->dev, "Ignoring full-battery soc(state of charge) threshold as it is not supplied\n");
-	}
-	if (desc->fullbatt_full_capacity == 0) {
+	if (desc->fullbatt_full_capacity == 0)
 		dev_info(&pdev->dev, "Ignoring full-battery full capacity threshold as it is not supplied\n");
-	}
 
 	if (!desc->charger_regulators || desc->num_charger_regulators < 1) {
 		dev_err(&pdev->dev, "charger_regulators undefined\n");
@@ -1676,16 +1673,16 @@ static int charger_manager_remove(struct platform_device *pdev)
 	cancel_work_sync(&setup_polling);
 	cancel_delayed_work_sync(&cm_monitor_work);
 
-	for (i = 0 ; i < desc->num_charger_regulators ; i++) {
+	for (i = 0; i < desc->num_charger_regulators; i++) {
 		struct charger_regulator *charger
 				= &desc->charger_regulators[i];
-		for (j = 0 ; j < charger->num_cables ; j++) {
+		for (j = 0; j < charger->num_cables; j++) {
 			struct charger_cable *cable = &charger->cables[j];
 			extcon_unregister_interest(&cable->extcon_dev);
 		}
 	}
 
-	for (i = 0 ; i < desc->num_charger_regulators ; i++)
+	for (i = 0; i < desc->num_charger_regulators; i++)
 		regulator_put(desc->charger_regulators[i].consumer);
 
 	power_supply_unregister(&cm->charger_psy);
-- 
1.8.5.2


^ permalink raw reply related	[flat|nested] 3+ messages in thread

* Re: [PATCH] Power: charger-manager: Fixed coding style
  2014-01-06 15:46 [PATCH] Power: charger-manager: Fixed coding style Jesper Falk
@ 2014-01-10  0:30 ` Chanwoo Choi
  2014-01-10  0:31   ` Chanwoo Choi
  0 siblings, 1 reply; 3+ messages in thread
From: Chanwoo Choi @ 2014-01-10  0:30 UTC (permalink / raw)
  To: Jesper Falk; +Cc: anton, dwmw2, linux-kernel

On 01/07/2014 12:46 AM, Jesper Falk wrote:
> Removed apaces before semicolon and fixed brackets on if statements
> 
> Signed-off-by: Jesper Falk <jesperfalk94@gmail.com>
> ---
>  drivers/power/charger-manager.c | 19 ++++++++-----------
>  1 file changed, 8 insertions(+), 11 deletions(-)
> 

Acked-by: Chanwoo Choi

I reviewed and tested this patch.

Thanks,
Chanwoo Choi


^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PATCH] Power: charger-manager: Fixed coding style
  2014-01-10  0:30 ` Chanwoo Choi
@ 2014-01-10  0:31   ` Chanwoo Choi
  0 siblings, 0 replies; 3+ messages in thread
From: Chanwoo Choi @ 2014-01-10  0:31 UTC (permalink / raw)
  To: Jesper Falk; +Cc: anton, dwmw2, linux-kernel

On 01/10/2014 09:30 AM, Chanwoo Choi wrote:
> On 01/07/2014 12:46 AM, Jesper Falk wrote:
>> Removed apaces before semicolon and fixed brackets on if statements
>>
>> Signed-off-by: Jesper Falk <jesperfalk94@gmail.com>
>> ---
>>  drivers/power/charger-manager.c | 19 ++++++++-----------
>>  1 file changed, 8 insertions(+), 11 deletions(-)
>>
> 
> Acked-by: Chanwoo Choi
> 
> I reviewed and tested this patch.
> 
> Thanks,
> Chanwoo Choi
> 
Sorry, I am missing email address.

Acked-by: Chanwoo Choi <cw00.choi@samsung.com>

Thanks,
Chanwoo Choi

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2014-01-10  0:31 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-01-06 15:46 [PATCH] Power: charger-manager: Fixed coding style Jesper Falk
2014-01-10  0:30 ` Chanwoo Choi
2014-01-10  0:31   ` Chanwoo Choi

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox