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]
Date:   Fri, 9 Sep 2022 17:23:07 +0800
From:   Jianmin Lv <lvjianmin@...ngson.cn>
To:     Lorenzo Pieralisi <lpieralisi@...nel.org>
Cc:     Robin Murphy <robin.murphy@....com>, chenhuacai@...ngson.cn,
        guohanjun@...wei.com, sudeep.holla@....com, rafael@...nel.org,
        lenb@...nel.org, robert.moore@...el.com,
        linux-kernel@...r.kernel.org, linux-acpi@...r.kernel.org,
        loongarch@...ts.linux.dev
Subject: Re: [PATCH V3 1/2] ACPI / scan: Support multiple dma windows with
 different offsets



On 2022/9/9 下午4:04, Lorenzo Pieralisi wrote:
> On Tue, Sep 06, 2022 at 08:40:48PM +0800, Jianmin Lv wrote:
>>
>>
>> On 2022/9/5 下午8:20, Robin Murphy wrote:
>>> On 2022-08-30 04:01, Jianmin Lv wrote:
>>>> For DT, of_dma_get_range returns bus_dma_region typed dma regions,
>>>> which makes multiple dma windows with different offset available
>>>> for translation between dma address and cpu address.
>>>>
>>>> But for ACPI, acpi_dma_get_range doesn't return similar dma regions,
>>>> causing no path for setting dev->dma_range_map conveniently. So the
>>>> patch changes acpi_dma_get_range and returns bus_dma_region typed
>>>> dma regions according to of_dma_get_range.
>>>>
>>>> After changing acpi_dma_get_range, acpi_arch_dma_setup is changed for
>>>> ARM64, where original dma_addr and size are removed as these
>>>> arguments are now redundant, and pass 0 and U64_MAX for dma_base
>>>> and size of arch_setup_dma_ops, so this is a simplification consistent
>>>> with what other ACPI architectures also pass to iommu_setup_dma_ops().
>>>
>>> Other than a micro-nit that acpi_dma_get_range() could probably use
>>> resource_size(),
>>>
>>
>> Ok, thanks, I'll use resource_size() in acpi_dma_get_range().
> 
> Are you reposting this shortly ? We are almost at -rc5, it would
> be good if we can proceed promptly.
> 
> Thanks,
> Lorenzo
> 
Ok, I'll send V4 today.

Thanks,
Jianmin

>>> Reviewed-by: Robin Murphy <robin.murphy@....com>
>>>
>>> It took me longer than I care to admit to figure out where the implicit
>>> declaration of struct bus_dma_region in the scope of acpi.h and
>>> acpi_bus.h comes from, but in the end I guess it's sufficiently
>>> well-defined by the C spec to be reliable.
>>>
>>> Thanks for getting this done!
>>>
>>
>> It's a pleasure!
>>
>>
>>> Robin.
>>>
>>
>> [...]
>>
>>

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ