Re: [PATCH i-g-t v3 30/31] lib/igt_core: move igt_load_igtrc to igt_device_scan

Sebastian Brzezinka <[email protected]>
Newsgroups org.freedesktop.lists.igt-dev
Message-ID <[email protected]>
Hi Kamil,

On Thu Jul 16, 2026 at 4:08 PM CEST, Kamil Konieczny wrote:
> Hi Sebastian,
> On 2026-07-15 at 14:15:40 +0200, Sebastian Brzezinka wrote:
>> igt_load_igtrc() is used exclusively by igt_device_scan internals to read
>> per-device configuration from the igtrc file.  Moving it from igt_core.c
>> to igt_device_scan.c co-locates the function with its primary user and
>> makes it possible for lsgpu to link against lib_igt_device_scan without
>> needing the rest of libigt.
>> 
>> Update the declaration accordingly: remove from igt_core.h and add to
>> igt_device_scan.h where the implementation now lives.
>> 
>> Signed-off-by: Sebastian Brzezinka <[email protected]>
>> Acked-by: Ashutosh Dixit <[email protected]>
>> ---
>>  lib/igt_core.c        | 47 ------------------------------------------
>>  lib/igt_core.h        |  2 --
>>  lib/igt_device_scan.c | 48 +++++++++++++++++++++++++++++++++++++++++++
>>  lib/igt_device_scan.h |  2 ++
>>  runner/executor.c     |  1 +
>
> If this is used by igt_runner, maybe more proper solution
> would be to move it to separate lib/igt_igtrc.[c|h]?
Somehow, I don't like the idea of a file that holds a single function.

-- 
Best regards,
Sebastian
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.