public inbox for linux-omap@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH]TWL4030 battery driver madc str fix
@ 2008-09-18  8:44 Madhusudhan Chikkature
  2008-09-18  8:53 ` Pakaravoor, Jagadeesh
  0 siblings, 1 reply; 4+ messages in thread
From: Madhusudhan Chikkature @ 2008-09-18  8:44 UTC (permalink / raw)
  To: tony; +Cc: linux-omap

Hi Tony,

This patch set up the unused memebrs of the madc structure used in the battery
driver to NULL.

Regards,
Madhu
-------------------------------------------------------
From: Madhusudhan Chikkature<madhu.cr@ti.com>

This patch set up the unused madc request structure members to NULL.

Signed-off-by: Madhusudhan Chikkature<madhu.cr@ti.com>
---
 drivers/power/twl4030_bci_battery.c |    2 ++
 1 files changed, 2 insertions(+)

Index: linux-omap-2.6/drivers/power/twl4030_bci_battery.c
===================================================================
--- linux-omap-2.6.orig/drivers/power/twl4030_bci_battery.c	2008-09-10
10:16:20.000000000 +0530
+++ linux-omap-2.6/drivers/power/twl4030_bci_battery.c	2008-09-18
11:06:07.000000000 +0530
@@ -604,7 +604,9 @@ static int twl4030backupbatt_voltage(voi
 	struct twl4030_madc_request req;

 	req.channels = (1 << 9);
+	req.do_avg = NULL;
 	req.method = TWL4030_MADC_SW1;
+	req.active = NULL;
 	req.func_cb = NULL;
 	twl4030_madc_conversion(&req);
 	temp = (u16)req.rbuf[9];



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

* RE: [PATCH]TWL4030 battery driver madc str fix
  2008-09-18  8:44 Madhusudhan Chikkature
@ 2008-09-18  8:53 ` Pakaravoor, Jagadeesh
  0 siblings, 0 replies; 4+ messages in thread
From: Pakaravoor, Jagadeesh @ 2008-09-18  8:53 UTC (permalink / raw)
  To: Chikkature Rajashekar, Madhusudhan; +Cc: linux-omap@vger.kernel.org

>  	struct twl4030_madc_request req;
> 
>  	req.channels = (1 << 9);
> +	req.do_avg = NULL;
>  	req.method = TWL4030_MADC_SW1;
> +	req.active = NULL;
>  	req.func_cb = NULL;
>  	twl4030_madc_conversion(&req);
>  	temp = (u16)req.rbuf[9];

As per twl4030_madc_request structure 'do_avg' is a u16, and 'active' is an integer. So they should be initialized to 0 instead of NULL.

--
Regards,
Jagadeesh

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

* [PATCH]TWL4030 battery driver madc str fix
@ 2008-09-18 11:58 Madhusudhan Chikkature
  2008-09-23 10:54 ` Tony Lindgren
  0 siblings, 1 reply; 4+ messages in thread
From: Madhusudhan Chikkature @ 2008-09-18 11:58 UTC (permalink / raw)
  To: tony; +Cc: linux-omap

Hi Tony,

I am resending the patch after fixing the comment provided by Jagadeesh.

Regards,
Madhu
-------------------------------------------------------------------------
From: Madhusudhan Chikkature<madhu.cr@ti.com>

This patch set up the unused madc request structure members to NULL.

Signed-off-by: Madhusudhan Chikkature<madhu.cr@ti.com>
---
 drivers/power/twl4030_bci_battery.c |    2 ++
 1 files changed, 2 insertions(+)

Index: linux-omap-2.6/drivers/power/twl4030_bci_battery.c
===================================================================
--- linux-omap-2.6.orig/drivers/power/twl4030_bci_battery.c	2008-09-10
10:16:20.000000000 +0530
+++ linux-omap-2.6/drivers/power/twl4030_bci_battery.c	2008-09-18
17:12:22.000000000 +0530
@@ -604,7 +604,9 @@
 	struct twl4030_madc_request req;

 	req.channels = (1 << 9);
+	req.do_avg = 0;
 	req.method = TWL4030_MADC_SW1;
+	req.active = 0;
 	req.func_cb = NULL;
 	twl4030_madc_conversion(&req);
 	temp = (u16)req.rbuf[9];



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

* Re: [PATCH]TWL4030 battery driver madc str fix
  2008-09-18 11:58 [PATCH]TWL4030 battery driver madc str fix Madhusudhan Chikkature
@ 2008-09-23 10:54 ` Tony Lindgren
  0 siblings, 0 replies; 4+ messages in thread
From: Tony Lindgren @ 2008-09-23 10:54 UTC (permalink / raw)
  To: Madhusudhan Chikkature; +Cc: linux-omap

* Madhusudhan Chikkature <madhu.cr@ti.com> [080918 14:58]:
> Hi Tony,
> 
> I am resending the patch after fixing the comment provided by Jagadeesh.

Pushing

Tony

> 
> Regards,
> Madhu
> -------------------------------------------------------------------------
> From: Madhusudhan Chikkature<madhu.cr@ti.com>
> 
> This patch set up the unused madc request structure members to NULL.
> 
> Signed-off-by: Madhusudhan Chikkature<madhu.cr@ti.com>
> ---
>  drivers/power/twl4030_bci_battery.c |    2 ++
>  1 files changed, 2 insertions(+)
> 
> Index: linux-omap-2.6/drivers/power/twl4030_bci_battery.c
> ===================================================================
> --- linux-omap-2.6.orig/drivers/power/twl4030_bci_battery.c	2008-09-10
> 10:16:20.000000000 +0530
> +++ linux-omap-2.6/drivers/power/twl4030_bci_battery.c	2008-09-18
> 17:12:22.000000000 +0530
> @@ -604,7 +604,9 @@
>  	struct twl4030_madc_request req;
> 
>  	req.channels = (1 << 9);
> +	req.do_avg = 0;
>  	req.method = TWL4030_MADC_SW1;
> +	req.active = 0;
>  	req.func_cb = NULL;
>  	twl4030_madc_conversion(&req);
>  	temp = (u16)req.rbuf[9];
> 
> 

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

end of thread, other threads:[~2008-09-23 10:54 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2008-09-18 11:58 [PATCH]TWL4030 battery driver madc str fix Madhusudhan Chikkature
2008-09-23 10:54 ` Tony Lindgren
  -- strict thread matches above, loose matches on Subject: below --
2008-09-18  8:44 Madhusudhan Chikkature
2008-09-18  8:53 ` Pakaravoor, Jagadeesh

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