Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1616096

Re: [RFC PATCH] binder: Don't require the binder lock when killed in binder_thread_read()

From Doug Anderson <dianders@chromium.org>
Newsgroups linux.kernel
Subject Re: [RFC PATCH] binder: Don't require the binder lock when killed in binder_thread_read()
Date 2017-04-04 17:20 +0200
Message-ID <tsyps-6A1-17@gated-at.bofh.it> (permalink)
References <tseAq-1Uo-15@gated-at.bofh.it> <tsrnY-1QN-15@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


Hi,

On Tue, Apr 4, 2017 at 12:40 AM, Michal Hocko <mhocko@kernel.org> wrote:
> On Mon 03-04-17 11:09:32, Doug Anderson wrote:
> [...]
>> Maybe +Michal Hocko would have some opinions of which OOM Reaper
>> patches would be good for picking into linux stable?
>
> I am lacking context here but please note that the OOM reaper patches
> alone are not sufficient to make the OOM handling lockup free. There
> were quite some changes in the core OOM killer handling to make this
> possible. This has been work throughout the last year and it will be
> really non-trivial to backport to stable trees.

Yeah, that was the impression I got.


> So the primary question is what are you trying to achieve?

Ideally it would be nice to bring back patches to make the OOM
handling lockup free.  However, presuming that's not feasible then at
least it would be nice if we could get some minimal set of patches
that:

- Isn't too scary to backport.
- Handles the low hanging fruit.
- Is fairly self contained.

For Chrome OS we've got devices on a number of different kernels
ranging from 3.8 - 4.4.  Due to changes in userspace, it appears much
more likely that we wedge the OOM killer these days, so my main goal
is to avoid this in most cases.

Right now for Chrome OS I have patches that look like this:

* https://chromium-review.googlesource.com/465186
  UPSTREAM: mm: oom_kill: don't ignore oom score on exiting tasks

* https://chromium-review.googlesource.com/465187
  CHROMIUM: DROP: mm/oom_kill: Don't kill a subthread in our place if
we still ...

* https://chromium-review.googlesource.com/465188
  CHROMIUM: DROP: mm/oom_kill: Double-check before killing a child in our place

* https://chromium-review.googlesource.com/465189
  CHROMIUM: DROP: mm/oom_kill: Avoid deadlock; allow multiple victims

...and those seem to fit the bill for us, but:

1. It would be nice if other users of linuxstable could benefit.

2. I know the above patches are not as ideal as the work that has
happened upstream, so of course I'd prefer to get the upstream
solution.

3. I always appreciate being closer to the upstream solution which
means we get more people looking at the code and more people testing
the code.


-Doug

Back to linux.kernel | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

[RFC PATCH] binder: Don't require the binder lock when killed in binder_thread_read() Douglas Anderson <dianders@chromium.org> - 2017-03-31 20:00 +0200
  Re: [RFC PATCH] binder: Don't require the binder lock when killed in  binder_thread_read() Greg KH <gregkh@linuxfoundation.org> - 2017-03-31 21:40 +0200
    Re: [RFC PATCH] binder: Don't require the binder lock when killed in binder_thread_read() Doug Anderson <dianders@chromium.org> - 2017-03-31 23:10 +0200
      Re: [RFC PATCH] binder: Don't require the binder lock when killed in  binder_thread_read() Greg KH <gregkh@linuxfoundation.org> - 2017-04-01 08:50 +0200
        Re: [RFC PATCH] binder: Don't require the binder lock when killed in binder_thread_read() Doug Anderson <dianders@chromium.org> - 2017-04-02 04:40 +0200
          Re: [RFC PATCH] binder: Don't require the binder lock when killed in  binder_thread_read() Greg KH <gregkh@linuxfoundation.org> - 2017-04-03 15:30 +0200
            Re: [RFC PATCH] binder: Don't require the binder lock when killed in binder_thread_read() Doug Anderson <dianders@chromium.org> - 2017-04-03 20:10 +0200
              Re: [RFC PATCH] binder: Don't require the binder lock when killed in  binder_thread_read() Michal Hocko <mhocko@kernel.org> - 2017-04-04 09:50 +0200
                Re: [RFC PATCH] binder: Don't require the binder lock when killed in binder_thread_read() Doug Anderson <dianders@chromium.org> - 2017-04-04 17:20 +0200
                Re: [RFC PATCH] binder: Don't require the binder lock when killed in  binder_thread_read() Michal Hocko <mhocko@kernel.org> - 2017-04-04 17:30 +0200
  Re: [RFC PATCH] binder: Don't require the binder lock when killed in  binder_thread_read() peter enderborg <peter.enderborg@sonymobile.com> - 2017-04-03 15:50 +0200

csiph-web