lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-Id: <4db4ab2d-968f-4403-b85e-1465b3c1017e@app.fastmail.com>
Date:   Fri, 27 Jan 2023 11:22:57 +0100
From:   "Arnd Bergmann" <arnd@...db.de>
To:     "Stanislaw Gruszka" <stanislaw.gruszka@...ux.intel.com>,
        "Arnd Bergmann" <arnd@...nel.org>
Cc:     "Oded Gabbay" <ogabbay@...nel.org>,
        "Jeffrey Hugo" <quic_jhugo@...cinc.com>,
        "Jacek Lawrynowicz" <jacek.lawrynowicz@...ux.intel.com>,
        "Dave Airlie" <airlied@...hat.com>,
        "Thomas Zimmermann" <tzimmermann@...e.de>,
        "Melissa Wen" <mwen@...lia.com>,
        "Daniel Vetter" <daniel.vetter@...ll.ch>,
        dri-devel@...ts.freedesktop.org, linux-kernel@...r.kernel.org
Subject: Re: [PATCH] accel: work around DRM_ACCEL dependencies

On Fri, Jan 27, 2023, at 11:17, Stanislaw Gruszka wrote:
> On Fri, Jan 27, 2023 at 10:36:20AM +0100, Arnd Bergmann wrote:

>> I think it will be necessary to establish a link hierarchy between drm.ko
>> and drm_accel.ko to avoid circular dependencies like this, but until then
>> the only way that both can be used is to have both subsystems built into
>> the kernel. Enforce this using a Kconfig dependency.
>
> Hmm, it was discussed a bit before and conclusion was that accel will be
> compiled in drm.ko to avoid circular dependencies. There should be
> no drm_accel.ko module.

Ok, got it. This does not sounds like a great solution as it ties
the two modules closer together than most users want, but it should
work as long as we control the dependencies for the individual drivers.

>> diff --git a/drivers/accel/Kconfig b/drivers/accel/Kconfig
>> index 834863902e16..dd18d3b2028c 100644
>> --- a/drivers/accel/Kconfig
>> +++ b/drivers/accel/Kconfig
>> @@ -8,7 +8,7 @@
>>  #
>>  menuconfig DRM_ACCEL
>>  	bool "Compute Acceleration Framework"
>> -	depends on DRM
>> +	depends on DRM=y
>
> Would making ivpu Kconfig:
>
> depends on DRM
> select DRM_ACCEL
>
> solve the problem and still allow to drm to be build as module ? 

Right, that should work, I'll send a v2 patch to add an "if DRM"
around the entire drivers/accel/Kconfig file, which should have the
effect.

     Arnd

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ