quota: fix livelock in dquot_writeback_dquots
authorDmitry Monakhov <dmtrmonakhov@yandex-team.ru>
Thu, 31 Oct 2019 10:39:19 +0000 (10:39 +0000)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sat, 21 Dec 2019 09:42:09 +0000 (10:42 +0100)
commitbae46100ca5444b4e508025282b4a7bd52e6faea
treec96d551a6f4881d0d7260fa92b770e9290c641b2
parentb52729015c205a101d38b75206c6f7010fb3c33e
quota: fix livelock in dquot_writeback_dquots

commit 6ff33d99fc5c96797103b48b7b0902c296f09c05 upstream.

Write only quotas which are dirty at entry.

XFSTEST: https://github.com/dmonakhov/xfstests/commit/b10ad23566a5bf75832a6f500e1236084083cddc

Link: https://lore.kernel.org/r/20191031103920.3919-1-dmonakhov@openvz.org
CC: stable@vger.kernel.org
Signed-off-by: Konstantin Khlebnikov <khlebnikov@yandex-team.ru>
Signed-off-by: Dmitry Monakhov <dmtrmonakhov@yandex-team.ru>
Signed-off-by: Jan Kara <jack@suse.cz>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
fs/quota/dquot.c