2013-03-07 10:37:34

by Tang Chen

[permalink] [raw]
Subject: [RESEND PATCH 0/6] Fix some coding style and comment problems.

Fix some coding style and comment problems I saw when I was reading the code.

Tang Chen (6):
acpi: Remove the leading space of "unlock" label in
acpi_memory_device_notify().
acpi: Add missing parameter comment for acpi_get_table_with_size().
acpi: Remove the leading spaces of "finish_override" label in
acpi_tb_table_override().
acpi: Remove the leading spaces of "unmap_and_exit" label in
acpi_tb_install_table().
acpi: Add the missing parameter comment for acpi_initialize_tables().
doc: Fix a wrong comment in Documentation/hw_random.txt

Documentation/hw_random.txt | 2 +-
drivers/acpi/acpi_memhotplug.c | 2 +-
drivers/acpi/acpica/tbinstal.c | 2 +-
drivers/acpi/acpica/tbutils.c | 2 +-
drivers/acpi/acpica/tbxface.c | 6 +++---
5 files changed, 7 insertions(+), 7 deletions(-)


2013-03-07 10:36:10

by Tang Chen

[permalink] [raw]
Subject: [RESEND PATCH 5/6] acpi: Add the missing parameter comment for acpi_initialize_tables().

In the comment of acpi_initialize_tables(), it mistakes allow_resize
with allow_realloc.

Signed-off-by: Tang Chen <[email protected]>
---
drivers/acpi/acpica/tbxface.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/drivers/acpi/acpica/tbxface.c b/drivers/acpi/acpica/tbxface.c
index 93d1432..659e0f6 100644
--- a/drivers/acpi/acpica/tbxface.c
+++ b/drivers/acpi/acpica/tbxface.c
@@ -80,7 +80,7 @@ acpi_status acpi_allocate_root_table(u32 initial_table_count)
* array is dynamically allocated.
* initial_table_count - Size of initial_table_array, in number of
* struct acpi_table_desc structures
- * allow_realloc - Flag to tell Table Manager if resize of
+ * allow_resize - Flag to tell Table Manager if resize of
* pre-allocated array is allowed. Ignored
* if initial_table_array is NULL.
*
--
1.7.1

2013-03-07 10:36:08

by Tang Chen

[permalink] [raw]
Subject: [RESEND PATCH 6/6] doc: Fix a wrong comment in Documentation/hw_random.txt

Seeing from the comment, there should be three reasons for removing request_mem_region.
Change the comment "two" to "three".

Signed-off-by: Tang Chen <[email protected]>
Acked-by: Rob Landley <[email protected]>
---
Documentation/hw_random.txt | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/Documentation/hw_random.txt b/Documentation/hw_random.txt
index 690f525..026e237 100644
--- a/Documentation/hw_random.txt
+++ b/Documentation/hw_random.txt
@@ -63,7 +63,7 @@ Intel RNG Driver notes:

* FIXME: support poll(2)

- NOTE: request_mem_region was removed, for two reasons:
+ NOTE: request_mem_region was removed, for three reasons:
1) Only one RNG is supported by this driver, 2) The location
used by the RNG is a fixed location in MMIO-addressable memory,
3) users with properly working BIOS e820 handling will always
--
1.7.1

2013-03-07 10:36:06

by Tang Chen

[permalink] [raw]
Subject: [RESEND PATCH 4/6] acpi: Remove the leading spaces of "unmap_and_exit" label in acpi_tb_install_table().

There are 6 leading spaces in front of "unmap_and_exit" label in acpi_tb_install_table(). Remove them.

Signed-off-by: Tang Chen <[email protected]>
---
drivers/acpi/acpica/tbutils.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/drivers/acpi/acpica/tbutils.c b/drivers/acpi/acpica/tbutils.c
index ce3d5db..27e7715 100644
--- a/drivers/acpi/acpica/tbutils.c
+++ b/drivers/acpi/acpica/tbutils.c
@@ -539,7 +539,7 @@ acpi_tb_install_table(acpi_physical_address address,
acpi_tb_delete_table(table_desc);
}

- unmap_and_exit:
+unmap_and_exit:

/* Always unmap the table header that we mapped above */

--
1.7.1

2013-03-07 10:36:01

by Tang Chen

[permalink] [raw]
Subject: [RESEND PATCH 1/6] acpi: Remove the leading space of "unlock" label in acpi_memory_device_notify().

There is a leading space in front of "unlock" label in acpi_memory_device_notify(). Remove it.

Signed-off-by: Tang Chen <[email protected]>
---
drivers/acpi/acpi_memhotplug.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/drivers/acpi/acpi_memhotplug.c b/drivers/acpi/acpi_memhotplug.c
index da1f82b..8a10c23 100644
--- a/drivers/acpi/acpi_memhotplug.c
+++ b/drivers/acpi/acpi_memhotplug.c
@@ -369,7 +369,7 @@ static void acpi_memory_device_notify(acpi_handle handle, u32 event, void *data)
kfree(ej_event);
}

- unlock:
+unlock:
acpi_scan_lock_release();
if (ACPI_SUCCESS(status))
return;
--
1.7.1

2013-03-07 10:36:55

by Tang Chen

[permalink] [raw]
Subject: [RESEND PATCH 2/6] acpi: Add missing parameter comment for acpi_get_table_with_size().

In the comment of acpi_get_table_with_size(), one parameter tbl_size
is missing. And the definitions of i and j begin with space, not tab.

Signed-off-by: Tang Chen <[email protected]>
---
drivers/acpi/acpica/tbxface.c | 4 ++--
1 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/acpi/acpica/tbxface.c b/drivers/acpi/acpica/tbxface.c
index b35a5e6..93d1432 100644
--- a/drivers/acpi/acpica/tbxface.c
+++ b/drivers/acpi/acpica/tbxface.c
@@ -304,6 +304,7 @@ ACPI_EXPORT_SYMBOL(acpi_unload_table_id)
* PARAMETERS: signature - ACPI signature of needed table
* instance - Which instance (for SSDTs)
* out_table - Where the pointer to the table is returned
+ * tbl_size - Size of the table
*
* RETURN: Status and pointer to table
*
@@ -315,8 +316,7 @@ acpi_get_table_with_size(char *signature,
u32 instance, struct acpi_table_header **out_table,
acpi_size *tbl_size)
{
- u32 i;
- u32 j;
+ u32 i, j;
acpi_status status;

/* Parameter validation */
--
1.7.1

2013-03-07 10:37:35

by Tang Chen

[permalink] [raw]
Subject: [RESEND PATCH 3/6] acpi: Remove the leading spaces of "finish_override" label in acpi_tb_table_override().

There is 7 leading spaces in front of "finish_override" label in acpi_tb_table_override(). Remove them.

Signed-off-by: Tang Chen <[email protected]>
---
drivers/acpi/acpica/tbinstal.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/drivers/acpi/acpica/tbinstal.c b/drivers/acpi/acpica/tbinstal.c
index e57cd38..b1e098d 100644
--- a/drivers/acpi/acpica/tbinstal.c
+++ b/drivers/acpi/acpica/tbinstal.c
@@ -313,7 +313,7 @@ struct acpi_table_header *acpi_tb_table_override(struct acpi_table_header

return (NULL); /* There was no override */

- finish_override:
+finish_override:

ACPI_INFO((AE_INFO,
"%4.4s %p %s table override, new table: %p",
--
1.7.1

2013-03-08 08:29:22

by Zheng, Lv

[permalink] [raw]
Subject: RE: [RESEND PATCH 3/6] acpi: Remove the leading spaces of "finish_override" label in acpi_tb_table_override().

Please do not try to fix ACPICA indentation problems in Linux side.
This will introduce source code divergences between ACPICA and Linux, which will add difficulties to ACPICA release work.
Please find real issues in ACPICA release scripts at:

https://github.com/acpica/acpica/tree/master/generate/linux

Thanks
-Lv

> -----Original Message-----
> From: Tang Chen [mailto:[email protected]]
> Sent: Thursday, March 07, 2013 6:38 PM
> To: [email protected]; [email protected]; Moore, Robert; Zheng, Lv;
> [email protected]; [email protected]; [email protected];
> [email protected]
> Cc: [email protected]; [email protected];
> [email protected]; [email protected]
> Subject: [RESEND PATCH 3/6] acpi: Remove the leading spaces of
> "finish_override" label in acpi_tb_table_override().
>
> There is 7 leading spaces in front of "finish_override" label in
> acpi_tb_table_override(). Remove them.
>
> Signed-off-by: Tang Chen <[email protected]>
> ---
> drivers/acpi/acpica/tbinstal.c | 2 +-
> 1 files changed, 1 insertions(+), 1 deletions(-)
>
> diff --git a/drivers/acpi/acpica/tbinstal.c b/drivers/acpi/acpica/tbinstal.c index
> e57cd38..b1e098d 100644
> --- a/drivers/acpi/acpica/tbinstal.c
> +++ b/drivers/acpi/acpica/tbinstal.c
> @@ -313,7 +313,7 @@ struct acpi_table_header
> *acpi_tb_table_override(struct acpi_table_header
>
> return (NULL); /* There was no override */
>
> - finish_override:
> +finish_override:
>
> ACPI_INFO((AE_INFO,
> "%4.4s %p %s table override, new table: %p",
> --
> 1.7.1

2013-03-08 09:00:16

by Tang Chen

[permalink] [raw]
Subject: Re: [RESEND PATCH 3/6] acpi: Remove the leading spaces of "finish_override" label in acpi_tb_table_override().

On 03/08/2013 04:28 PM, Zheng, Lv wrote:
> Please do not try to fix ACPICA indentation problems in Linux side.
> This will introduce source code divergences between ACPICA and Linux, which will add difficulties to ACPICA release work.
> Please find real issues in ACPICA release scripts at:
>
> https://github.com/acpica/acpica/tree/master/generate/linux

Hi Lv,

Thanks for telling me this. :)

One more thing, if I want to fix something in acpica, such as this patch
set,
who and which mail list should I send patches to ?

Thanks. :)

>
> Thanks
> -Lv
>
>> -----Original Message-----
>> From: Tang Chen [mailto:[email protected]]
>> Sent: Thursday, March 07, 2013 6:38 PM
>> To: [email protected]; [email protected]; Moore, Robert; Zheng, Lv;
>> [email protected]; [email protected]; [email protected];
>> [email protected]
>> Cc: [email protected]; [email protected];
>> [email protected]; [email protected]
>> Subject: [RESEND PATCH 3/6] acpi: Remove the leading spaces of
>> "finish_override" label in acpi_tb_table_override().
>>
>> There is 7 leading spaces in front of "finish_override" label in
>> acpi_tb_table_override(). Remove them.
>>
>> Signed-off-by: Tang Chen<[email protected]>
>> ---
>> drivers/acpi/acpica/tbinstal.c | 2 +-
>> 1 files changed, 1 insertions(+), 1 deletions(-)
>>
>> diff --git a/drivers/acpi/acpica/tbinstal.c b/drivers/acpi/acpica/tbinstal.c index
>> e57cd38..b1e098d 100644
>> --- a/drivers/acpi/acpica/tbinstal.c
>> +++ b/drivers/acpi/acpica/tbinstal.c
>> @@ -313,7 +313,7 @@ struct acpi_table_header
>> *acpi_tb_table_override(struct acpi_table_header
>>
>> return (NULL); /* There was no override */
>>
>> - finish_override:
>> +finish_override:
>>
>> ACPI_INFO((AE_INFO,
>> "%4.4s %p %s table override, new table: %p",
>> --
>> 1.7.1
>
> --
> To unsubscribe from this list: send the line "unsubscribe linux-acpi" in
> the body of a message to [email protected]
> More majordomo info at http://vger.kernel.org/majordomo-info.html
>

2013-03-08 12:45:14

by Rafael J. Wysocki

[permalink] [raw]
Subject: Re: [RESEND PATCH 3/6] acpi: Remove the leading spaces of "finish_override" label in acpi_tb_table_override().

On Friday, March 08, 2013 04:43:00 PM Tang Chen wrote:
> On 03/08/2013 04:28 PM, Zheng, Lv wrote:
> > Please do not try to fix ACPICA indentation problems in Linux side.
> > This will introduce source code divergences between ACPICA and Linux, which will add difficulties to ACPICA release work.
> > Please find real issues in ACPICA release scripts at:
> >
> > https://github.com/acpica/acpica/tree/master/generate/linux
>
> Hi Lv,
>
> Thanks for telling me this. :)
>
> One more thing, if I want to fix something in acpica, such as this patch
> set,
> who and which mail list should I send patches to ?

Please post them to [email protected] with CCs to me and Bob Moore.

Thanks,
Rafael


> >> -----Original Message-----
> >> From: Tang Chen [mailto:[email protected]]
> >> Sent: Thursday, March 07, 2013 6:38 PM
> >> To: [email protected]; [email protected]; Moore, Robert; Zheng, Lv;
> >> [email protected]; [email protected]; [email protected];
> >> [email protected]
> >> Cc: [email protected]; [email protected];
> >> [email protected]; [email protected]
> >> Subject: [RESEND PATCH 3/6] acpi: Remove the leading spaces of
> >> "finish_override" label in acpi_tb_table_override().
> >>
> >> There is 7 leading spaces in front of "finish_override" label in
> >> acpi_tb_table_override(). Remove them.
> >>
> >> Signed-off-by: Tang Chen<[email protected]>
> >> ---
> >> drivers/acpi/acpica/tbinstal.c | 2 +-
> >> 1 files changed, 1 insertions(+), 1 deletions(-)
> >>
> >> diff --git a/drivers/acpi/acpica/tbinstal.c b/drivers/acpi/acpica/tbinstal.c index
> >> e57cd38..b1e098d 100644
> >> --- a/drivers/acpi/acpica/tbinstal.c
> >> +++ b/drivers/acpi/acpica/tbinstal.c
> >> @@ -313,7 +313,7 @@ struct acpi_table_header
> >> *acpi_tb_table_override(struct acpi_table_header
> >>
> >> return (NULL); /* There was no override */
> >>
> >> - finish_override:
> >> +finish_override:
> >>
> >> ACPI_INFO((AE_INFO,
> >> "%4.4s %p %s table override, new table: %p",
> >> --
> >> 1.7.1
> >
> > --
> > To unsubscribe from this list: send the line "unsubscribe linux-acpi" in
> > the body of a message to [email protected]
> > More majordomo info at http://vger.kernel.org/majordomo-info.html
> >
--
I speak only for myself.
Rafael J. Wysocki, Intel Open Source Technology Center.

2013-03-08 15:09:23

by Zheng, Lv

[permalink] [raw]
Subject: RE: [RESEND PATCH 3/6] acpi: Remove the leading spaces of "finish_override" label in acpi_tb_table_override().

> > > https://github.com/acpica/acpica/tree/master/generate/linux
> > Hi Lv,
> >
> > Thanks for telling me this. :)
> >
> > One more thing, if I want to fix something in acpica, such as this
> > patch set, who and which mail list should I send patches to ?
>
> Please post them to [email protected] with CCs to me and Bob
> Moore.

Yes. More information can be found at https://acpica.org/.
You can also just blame me if you find issues caused by the ACPICA release process. :-)
I have the duty to make the ACPICA release process better.
Thanks for your contribution.

Best regards
-Lv
????{.n?+???????+%?????ݶ??w??{.n?+????{??G?????{ay?ʇڙ?,j??f???h?????????z_??(?階?ݢj"???m??????G????????????&???~???iO???z??v?^?m???? ????????I?

2013-03-10 10:18:14

by Herbert Xu

[permalink] [raw]
Subject: Re: [RESEND PATCH 6/6] doc: Fix a wrong comment in Documentation/hw_random.txt

On Thu, Mar 07, 2013 at 06:38:17PM +0800, Tang Chen wrote:
> Seeing from the comment, there should be three reasons for removing request_mem_region.
> Change the comment "two" to "three".
>
> Signed-off-by: Tang Chen <[email protected]>
> Acked-by: Rob Landley <[email protected]>

Patch applied.
--
Email: Herbert Xu <[email protected]>
Home Page: http://gondor.apana.org.au/~herbert/
PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt