[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH v2 3/6] mm: replace vma->vm_flags direct modifications with modifier calls
- To: Michal Hocko <mhocko@xxxxxxxx>
- From: Suren Baghdasaryan <surenb@xxxxxxxxxx>
- Date: Wed, 25 Jan 2023 08:55:12 -0800
- Cc: akpm@xxxxxxxxxxxxxxxxxxxx, michel@xxxxxxxxxxxxxx, jglisse@xxxxxxxxxx, vbabka@xxxxxxx, hannes@xxxxxxxxxxx, mgorman@xxxxxxxxxxxxxxxxxxx, dave@xxxxxxxxxxxx, willy@xxxxxxxxxxxxx, liam.howlett@xxxxxxxxxx, peterz@xxxxxxxxxxxxx, ldufour@xxxxxxxxxxxxx, paulmck@xxxxxxxxxx, luto@xxxxxxxxxx, songliubraving@xxxxxx, peterx@xxxxxxxxxx, david@xxxxxxxxxx, dhowells@xxxxxxxxxx, hughd@xxxxxxxxxx, bigeasy@xxxxxxxxxxxxx, kent.overstreet@xxxxxxxxx, punit.agrawal@xxxxxxxxxxxxx, lstoakes@xxxxxxxxx, peterjung1337@xxxxxxxxx, rientjes@xxxxxxxxxx, axelrasmussen@xxxxxxxxxx, joelaf@xxxxxxxxxx, minchan@xxxxxxxxxx, jannh@xxxxxxxxxx, shakeelb@xxxxxxxxxx, tatashin@xxxxxxxxxx, edumazet@xxxxxxxxxx, gthelen@xxxxxxxxxx, gurua@xxxxxxxxxx, arjunroy@xxxxxxxxxx, soheil@xxxxxxxxxx, hughlynch@xxxxxxxxxx, leewalsh@xxxxxxxxxx, posk@xxxxxxxxxx, will@xxxxxxxxxx, aneesh.kumar@xxxxxxxxxxxxx, npiggin@xxxxxxxxx, chenhuacai@xxxxxxxxxx, tglx@xxxxxxxxxxxxx, mingo@xxxxxxxxxx, bp@xxxxxxxxx, dave.hansen@xxxxxxxxxxxxxxx, richard@xxxxxx, anton.ivanov@xxxxxxxxxxxxxxxxxx, johannes@xxxxxxxxxxxxxxxx, qianweili@xxxxxxxxxx, wangzhou1@xxxxxxxxxxxxx, herbert@xxxxxxxxxxxxxxxxxxx, davem@xxxxxxxxxxxxx, vkoul@xxxxxxxxxx, airlied@xxxxxxxxx, daniel@xxxxxxxx, maarten.lankhorst@xxxxxxxxxxxxxxx, mripard@xxxxxxxxxx, tzimmermann@xxxxxxx, l.stach@xxxxxxxxxxxxxx, krzysztof.kozlowski@xxxxxxxxxx, patrik.r.jakobsson@xxxxxxxxx, matthias.bgg@xxxxxxxxx, robdclark@xxxxxxxxx, quic_abhinavk@xxxxxxxxxxx, dmitry.baryshkov@xxxxxxxxxx, tomba@xxxxxxxxxx, hjc@xxxxxxxxxxxxxx, heiko@xxxxxxxxx, ray.huang@xxxxxxx, kraxel@xxxxxxxxxx, sre@xxxxxxxxxx, mcoquelin.stm32@xxxxxxxxx, alexandre.torgue@xxxxxxxxxxx, tfiga@xxxxxxxxxxxx, m.szyprowski@xxxxxxxxxxx, mchehab@xxxxxxxxxx, dimitri.sivanich@xxxxxxx, zhangfei.gao@xxxxxxxxxx, jejb@xxxxxxxxxxxxx, martin.petersen@xxxxxxxxxx, dgilbert@xxxxxxxxxxxx, hdegoede@xxxxxxxxxx, mst@xxxxxxxxxx, jasowang@xxxxxxxxxx, alex.williamson@xxxxxxxxxx, deller@xxxxxx, jayalk@xxxxxxxxxxxx, viro@xxxxxxxxxxxxxxxxxx, nico@xxxxxxxxxxx, xiang@xxxxxxxxxx, chao@xxxxxxxxxx, tytso@xxxxxxx, adilger.kernel@xxxxxxxxx, miklos@xxxxxxxxxx, mike.kravetz@xxxxxxxxxx, muchun.song@xxxxxxxxx, bhe@xxxxxxxxxx, andrii@xxxxxxxxxx, yoshfuji@xxxxxxxxxxxxxx, dsahern@xxxxxxxxxx, kuba@xxxxxxxxxx, pabeni@xxxxxxxxxx, perex@xxxxxxxx, tiwai@xxxxxxxx, haojian.zhuang@xxxxxxxxx, robert.jarzmik@xxxxxxx, linux-mm@xxxxxxxxx, linux-arm-kernel@xxxxxxxxxxxxxxxxxxx, linuxppc-dev@xxxxxxxxxxxxxxxx, x86@xxxxxxxxxx, linux-kernel@xxxxxxxxxxxxxxx, linux-graphics-maintainer@xxxxxxxxxx, linux-ia64@xxxxxxxxxxxxxxx, linux-arch@xxxxxxxxxxxxxxx, loongarch@xxxxxxxxxxxxxxx, kvm@xxxxxxxxxxxxxxx, linux-s390@xxxxxxxxxxxxxxx, linux-sgx@xxxxxxxxxxxxxxx, linux-um@xxxxxxxxxxxxxxxxxxx, linux-acpi@xxxxxxxxxxxxxxx, linux-crypto@xxxxxxxxxxxxxxx, nvdimm@xxxxxxxxxxxxxxx, dmaengine@xxxxxxxxxxxxxxx, amd-gfx@xxxxxxxxxxxxxxxxxxxxx, dri-devel@xxxxxxxxxxxxxxxxxxxxx, etnaviv@xxxxxxxxxxxxxxxxxxxxx, linux-samsung-soc@xxxxxxxxxxxxxxx, intel-gfx@xxxxxxxxxxxxxxxxxxxxx, linux-mediatek@xxxxxxxxxxxxxxxxxxx, linux-arm-msm@xxxxxxxxxxxxxxx, freedreno@xxxxxxxxxxxxxxxxxxxxx, linux-rockchip@xxxxxxxxxxxxxxxxxxx, linux-tegra@xxxxxxxxxxxxxxx, virtualization@xxxxxxxxxxxxxxxxxxxxxxxxxx, xen-devel@xxxxxxxxxxxxxxxxxxxx, linux-stm32@xxxxxxxxxxxxxxxxxxxxxxxxxxxx, linux-rdma@xxxxxxxxxxxxxxx, linux-media@xxxxxxxxxxxxxxx, linux-accelerators@xxxxxxxxxxxxxxxx, sparclinux@xxxxxxxxxxxxxxx, linux-scsi@xxxxxxxxxxxxxxx, linux-staging@xxxxxxxxxxxxxxx, target-devel@xxxxxxxxxxxxxxx, linux-usb@xxxxxxxxxxxxxxx, netdev@xxxxxxxxxxxxxxx, linux-fbdev@xxxxxxxxxxxxxxx, linux-aio@xxxxxxxxx, linux-fsdevel@xxxxxxxxxxxxxxx, linux-erofs@xxxxxxxxxxxxxxxx, linux-ext4@xxxxxxxxxxxxxxx, devel@xxxxxxxxxxxxxxxxxx, kexec@xxxxxxxxxxxxxxxxxxx, linux-xfs@xxxxxxxxxxxxxxx, bpf@xxxxxxxxxxxxxxx, linux-perf-users@xxxxxxxxxxxxxxx, kasan-dev@xxxxxxxxxxxxxxxx, selinux@xxxxxxxxxxxxxxx, alsa-devel@xxxxxxxxxxxxxxxx, kernel-team@xxxxxxxxxxx
- Delivery-date: Thu, 26 Jan 2023 05:08:40 +0000
- List-id: Xen developer discussion <xen-devel.lists.xenproject.org>
On Wed, Jan 25, 2023 at 1:30 AM 'Michal Hocko' via kernel-team
<kernel-team@xxxxxxxxxxx> wrote:
>
> On Wed 25-01-23 00:38:48, Suren Baghdasaryan wrote:
> > Replace direct modifications to vma->vm_flags with calls to modifier
> > functions to be able to track flag changes and to keep vma locking
> > correctness.
>
> Is this a manual (git grep) based work or have you used Coccinele for
> the patch generation?
It was a manual "search and replace" and in the process I temporarily
renamed vm_flags to ensure I did not miss any usage.
>
> My potentially incomplete check
> $ git grep ">[[:space:]]*vm_flags[[:space:]]*[&|^]="
>
> shows that nothing should be left after this. There is still quite a lot
> of direct checks of the flags (more than 600). Maybe it would be good to
> make flags accessible only via accessors which would also prevent any
> future direct setting of those flags in uncontrolled way as well.
Yes, I think Peter's suggestion in the first patch would also require
that. Much more churn but probably worth it for the future
maintenance. I'll add a patch which converts all readers as well.
>
> Anyway
> Acked-by: Michal Hocko <mhocko@xxxxxxxx>
Thanks for all the reviews!
> --
> Michal Hocko
> SUSE Labs
>
> --
> To unsubscribe from this group and stop receiving emails from it, send an
> email to kernel-team+unsubscribe@xxxxxxxxxxx.
>
|