* Re: [PATCH] mm: convert totalram_pages, totalhigh_pages and managed_pages to atomic.
[not found] ` <1540229092-25207-1-git-send-email-arunks-sgV2jX0FEOL9JmXXK+q4OQ@public.gmane.org>
@ 2018-10-22 18:11 ` Michal Hocko
[not found] ` <20181022181122.GK18839-2MMpYkNvuYDjFM9bn6wA6Q@public.gmane.org>
2018-10-23 5:37 ` Huang, Ying
1 sibling, 1 reply; 4+ messages in thread
From: Michal Hocko @ 2018-10-22 18:11 UTC (permalink / raw)
To: Arun KS
Cc: Mike Snitzer, Benjamin Herrenschmidt, Kemi Wang,
dri-devel-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW, J. Bruce Fields,
linux-sctp-u79uwXL29TY76Z2rM5mHXA, Paul Mackerras, Pavel Machek,
Christoph Lameter, K. Y. Srinivasan, Sumit Semwal,
David (ChunMing) Zhou, Petr Tesarik, Michael Ellerman,
ceph-devel-u79uwXL29TY76Z2rM5mHXA, James E.J. Bottomley,
kasan-dev-/JYPxA39Uh5TLH3MbocFFw, Marcos Paulo de Souza,
Steven J. Hill, David Rientjes, Anthony Yznaga, Daniel Vacek,
Roman Gushchin, Len Brown <len.b
On Mon 22-10-18 22:53:22, Arun KS wrote:
> Remove managed_page_count_lock spinlock and instead use atomic
> variables.
I assume this has been auto-generated. If yes, it would be better to
mention the script so that people can review it and regenerate for
comparision. Such a large change is hard to review manually.
--
Michal Hocko
SUSE Labs
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH] mm: convert totalram_pages, totalhigh_pages and managed_pages to atomic.
[not found] ` <20181022181122.GK18839-2MMpYkNvuYDjFM9bn6wA6Q@public.gmane.org>
@ 2018-10-23 4:46 ` Arun Sudhilal
0 siblings, 0 replies; 4+ messages in thread
From: Arun Sudhilal @ 2018-10-23 4:46 UTC (permalink / raw)
To: mhocko-DgEjT+Ai2ygdnm+yROfE0A
Cc: snitzer-H+wXaHxf7aLQT0dZR+AlfA,
benh-XVmvHMARGAS8U2dJNN8I7kB+6BGkLq7r,
kemi.wang-ral2JQCrhuEAvxtiuMwx3w,
dri-devel-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW,
bfields-uC3wQj2KruNg9hUCZPvPmw, linux-sctp-u79uwXL29TY76Z2rM5mHXA,
paulus-eUNUBHrolfbYtjvyW6yDsg, pavel-+ZI9xUNit7I,
cl-vYTEC60ixJUAvxtiuMwx3w, kys-0li6OtcxBFHby3iVrkZq2A,
sumit.semwal-QSEj5FYQhm4dnm+yROfE0A, David1.Zhou-5C7GfCeVMHo,
ptesarik-IBi9RG/b67k, mpe-Gsx/Oe8HsFggBc27wqDAHg,
ceph-devel-u79uwXL29TY76Z2rM5mHXA, jejb-6jwH94ZQLHl74goWV3ctuw,
kasan-dev-/JYPxA39Uh5TLH3MbocFFw,
marcos.souza.org-Re5JQEeQqe8AvxtiuMwx3w,
steven.hill-YGCgFSpz5w/QT0dZR+AlfA,
rientjes-hpIqsD4AKlfQT0dZR+AlfA,
anthony.yznaga-QHcLZuEGTsvQT0dZR+AlfA,
neelx-H+wXaHxf7aLQT0dZR+AlfA, guro-b10kYP2dOMg,
len.brown-ral2JQCrhuEAvxtiuMwx3w, linux-pm-u79uwXL29TY76Z2rM5mHXA,
vbabka-AlSwsSmVLrQ, linux-um-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r,
rppt-23VcF4HTsmIX0ybBhKVfKdBPR1lH4CV8,
viro-RmSDqhL/yNMiFSDQTTA3OLVCufUGDwFn,
tglx-hfZtesqFncYOwBW4kG4KsQ,
trond.myklebust-F/q8l9xzQnoyLce1RVWEUA,
anton-yrGDUoBaLx3QT0dZR+AlfA, linux-parisc-u79uwXL29TY76Z2rM5mHXA,
malat-8fiUuRrzOP0dnm+yROfE0A,
gregkh-hQyY1W1yCW8ekmWlsbkhG0B+6BGkLq7r,
rdunlap-wEGCiKHe2LqWVfeAwA7xHQ, rjw-LthD3rsA81gm4RdzfppkhA,
linux-kernel-u79uwXL29TY76Z2rM5mHXA, cyrilbur
On Mon, Oct 22, 2018 at 11:41 PM Michal Hocko <mhocko-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org> wrote:
>
> On Mon 22-10-18 22:53:22, Arun KS wrote:
> > Remove managed_page_count_lock spinlock and instead use atomic
> > variables.
>
Hello Michal,
> I assume this has been auto-generated. If yes, it would be better to
> mention the script so that people can review it and regenerate for
> comparision. Such a large change is hard to review manually.
Changes were made partially with script. For totalram_pages and
totalhigh_pages,
find dir -type f -exec sed -i
's/totalram_pages/atomic_long_read(\&totalram_pages)/g' {} \;
find dir -type f -exec sed -i
's/totalhigh_pages/atomic_long_read(\&totalhigh_pages)/g' {} \;
For managed_pages it was mostly manual edits after using,
find mm/ -type f -exec sed -i
's/zone->managed_pages/atomic_long_read(\&zone->managed_pages)/g' {}
\;
Regards,
Arun
> --
> Michal Hocko
> SUSE Labs
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH] mm: convert totalram_pages, totalhigh_pages and managed_pages to atomic.
[not found] ` <c57bcc584b3700c483b0311881ec3ae8786f88b1.camel-6d6DIl74uiNBDgjK7y7TUQ@public.gmane.org>
@ 2018-10-23 4:48 ` Arun KS
0 siblings, 0 replies; 4+ messages in thread
From: Arun KS @ 2018-10-23 4:48 UTC (permalink / raw)
To: Joe Perches
Cc: Mike Snitzer, Benjamin Herrenschmidt, Kemi Wang,
dri-devel-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW, J. Bruce Fields,
linux-sctp-u79uwXL29TY76Z2rM5mHXA, Paul Mackerras, Pavel Machek,
Christoph Lameter, K. Y. Srinivasan, Sumit Semwal,
David (ChunMing) Zhou, Petr Tesarik, Michael Ellerman,
ceph-devel-u79uwXL29TY76Z2rM5mHXA, James E.J. Bottomley,
kasan-dev-/JYPxA39Uh5TLH3MbocFFw, Marcos Paulo de Souza,
Steven J. Hill, David Rientjes, Anthony Yznaga, Daniel Vacek,
Roman Gushchin, Len Brown <len.b
On 2018-10-23 09:45, Joe Perches wrote:
> On Mon, 2018-10-22 at 22:53 +0530, Arun KS wrote:
>> Remove managed_page_count_lock spinlock and instead use atomic
>> variables.
>
Hello Joe,
> Perhaps better to define and use macros for the accesses
> instead of specific uses of atomic_long_<inc/dec/read>
>
> Something like:
>
> #define totalram_pages() (unsigned
> long)atomic_long_read(&_totalram_pages)
> #define totalram_pages_inc() (unsigned
> long)atomic_long_inc(&_totalram_pages)
> #define totalram_pages_dec() (unsigned
> long)atomic_long_dec(&_totalram_pages)
That sounds like a nice idea.
Regards,
Arun
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH] mm: convert totalram_pages, totalhigh_pages and managed_pages to atomic.
[not found] ` <1540229092-25207-1-git-send-email-arunks-sgV2jX0FEOL9JmXXK+q4OQ@public.gmane.org>
2018-10-22 18:11 ` [PATCH] mm: convert totalram_pages, totalhigh_pages and managed_pages to atomic Michal Hocko
@ 2018-10-23 5:37 ` Huang, Ying
1 sibling, 0 replies; 4+ messages in thread
From: Huang, Ying @ 2018-10-23 5:37 UTC (permalink / raw)
To: Arun KS
Cc: Mike Snitzer, Benjamin Herrenschmidt, Kemi Wang,
dri-devel-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW, J. Bruce Fields,
linux-sctp-u79uwXL29TY76Z2rM5mHXA, Paul Mackerras, Pavel Machek,
Christoph Lameter, K. Y. Srinivasan, Sumit Semwal,
David (ChunMing) Zhou, Petr Tesarik, Michael Ellerman,
ceph-devel-u79uwXL29TY76Z2rM5mHXA, James E.J. Bottomley,
kasan-dev-/JYPxA39Uh5TLH3MbocFFw, Marcos Paulo de Souza,
Steven J. Hill, David Rientjes, Anthony Yznaga, Daniel Vacek,
Roman Gushchin, Len Brown <len.
Arun KS <arunks-sgV2jX0FEOL9JmXXK+q4OQ@public.gmane.org> writes:
> Remove managed_page_count_lock spinlock and instead use atomic
> variables.
>
> Suggested-by: Michal Hocko <mhocko-IBi9RG/b67k@public.gmane.org>
> Suggested-by: Vlastimil Babka <vbabka-AlSwsSmVLrQ@public.gmane.org>
> Signed-off-by: Arun KS <arunks-sgV2jX0FEOL9JmXXK+q4OQ@public.gmane.org>
>
> ---
> As discussed here,
> https://patchwork.kernel.org/patch/10627521/#22261253
My 2 cents. I think you should include at least part of the discussion
in the patch description to make it more readable by itself.
Best Regards,
Huang, Ying
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2018-10-23 5:37 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
[not found] <1540229092-25207-1-git-send-email-arunks@codeaurora.org>
[not found] ` <1540229092-25207-1-git-send-email-arunks-sgV2jX0FEOL9JmXXK+q4OQ@public.gmane.org>
2018-10-22 18:11 ` [PATCH] mm: convert totalram_pages, totalhigh_pages and managed_pages to atomic Michal Hocko
[not found] ` <20181022181122.GK18839-2MMpYkNvuYDjFM9bn6wA6Q@public.gmane.org>
2018-10-23 4:46 ` Arun Sudhilal
2018-10-23 5:37 ` Huang, Ying
[not found] ` <c57bcc584b3700c483b0311881ec3ae8786f88b1.camel@perches.com>
[not found] ` <c57bcc584b3700c483b0311881ec3ae8786f88b1.camel-6d6DIl74uiNBDgjK7y7TUQ@public.gmane.org>
2018-10-23 4:48 ` Arun KS
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox