{"push_id":2737309250,"size":3,"distinct_size":3,"ref":"refs/heads/lineage-15.1","head":"29108573eac825e945347e5141fcff8c9ef308eb","before":"9902103543ef87a2c6aad231ec9c01e2e1054bff","commits":[{"sha":"018203fb89a35782c865f62af9a307617cac74d0","author":{"name":"Peter Zijlstra","email":"3fddac958924aef220f202ca567388ddab3f14a8@infradead.org"},"message":"UPSTREAM: sched: Allow balance callbacks for check_class_changed()\n\nIn order to remove dropping rq->lock from the\nswitched_{to,from}()/prio_changed() sched_class methods, run the\nbalance callbacks after it.\n\nWe need to remove dropping rq->lock because its buggy,\nsuppose using sched_setattr()/sched_setscheduler() to change a running\ntask from FIFO to OTHER.\n\nBy the time we get to switched_from_rt() the task is already enqueued\non the cfs runqueues. If switched_from_rt() does pull_rt_task() and\ndrops rq->lock, load-balancing can come in and move our task @p to\nanother rq.\n\nThe subsequent switched_to_fair() still assumes @p is on @rq and bad\nthings will happen.\n\nBy using balance callbacks we delay the load-balancing operations\n{rt,dl}x{push,pull} until we've done all the important work and the\ntask is fully set up.\n\nFurthermore, the balance callbacks do not know about @p, therefore\nthey cannot get confused like this.\n\nReported-by: Mike Galbraith <umgwanakikbuti@gmail.com>\nSigned-off-by: Peter Zijlstra (Intel) <peterz@infradead.org>\nCc: ktkhai@parallels.com\nCc: rostedt@goodmis.org\nCc: juri.lelli@gmail.com\nCc: pang.xunlei@linaro.org\nCc: oleg@redhat.com\nCc: wanpeng.li@linux.intel.com\nLink: http://lkml.kernel.org/r/20150611124742.615343911@infradead.org\nSigned-off-by: Thomas Gleixner <tglx@linutronix.de>\n(cherry picked from commit 4c9a4bc89a9cca8128bce67d6bc8870d6b7ee0b2)\nBug: 35833695\nTest: Boot\n\nChange-Id: I5bddef497a278d8777382f29c7e9aaa063f335dd\nSigned-off-by: Francisco Franco <franciscofranco.1990@gmail.com>","distinct":true,"url":"https://api.github.com/repos/penglezos/android_kernel_xiaomi_msm8953/commits/018203fb89a35782c865f62af9a307617cac74d0"},{"sha":"5ca63d6282554665d75ffad84e58357f2fa80d9a","author":{"name":"NeilBrown","email":"1c00aa603bb92d594c03cff60ecf8e63b2a5bcb1@suse.de"},"message":"sched: Prevent recursion in io_schedule()\n\nio_schedule() calls blk_flush_plug() which, depending on the\ncontents of current->plug, can initiate arbitrary blk-io requests.\n\nNote that this contrasts with blk_schedule_flush_plug() which requires\nall non-trivial work to be handed off to a separate thread.\n\nThis makes it possible for io_schedule() to recurse, and initiating\nblock requests could possibly call mempool_alloc() which, in times of\nmemory pressure, uses io_schedule().\n\nApart from any stack usage issues, io_schedule() will not behave\ncorrectly when called recursively as delayacct_blkio_start() does\nnot allow for repeated calls.\n\nSo:\n - use ->in_iowait to detect recursion.  Set it earlier, and restore\n   it to the old value.\n - move the call to \"raw_rq\" after the call to blk_flush_plug().\n   As this is some sort of per-cpu thing, we want some chance that\n   we are on the right CPU\n - When io_schedule() is called recurively, use blk_schedule_flush_plug()\n   which cannot further recurse.\n - as this makes io_schedule() a lot more complex and as io_schedule()\n   must match io_schedule_timeout(), but all the changes in io_schedule_timeout()\n   and make io_schedule a simple wrapper for that.\n\nSigned-off-by: NeilBrown <neilb@suse.de>\nSigned-off-by: Peter Zijlstra (Intel) <peterz@infradead.org>\n[ Moved the now rudimentary io_schedule() into sched.h. ]\nCc: Jens Axboe <axboe@kernel.dk>\nCc: Linus Torvalds <torvalds@linux-foundation.org>\nCc: Tony Battersby <tonyb@cybernetics.com>\nLink: http://lkml.kernel.org/r/20150213162600.059fffb2@notabene.brown\nSigned-off-by: Ingo Molnar <mingo@kernel.org>\nSigned-off-by: Francisco Franco <franciscofranco.1990@gmail.com>","distinct":true,"url":"https://api.github.com/repos/penglezos/android_kernel_xiaomi_msm8953/commits/5ca63d6282554665d75ffad84e58357f2fa80d9a"},{"sha":"29108573eac825e945347e5141fcff8c9ef308eb","author":{"name":"Shaohua Li","email":"c0c0c8857ed6ec93282de3ee9d47e224acf995af@fb.com"},"message":"sched: always use blk_schedule_flush_plug in io_schedule_out\n\nblock plug callback could sleep, so we introduce a parameter\n'from_schedule' and corresponding drivers can use it to destinguish a\nschedule plug flush or a plug finish. Unfortunately io_schedule_out\nstill uses blk_flush_plug(). This causes below output (Note, I added a\nmight_sleep() in raid1_unplug to make it trigger faster, but the whole\nthing doesn't matter if I add might_sleep). In raid1/10, this can cause\ndeadlock.\n\nThis patch makes io_schedule_out always uses blk_schedule_flush_plug.\nThis should only impact drivers (as far as I know, raid 1/10) which are\nsensitive to the 'from_schedule' parameter.\n\n[  370.817949] ------------[ cut here ]------------\n[  370.817960] WARNING: CPU: 7 PID: 145 at ../kernel/sched/core.c:7306 __might_sleep+0x7f/0x90()\n[  370.817969] do not call blocking ops when !TASK_RUNNING; state=2 set at [<ffffffff81092fcf>] prepare_to_wait+0x2f/0x90\n[  370.817971] Modules linked in: raid1\n[  370.817976] CPU: 7 PID: 145 Comm: kworker/u16:9 Tainted: G        W       4.0.0+ #361\n[  370.817977] Hardware name: QEMU Standard PC (i440FX + PIIX, 1996), BIOS 1.7.5-20140709_153802- 04/01/2014\n[  370.817983] Workqueue: writeback bdi_writeback_workfn (flush-9:1)\n[  370.817985]  ffffffff81cd83be ffff8800ba8cb298 ffffffff819dd7af 0000000000000001\n[  370.817988]  ffff8800ba8cb2e8 ffff8800ba8cb2d8 ffffffff81051afc ffff8800ba8cb2c8\n[  370.817990]  ffffffffa00061a8 000000000000041e 0000000000000000 ffff8800ba8cba28\n[  370.817993] Call Trace:\n[  370.817999]  [<ffffffff819dd7af>] dump_stack+0x4f/0x7b\n[  370.818002]  [<ffffffff81051afc>] warn_slowpath_common+0x8c/0xd0\n[  370.818004]  [<ffffffff81051b86>] warn_slowpath_fmt+0x46/0x50\n[  370.818006]  [<ffffffff81092fcf>] ? prepare_to_wait+0x2f/0x90\n[  370.818008]  [<ffffffff81092fcf>] ? prepare_to_wait+0x2f/0x90\n[  370.818010]  [<ffffffff810776ef>] __might_sleep+0x7f/0x90\n[  370.818014]  [<ffffffffa0000c03>] raid1_unplug+0xd3/0x170 [raid1]\n[  370.818024]  [<ffffffff81421d9a>] blk_flush_plug_list+0x8a/0x1e0\n[  370.818028]  [<ffffffff819e3550>] ? bit_wait+0x50/0x50\n[  370.818031]  [<ffffffff819e21b0>] io_schedule_timeout+0x130/0x140\n[  370.818033]  [<ffffffff819e3586>] bit_wait_io+0x36/0x50\n[  370.818034]  [<ffffffff819e31b5>] __wait_on_bit+0x65/0x90\n[  370.818041]  [<ffffffff8125b67c>] ? ext4_read_block_bitmap_nowait+0xbc/0x630\n[  370.818043]  [<ffffffff819e3550>] ? bit_wait+0x50/0x50\n[  370.818045]  [<ffffffff819e3302>] out_of_line_wait_on_bit+0x72/0x80\n[  370.818047]  [<ffffffff810935e0>] ? autoremove_wake_function+0x40/0x40\n[  370.818050]  [<ffffffff811de744>] __wait_on_buffer+0x44/0x50\n[  370.818053]  [<ffffffff8125ae80>] ext4_wait_block_bitmap+0xe0/0xf0\n[  370.818058]  [<ffffffff812975d6>] ext4_mb_init_cache+0x206/0x790\n[  370.818062]  [<ffffffff8114bc6c>] ? lru_cache_add+0x1c/0x50\n[  370.818064]  [<ffffffff81297c7e>] ext4_mb_init_group+0x11e/0x200\n[  370.818066]  [<ffffffff81298231>] ext4_mb_load_buddy+0x341/0x360\n[  370.818068]  [<ffffffff8129a1a3>] ext4_mb_find_by_goal+0x93/0x2f0\n[  370.818070]  [<ffffffff81295b54>] ? ext4_mb_normalize_request+0x1e4/0x5b0\n[  370.818072]  [<ffffffff8129ab67>] ext4_mb_regular_allocator+0x67/0x460\n[  370.818074]  [<ffffffff81295b54>] ? ext4_mb_normalize_request+0x1e4/0x5b0\n[  370.818076]  [<ffffffff8129ca4b>] ext4_mb_new_blocks+0x4cb/0x620\n[  370.818079]  [<ffffffff81290956>] ext4_ext_map_blocks+0x4c6/0x14d0\n[  370.818081]  [<ffffffff812a4d4e>] ? ext4_es_lookup_extent+0x4e/0x290\n[  370.818085]  [<ffffffff8126399d>] ext4_map_blocks+0x14d/0x4f0\n[  370.818088]  [<ffffffff81266fbd>] ext4_writepages+0x76d/0xe50\n[  370.818094]  [<ffffffff81149691>] do_writepages+0x21/0x50\n[  370.818097]  [<ffffffff811d5c00>] __writeback_single_inode+0x60/0x490\n[  370.818099]  [<ffffffff811d630a>] writeback_sb_inodes+0x2da/0x590\n[  370.818103]  [<ffffffff811abf4b>] ? trylock_super+0x1b/0x50\n[  370.818105]  [<ffffffff811abf4b>] ? trylock_super+0x1b/0x50\n[  370.818107]  [<ffffffff811d665f>] __writeback_inodes_wb+0x9f/0xd0\n[  370.818109]  [<ffffffff811d69db>] wb_writeback+0x34b/0x3c0\n[  370.818111]  [<ffffffff811d70df>] bdi_writeback_workfn+0x23f/0x550\n[  370.818116]  [<ffffffff8106bbd8>] process_one_work+0x1c8/0x570\n[  370.818117]  [<ffffffff8106bb5b>] ? process_one_work+0x14b/0x570\n[  370.818119]  [<ffffffff8106c09b>] worker_thread+0x11b/0x470\n[  370.818121]  [<ffffffff8106bf80>] ? process_one_work+0x570/0x570\n[  370.818124]  [<ffffffff81071868>] kthread+0xf8/0x110\n[  370.818126]  [<ffffffff81071770>] ? kthread_create_on_node+0x210/0x210\n[  370.818129]  [<ffffffff819e9322>] ret_from_fork+0x42/0x70\n[  370.818131]  [<ffffffff81071770>] ? kthread_create_on_node+0x210/0x210\n[  370.818132] ---[ end trace 7b4deb71e68b6605 ]---\n\nV2: don't change ->in_iowait\n\nCc: NeilBrown <neilb@suse.de>\nSigned-off-by: Shaohua Li <shli@fb.com>\nReviewed-by: Jeff Moyer <jmoyer@redhat.com>\nSigned-off-by: Jens Axboe <axboe@fb.com>\nSigned-off-by: Francisco Franco <franciscofranco.1990@gmail.com>","distinct":true,"url":"https://api.github.com/repos/penglezos/android_kernel_xiaomi_msm8953/commits/29108573eac825e945347e5141fcff8c9ef308eb"}]}
{"actor":{"display_login":"penglezos"}}