* [PATCH] ACPI/fan: Initialize acpi_state variable
@ 2013-06-27 11:08 naresh.bhat
2013-06-27 12:28 ` Rafael J. Wysocki
0 siblings, 1 reply; 10+ messages in thread
From: naresh.bhat @ 2013-06-27 11:08 UTC (permalink / raw)
To: linux-acpi; +Cc: len.brown, patches, linaro-kernel, naresh.bhat, linux-kernel
From: Naresh Bhat <naresh.bhat@linaro.org>
CC drivers/acpi/fan.o
drivers/acpi/fan.c: In function ‘fan_get_cur_state’:
drivers/acpi/fan.c:96:9: warning: ‘acpi_state’ may be used uninitialized in this function [-Wuninitialized]
---
drivers/acpi/fan.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/acpi/fan.c b/drivers/acpi/fan.c
index f815da8..f61f7fd 100644
--- a/drivers/acpi/fan.c
+++ b/drivers/acpi/fan.c
@@ -84,7 +84,7 @@ static int fan_get_cur_state(struct thermal_cooling_device *cdev, unsigned long
{
struct acpi_device *device = cdev->devdata;
int result;
- int acpi_state;
+ int acpi_state = 0;
if (!device)
return -EINVAL;
--
1.7.9.5
^ permalink raw reply related [flat|nested] 10+ messages in thread
* Re: [PATCH] ACPI/fan: Initialize acpi_state variable
2013-06-27 11:08 [PATCH] ACPI/fan: Initialize acpi_state variable naresh.bhat
@ 2013-06-27 12:28 ` Rafael J. Wysocki
2013-06-27 13:07 ` Naresh Bhat
0 siblings, 1 reply; 10+ messages in thread
From: Rafael J. Wysocki @ 2013-06-27 12:28 UTC (permalink / raw)
To: naresh.bhat; +Cc: linux-acpi, len.brown, patches, linaro-kernel, linux-kernel
On Thursday, June 27, 2013 04:38:34 PM naresh.bhat@linaro.org wrote:
> From: Naresh Bhat <naresh.bhat@linaro.org>
>
> CC drivers/acpi/fan.o
> drivers/acpi/fan.c: In function ‘fan_get_cur_state’:
> drivers/acpi/fan.c:96:9: warning: ‘acpi_state’ may be used uninitialized in this function [-Wuninitialized]
> ---
> drivers/acpi/fan.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/acpi/fan.c b/drivers/acpi/fan.c
> index f815da8..f61f7fd 100644
> --- a/drivers/acpi/fan.c
> +++ b/drivers/acpi/fan.c
> @@ -84,7 +84,7 @@ static int fan_get_cur_state(struct thermal_cooling_device *cdev, unsigned long
> {
> struct acpi_device *device = cdev->devdata;
> int result;
> - int acpi_state;
> + int acpi_state = 0;
Please use an appropriate symbol here.
>
> if (!device)
> return -EINVAL;
>
Thanks,
Rafael
--
I speak only for myself.
Rafael J. Wysocki, Intel Open Source Technology Center.
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: [PATCH] ACPI/fan: Initialize acpi_state variable
2013-06-27 12:28 ` Rafael J. Wysocki
@ 2013-06-27 13:07 ` Naresh Bhat
2013-06-27 19:29 ` Rafael J. Wysocki
0 siblings, 1 reply; 10+ messages in thread
From: Naresh Bhat @ 2013-06-27 13:07 UTC (permalink / raw)
To: Rafael J. Wysocki
Cc: linux-acpi, len.brown, patches, linaro-kernel, linux-kernel
Hi Rafael,
You mean I need to initialize using ACPI_STATE_D0 ? and resend the patch ?
Thanks
-Naresh Bhat
On 27 June 2013 17:58, Rafael J. Wysocki <rjw@sisk.pl> wrote:
> On Thursday, June 27, 2013 04:38:34 PM naresh.bhat@linaro.org wrote:
>> From: Naresh Bhat <naresh.bhat@linaro.org>
>>
>> CC drivers/acpi/fan.o
>> drivers/acpi/fan.c: In function ‘fan_get_cur_state’:
>> drivers/acpi/fan.c:96:9: warning: ‘acpi_state’ may be used uninitialized in this function [-Wuninitialized]
>> ---
>> drivers/acpi/fan.c | 2 +-
>> 1 file changed, 1 insertion(+), 1 deletion(-)
>>
>> diff --git a/drivers/acpi/fan.c b/drivers/acpi/fan.c
>> index f815da8..f61f7fd 100644
>> --- a/drivers/acpi/fan.c
>> +++ b/drivers/acpi/fan.c
>> @@ -84,7 +84,7 @@ static int fan_get_cur_state(struct thermal_cooling_device *cdev, unsigned long
>> {
>> struct acpi_device *device = cdev->devdata;
>> int result;
>> - int acpi_state;
>> + int acpi_state = 0;
>
> Please use an appropriate symbol here.
>
>>
>> if (!device)
>> return -EINVAL;
>>
>
> Thanks,
> Rafael
>
>
> --
> I speak only for myself.
> Rafael J. Wysocki, Intel Open Source Technology Center.
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: [PATCH] ACPI/fan: Initialize acpi_state variable
2013-06-27 13:07 ` Naresh Bhat
@ 2013-06-27 19:29 ` Rafael J. Wysocki
2013-06-27 19:49 ` Naresh Bhat
0 siblings, 1 reply; 10+ messages in thread
From: Rafael J. Wysocki @ 2013-06-27 19:29 UTC (permalink / raw)
To: Naresh Bhat; +Cc: linux-acpi, len.brown, patches, linaro-kernel, linux-kernel
On Thursday, June 27, 2013 06:37:35 PM Naresh Bhat wrote:
> Hi Rafael,
>
> You mean I need to initialize using ACPI_STATE_D0 ? and resend the patch ?
Yes, please.
Although this is a false positive anyway ...
Thanks,
Rafael
> On 27 June 2013 17:58, Rafael J. Wysocki <rjw@sisk.pl> wrote:
> > On Thursday, June 27, 2013 04:38:34 PM naresh.bhat@linaro.org wrote:
> >> From: Naresh Bhat <naresh.bhat@linaro.org>
> >>
> >> CC drivers/acpi/fan.o
> >> drivers/acpi/fan.c: In function ‘fan_get_cur_state’:
> >> drivers/acpi/fan.c:96:9: warning: ‘acpi_state’ may be used uninitialized in this function [-Wuninitialized]
> >> ---
> >> drivers/acpi/fan.c | 2 +-
> >> 1 file changed, 1 insertion(+), 1 deletion(-)
> >>
> >> diff --git a/drivers/acpi/fan.c b/drivers/acpi/fan.c
> >> index f815da8..f61f7fd 100644
> >> --- a/drivers/acpi/fan.c
> >> +++ b/drivers/acpi/fan.c
> >> @@ -84,7 +84,7 @@ static int fan_get_cur_state(struct thermal_cooling_device *cdev, unsigned long
> >> {
> >> struct acpi_device *device = cdev->devdata;
> >> int result;
> >> - int acpi_state;
> >> + int acpi_state = 0;
> >
> > Please use an appropriate symbol here.
> >
> >>
> >> if (!device)
> >> return -EINVAL;
> >>
> >
> > Thanks,
> > Rafael
> >
> >
> > --
> > I speak only for myself.
> > Rafael J. Wysocki, Intel Open Source Technology Center.
--
I speak only for myself.
Rafael J. Wysocki, Intel Open Source Technology Center.
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: [PATCH] ACPI/fan: Initialize acpi_state variable
2013-06-27 19:29 ` Rafael J. Wysocki
@ 2013-06-27 19:49 ` Naresh Bhat
0 siblings, 0 replies; 10+ messages in thread
From: Naresh Bhat @ 2013-06-27 19:49 UTC (permalink / raw)
To: Rafael J. Wysocki
Cc: linux-acpi, len.brown, Patch Tracking, linaro-kernel, linux-kernel
Done.
Thank you very much
-Naresh Bhat
On 28 June 2013 00:59, Rafael J. Wysocki <rjw@sisk.pl> wrote:
> On Thursday, June 27, 2013 06:37:35 PM Naresh Bhat wrote:
>> Hi Rafael,
>>
>> You mean I need to initialize using ACPI_STATE_D0 ? and resend the patch ?
>
> Yes, please.
>
> Although this is a false positive anyway ...
>
> Thanks,
> Rafael
>
>
>> On 27 June 2013 17:58, Rafael J. Wysocki <rjw@sisk.pl> wrote:
>> > On Thursday, June 27, 2013 04:38:34 PM naresh.bhat@linaro.org wrote:
>> >> From: Naresh Bhat <naresh.bhat@linaro.org>
>> >>
>> >> CC drivers/acpi/fan.o
>> >> drivers/acpi/fan.c: In function ‘fan_get_cur_state’:
>> >> drivers/acpi/fan.c:96:9: warning: ‘acpi_state’ may be used uninitialized in this function [-Wuninitialized]
>> >> ---
>> >> drivers/acpi/fan.c | 2 +-
>> >> 1 file changed, 1 insertion(+), 1 deletion(-)
>> >>
>> >> diff --git a/drivers/acpi/fan.c b/drivers/acpi/fan.c
>> >> index f815da8..f61f7fd 100644
>> >> --- a/drivers/acpi/fan.c
>> >> +++ b/drivers/acpi/fan.c
>> >> @@ -84,7 +84,7 @@ static int fan_get_cur_state(struct thermal_cooling_device *cdev, unsigned long
>> >> {
>> >> struct acpi_device *device = cdev->devdata;
>> >> int result;
>> >> - int acpi_state;
>> >> + int acpi_state = 0;
>> >
>> > Please use an appropriate symbol here.
>> >
>> >>
>> >> if (!device)
>> >> return -EINVAL;
>> >>
>> >
>> > Thanks,
>> > Rafael
>> >
>> >
>> > --
>> > I speak only for myself.
>> > Rafael J. Wysocki, Intel Open Source Technology Center.
> --
> I speak only for myself.
> Rafael J. Wysocki, Intel Open Source Technology Center.
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: [PATCH] ACPI/fan: Initialize acpi_state variable
2013-07-01 13:59 ` Rafael J. Wysocki
@ 2013-07-01 14:25 ` Naresh Bhat
0 siblings, 0 replies; 10+ messages in thread
From: Naresh Bhat @ 2013-07-01 14:25 UTC (permalink / raw)
To: Rafael J. Wysocki
Cc: linux-acpi, len.brown, Patch Tracking, linaro-kernel, linux-kernel
Opps sorry about that. I have added my sign-off and send the patch.
Thanks
Naresh Bhat
On 1 July 2013 19:29, Rafael J. Wysocki <rjw@sisk.pl> wrote:
> On Monday, July 01, 2013 05:31:46 PM Naresh Bhat wrote:
>> Hi Rafeal,
>>
>> I appreciate if you give any feedback on the provided patch.
>
> The patch is OK, but please add your sign-off.
>
> Thanks,
> Rafael
>
>
>> On 28 June 2013 01:17, <naresh.bhat@linaro.org> wrote:
>> > From: Naresh Bhat <naresh.bhat@linaro.org>
>> >
>> > CC drivers/acpi/fan.o
>> > drivers/acpi/fan.c: In function ‘fan_get_cur_state’:
>> > drivers/acpi/fan.c:96:9: warning: ‘acpi_state’ may be used uninitialized in this function [-Wuninitialized]
>> > ---
>> > drivers/acpi/fan.c | 2 +-
>> > 1 file changed, 1 insertion(+), 1 deletion(-)
>> >
>> > diff --git a/drivers/acpi/fan.c b/drivers/acpi/fan.c
>> > index f815da8..f961435 100644
>> > --- a/drivers/acpi/fan.c
>> > +++ b/drivers/acpi/fan.c
>> > @@ -84,7 +84,7 @@ static int fan_get_cur_state(struct thermal_cooling_device *cdev, unsigned long
>> > {
>> > struct acpi_device *device = cdev->devdata;
>> > int result;
>> > - int acpi_state;
>> > + int acpi_state = ACPI_STATE_D0;
>> >
>> > if (!device)
>> > return -EINVAL;
>> > --
>> > 1.7.9.5
>> >
> --
> I speak only for myself.
> Rafael J. Wysocki, Intel Open Source Technology Center.
^ permalink raw reply [flat|nested] 10+ messages in thread
* [PATCH] ACPI/fan: Initialize acpi_state variable
@ 2013-07-01 14:21 naresh.bhat
0 siblings, 0 replies; 10+ messages in thread
From: naresh.bhat @ 2013-07-01 14:21 UTC (permalink / raw)
To: linux-acpi; +Cc: len.brown, patches, linaro-kernel, naresh.bhat, linux-kernel
From: Naresh Bhat <naresh.bhat@linaro.org>
CC drivers/acpi/fan.o
drivers/acpi/fan.c: In function ‘fan_get_cur_state’:
drivers/acpi/fan.c:96:9: warning: ‘acpi_state’ may be used uninitialized in this function [-Wuninitialized]
Signed-off-by: Naresh Bhat <naresh.bhat@linaro.org>
---
drivers/acpi/fan.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/acpi/fan.c b/drivers/acpi/fan.c
index 8d1c010..5b02a0a 100644
--- a/drivers/acpi/fan.c
+++ b/drivers/acpi/fan.c
@@ -84,7 +84,7 @@ static int fan_get_cur_state(struct thermal_cooling_device *cdev, unsigned long
{
struct acpi_device *device = cdev->devdata;
int result;
- int acpi_state;
+ int acpi_state = ACPI_STATE_D0;
if (!device)
return -EINVAL;
--
1.7.9.5
^ permalink raw reply related [flat|nested] 10+ messages in thread
* Re: [PATCH] ACPI/fan: Initialize acpi_state variable
2013-07-01 12:01 ` Naresh Bhat
@ 2013-07-01 13:59 ` Rafael J. Wysocki
2013-07-01 14:25 ` Naresh Bhat
0 siblings, 1 reply; 10+ messages in thread
From: Rafael J. Wysocki @ 2013-07-01 13:59 UTC (permalink / raw)
To: Naresh Bhat
Cc: linux-acpi, len.brown, Patch Tracking, linaro-kernel, linux-kernel
On Monday, July 01, 2013 05:31:46 PM Naresh Bhat wrote:
> Hi Rafeal,
>
> I appreciate if you give any feedback on the provided patch.
The patch is OK, but please add your sign-off.
Thanks,
Rafael
> On 28 June 2013 01:17, <naresh.bhat@linaro.org> wrote:
> > From: Naresh Bhat <naresh.bhat@linaro.org>
> >
> > CC drivers/acpi/fan.o
> > drivers/acpi/fan.c: In function ‘fan_get_cur_state’:
> > drivers/acpi/fan.c:96:9: warning: ‘acpi_state’ may be used uninitialized in this function [-Wuninitialized]
> > ---
> > drivers/acpi/fan.c | 2 +-
> > 1 file changed, 1 insertion(+), 1 deletion(-)
> >
> > diff --git a/drivers/acpi/fan.c b/drivers/acpi/fan.c
> > index f815da8..f961435 100644
> > --- a/drivers/acpi/fan.c
> > +++ b/drivers/acpi/fan.c
> > @@ -84,7 +84,7 @@ static int fan_get_cur_state(struct thermal_cooling_device *cdev, unsigned long
> > {
> > struct acpi_device *device = cdev->devdata;
> > int result;
> > - int acpi_state;
> > + int acpi_state = ACPI_STATE_D0;
> >
> > if (!device)
> > return -EINVAL;
> > --
> > 1.7.9.5
> >
--
I speak only for myself.
Rafael J. Wysocki, Intel Open Source Technology Center.
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: [PATCH] ACPI/fan: Initialize acpi_state variable
2013-06-27 19:47 naresh.bhat
@ 2013-07-01 12:01 ` Naresh Bhat
2013-07-01 13:59 ` Rafael J. Wysocki
0 siblings, 1 reply; 10+ messages in thread
From: Naresh Bhat @ 2013-07-01 12:01 UTC (permalink / raw)
To: linux-acpi
Cc: len.brown, Patch Tracking, linaro-kernel, Naresh Bhat,
linux-kernel, Rafael J. Wysocki
Hi Rafeal,
I appreciate if you give any feedback on the provided patch.
Thanks
-Naresh Bhat
On 28 June 2013 01:17, <naresh.bhat@linaro.org> wrote:
> From: Naresh Bhat <naresh.bhat@linaro.org>
>
> CC drivers/acpi/fan.o
> drivers/acpi/fan.c: In function ‘fan_get_cur_state’:
> drivers/acpi/fan.c:96:9: warning: ‘acpi_state’ may be used uninitialized in this function [-Wuninitialized]
> ---
> drivers/acpi/fan.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/acpi/fan.c b/drivers/acpi/fan.c
> index f815da8..f961435 100644
> --- a/drivers/acpi/fan.c
> +++ b/drivers/acpi/fan.c
> @@ -84,7 +84,7 @@ static int fan_get_cur_state(struct thermal_cooling_device *cdev, unsigned long
> {
> struct acpi_device *device = cdev->devdata;
> int result;
> - int acpi_state;
> + int acpi_state = ACPI_STATE_D0;
>
> if (!device)
> return -EINVAL;
> --
> 1.7.9.5
>
^ permalink raw reply [flat|nested] 10+ messages in thread
* [PATCH] ACPI/fan: Initialize acpi_state variable
@ 2013-06-27 19:47 naresh.bhat
2013-07-01 12:01 ` Naresh Bhat
0 siblings, 1 reply; 10+ messages in thread
From: naresh.bhat @ 2013-06-27 19:47 UTC (permalink / raw)
To: linux-acpi
Cc: len.brown, patches, linaro-kernel, naresh.bhat, linux-kernel, rjw
From: Naresh Bhat <naresh.bhat@linaro.org>
CC drivers/acpi/fan.o
drivers/acpi/fan.c: In function ‘fan_get_cur_state’:
drivers/acpi/fan.c:96:9: warning: ‘acpi_state’ may be used uninitialized in this function [-Wuninitialized]
---
drivers/acpi/fan.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/acpi/fan.c b/drivers/acpi/fan.c
index f815da8..f961435 100644
--- a/drivers/acpi/fan.c
+++ b/drivers/acpi/fan.c
@@ -84,7 +84,7 @@ static int fan_get_cur_state(struct thermal_cooling_device *cdev, unsigned long
{
struct acpi_device *device = cdev->devdata;
int result;
- int acpi_state;
+ int acpi_state = ACPI_STATE_D0;
if (!device)
return -EINVAL;
--
1.7.9.5
^ permalink raw reply related [flat|nested] 10+ messages in thread
end of thread, other threads:[~2013-07-01 14:25 UTC | newest]
Thread overview: 10+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-06-27 11:08 [PATCH] ACPI/fan: Initialize acpi_state variable naresh.bhat
2013-06-27 12:28 ` Rafael J. Wysocki
2013-06-27 13:07 ` Naresh Bhat
2013-06-27 19:29 ` Rafael J. Wysocki
2013-06-27 19:49 ` Naresh Bhat
2013-06-27 19:47 naresh.bhat
2013-07-01 12:01 ` Naresh Bhat
2013-07-01 13:59 ` Rafael J. Wysocki
2013-07-01 14:25 ` Naresh Bhat
2013-07-01 14:21 naresh.bhat
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).