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: <ee484db3-48e5-434f-8f41-21535c1bf069@linux.dev>
Date: Sat, 31 Aug 2024 03:48:49 +0800
From: Sui Jingfeng <sui.jingfeng@...ux.dev>
To: "Wang, Xiaolei" <Xiaolei.Wang@...driver.com>,
 "l.stach@...gutronix.de" <l.stach@...gutronix.de>,
 "linux+etnaviv@...linux.org.uk" <linux+etnaviv@...linux.org.uk>,
 "christian.gmeiner@...il.com" <christian.gmeiner@...il.com>,
 "airlied@...il.com" <airlied@...il.com>, "daniel@...ll.ch" <daniel@...ll.ch>
Cc: "etnaviv@...ts.freedesktop.org" <etnaviv@...ts.freedesktop.org>,
 "dri-devel@...ts.freedesktop.org" <dri-devel@...ts.freedesktop.org>,
 "linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>
Subject: Re: [v2] drm/etnaviv: Clear the __GFP_HIGHMEM bit in GFP_HIGHUSER
 with 32 address

On 2024/8/31 03:40, Sui Jingfeng wrote:
> Hi, Xiaolei
>
>
> On 2024/8/16 09:55, Wang, Xiaolei wrote:
>> Ping ...
>
> I think, the more proper fix that Lucas hint
> is to modify the 'priv->shm_gfp_mask' variable
> in the|etnaviv_bind() function|. Say:
> |Use "priv->shm_gfp_mask = GFP_USER | __GFP_RETRY_MAYFAIL | 
> __GFP_NOWARN;"|
>
> instead of
>
> |"priv->shm_gfp_mask = ||GFP_HIGHUSER||| __GFP_RETRY_MAYFAIL | 
> __GFP_NOWARN;|"
>
>

Oops, please ignore the irrelevant(superfluous) "|" characters in my
reply, my Thunderbird mail client has some problem, generate them unreasonably.

Should be:

priv->shm_gfp_mask = GFP_USER | __GFP_RETRY_MAYFAIL | __GFP_NOWARN;



> Right?
>
>> thanks
>> xiaolei
>>
>> diff --git a/drivers/gpu/drm/etnaviv/etnaviv_gpu.c 
>> b/drivers/gpu/drm/etnaviv/etnaviv_gpu.c
>> index 7c7f97793ddd..0e6bdf2d028b 100644
>> --- a/drivers/gpu/drm/etnaviv/etnaviv_gpu.c
>> +++ b/drivers/gpu/drm/etnaviv/etnaviv_gpu.c
>> @@ -844,8 +844,10 @@ int etnaviv_gpu_init(struct etnaviv_gpu *gpu)
>>            * request pages for our SHM backend buffers from the DMA32 
>> zone to
>>            * hopefully avoid performance killing SWIOTLB bounce 
>> buffering.
>>            */
>> -       if (dma_addressing_limited(gpu->dev))
>> +       if (dma_addressing_limited(gpu->dev)) {
>>                   priv->shm_gfp_mask |= GFP_DMA32;
>> +               priv->shm_gfp_mask &= ~__GFP_HIGHMEM;
>> +       }
>>
>>           /* Create buffer: */
>>           ret = etnaviv_cmdbuf_init(priv->cmdbuf_suballoc, &gpu->buffer,
>
-- 
Best regards,
Sui


Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ