Re: [PATCH] drm/amdgpu: use ARRAY_SIZE() to add amdgpu debugfs files

2020-07-13 Thread Christian König
, Christian. If so, we need a separate patch to cleanup them in a batch. BR, Xiaojie From: Christian König Sent: Monday, July 13, 2020 4:38 PM To: Yuan, Xiaojie; amd-gfx@lists.freedesktop.org Subject: Re: [PATCH] drm/amdgpu: use ARRAY_SIZE() to add amdgpu debug

Re: [PATCH] drm/amdgpu: use ARRAY_SIZE() to add amdgpu debugfs files

2020-07-13 Thread Yuan, Xiaojie
automatically If so, we need a separate patch to cleanup them in a batch. BR, Xiaojie From: Christian König Sent: Monday, July 13, 2020 4:38 PM To: Yuan, Xiaojie; amd-gfx@lists.freedesktop.org Subject: Re: [PATCH] drm/amdgpu: use ARRAY_SIZE() to add amdgpu

Re: [PATCH] drm/amdgpu: use ARRAY_SIZE() to add amdgpu debugfs files

2020-07-13 Thread Christian König
Am 13.07.20 um 07:59 schrieb Xiaojie Yuan: to easily add new debugfs file w/o changing the hardcoded list count. In general a good idea, but I would rather like to see amdgpu_debugfs_add_files() completely removed and debugfs_create_file() used directly instead. Christian.

RE: [PATCH] drm/amdgpu: use ARRAY_SIZE() to add amdgpu debugfs files

2020-07-13 Thread Zhang, Hawking
[AMD Public Use] Reviewed-by: Hawking Zhang Regards, Hawking -Original Message- From: amd-gfx On Behalf Of Xiaojie Yuan Sent: Monday, July 13, 2020 14:00 To: amd-gfx@lists.freedesktop.org Cc: Yuan, Xiaojie Subject: [PATCH] drm/amdgpu: use ARRAY_SIZE() to add amdgpu debugfs files to

Re: [PATCH] drm/amdgpu: use ARRAY_SIZE

2017-10-16 Thread Alex Deucher
On Mon, Oct 16, 2017 at 3:48 AM, Christian König wrote: > Am 16.10.2017 um 04:29 schrieb Jérémy Lefaure: >> >> Using the ARRAY_SIZE macro improves the readability of the code. >> >> Found with Coccinelle with the following semantic patch: >> @r depends on (org ||

Re: [PATCH] drm/amdgpu: use ARRAY_SIZE

2017-10-16 Thread Christian König
Am 16.10.2017 um 04:29 schrieb Jérémy Lefaure: Using the ARRAY_SIZE macro improves the readability of the code. Found with Coccinelle with the following semantic patch: @r depends on (org || report)@ type T; T[] E; position p; @@ ( (sizeof(E)@p /sizeof(*E)) | (sizeof(E)@p /sizeof(E[...])) |