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] [thread-next>] [day] [month] [year] [list]
Date:   Fri, 8 Oct 2021 21:21:46 +0200
From:   Jerome Forissier <jerome@...issier.org>
To:     Sudeep Holla <sudeep.holla@....com>,
        Jens Wiklander <jens.wiklander@...aro.org>
Cc:     linux-kernel@...r.kernel.org, linux-arm-kernel@...ts.infradead.org,
        op-tee@...ts.trustedfirmware.org,
        Sumit Garg <sumit.garg@...aro.org>,
        Marc Bonnici <marc.bonnici@....com>, sughosh.ganu@...aro.org
Subject: Re: [PATCH v6 5/5] optee: add FF-A support

Hi Sudeep,

On 10/8/21 6:32 PM, Sudeep Holla wrote:
> On Fri, Oct 08, 2021 at 02:27:32PM +0100, Sudeep Holla wrote:
>> On Wed, Oct 06, 2021 at 09:09:02AM +0200, Jens Wiklander wrote:
>>> Adds support for using FF-A [1] as transport to the OP-TEE driver.
>>>
>>> Introduces struct optee_msg_param_fmem which carries all information
>>> needed when OP-TEE is calling FFA_MEM_RETRIEVE_REQ to get the shared
>>> memory reference mapped by the hypervisor in S-EL2. Register usage is
>>> also updated to include the information needed.
>>>
>>> The FF-A part of this driver is enabled if CONFIG_ARM_FFA_TRANSPORT is
>>> enabled.
>>>
>>
>> I am not sure if I missed this with earlier version but I see the below
>> warning the second time I insert the optee module. I am sure I tested it
>> with previous version when I was fixing issues with FF-A as a module.
>>
>> Not sure if I am missing something in my steps.
>>
> 
> OK, more info, indeed I didn't observe this issue 2 weeks back with optee
> at commit 57e642f12085 ("core: enable system PTA upon user TA support").
> The UUID(d96a5b40-c3e5-21e3-8794-1002a5d5c61b) wasn't enumerated with above
> commit. Today I am testing the latest commit 2de2880065f3 ("core: update
> reference link to PrimeCell Cache Controller").
> 
> Though it looks like an issue with the driver, the latest optee changes
> triggered the driver to hit this issue in my setup. Hope this helps.

Totally makes sense. The optee_os commit triggering this is almost
certainly 811c42d40cd0 ("plat-vexpress: enable CFG_ENABLE_EMBEDDED_TESTS
by default"). With this commit, the "invoke tests" PTA gets included by
default in the TEE binary. This PTA has the TA_FLAG_DEVICE_ENUM flag so
it is enumerated by the Linux driver. AFAICT the vexpress platform has
no other PTA with that flag, so as you said the OP-TEE commit is simply
 exposing a bug in the Linux driver.

> IIUC we are not undoing optee_register_device executed via
> optee_enumerate_devices in the exit path.

That doesn't sound good indeed ;)

-- 
Jerome

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ