Re: [Devel] [PATCH 15/18] acpi: use ARRAY_SIZE

From: Rafael J. Wysocki
Date: Tue Oct 03 2017 - 12:04:53 EST


On Tue, Oct 3, 2017 at 2:34 PM, Colin Ian King <colin.king@xxxxxxxxxxxxx> wrote:
> On 03/10/17 12:39, Rafael J. Wysocki wrote:
>> On Tuesday, October 3, 2017 3:16:22 AM CEST JÃrÃmy Lefaure wrote:
>>> On Mon, 02 Oct 2017 14:27:52 +0200
>>> "Rafael J. Wysocki" <rjw@xxxxxxxxxxxxx> wrote:
>>>
>>>> ACPICA is soewhat special code, though and I'm not taking or ACKing patches
>>>> for it directly as a rule.
>>>>
>>>> For one, I'm not sure if ACPICA can use ARRAY_SIZE at all.
>>> Why is it special code that can't use ARRAY_SIZE ? Is it because this
>>> macro is defined in linux/kernel.h ?
>
> However, ACPICA does have ACPI_ARRAY_LENGTH(x), see source/include/actypes.h

Fair enough, but that cleanup should go in via ACPICA upstream anyway.

Thanks,
Rafael