Message ID | 20221130132156.2836184-10-linan122@huawei.com |
---|---|
State | New |
Headers |
Return-Path: <linux-kernel-owner@vger.kernel.org> Delivered-To: ouuuleilei@gmail.com Received: by 2002:adf:f944:0:0:0:0:0 with SMTP id q4csp920410wrr; Wed, 30 Nov 2022 05:21:36 -0800 (PST) X-Google-Smtp-Source: AA0mqf5//I6HsmpLWbPYhjBOLKMx9lYcIlS3dBGGrR+gs3Y1QMLO3+UrzvuAT+aXrnxsFFhzNZ0L X-Received: by 2002:a17:902:e313:b0:189:97e9:c8e with SMTP id q19-20020a170902e31300b0018997e90c8emr9988404plc.63.1669814496580; Wed, 30 Nov 2022 05:21:36 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1669814496; cv=none; d=google.com; s=arc-20160816; b=wDO3D0RJbaC0i5jPVHcadzopO9K5mPOXZBgRnB6Rdk1BycmKTTQP6ZP87aUOJgY+5Y Bd0Ct7aLzGGsClc0EEHuJ1jvunqYj2mPwN6fpAmSPmdbxLh6h37XEUZMasXU7XGzHKRQ dMSxjArn12fxufSgAqXI/xZTxkcS9Qa02cm7UFVoyFBTZwJaZHnI30FpvGp4rgqTyrDl YFJNhwLMSxfXQE1bvGaZoDRZ9k1tp8UBM7yqk8jYFs3m9J9XNTUi3DRwuNsqBnr20JU4 c5Wu6nhxOmifAF0e2uUBNkcdkTHZ77q/YNgKhU9O5cSnhkvvVZcxQwOEHG52in+3gxE2 U17A== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from; bh=qYYu8MaQosUsSgpRafqL3nDsZVgA3iEEguStEtj1YfU=; b=aaehX5f0266shfoKNuC3Lq9+lE6jbguCKZgg/WN75yng8TCwryBEXsBVQcxfGk+0HC 2JMon9ucji54CUbze09PDQMCFefwk25+fGZj04o0AlPw+OUeQ56B+buF6fk4q8Hl8MJm ctvcztIhJDXjtfC5L34X8ctD9yroRWH22Z4TauEka2FlFZ4hr5b63JlA4UTUfbWeebi2 U6JPxOrehMBsTpFWJDR20fzWkRLqYCn2JdE+jdosYJizeFMqZo612oroOEGUXWK/DlJU QcLgaQGIRodc4z9eRtuZCli2hLMkT5ZANr7fkybj9dCSGNCujSPRp/cGGYLeL9TKJmfr C7Cw== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=huawei.com Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id u13-20020a63140d000000b00476e9888164si1252403pgl.88.2022.11.30.05.21.23; Wed, 30 Nov 2022 05:21:36 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=huawei.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S235801AbiK3NBp (ORCPT <rfc822;heyuhang3455@gmail.com> + 99 others); Wed, 30 Nov 2022 08:01:45 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:41470 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234936AbiK3NA6 (ORCPT <rfc822;linux-kernel@vger.kernel.org>); Wed, 30 Nov 2022 08:00:58 -0500 Received: from szxga02-in.huawei.com (szxga02-in.huawei.com [45.249.212.188]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 40B154EC2A; Wed, 30 Nov 2022 05:00:58 -0800 (PST) Received: from dggpeml500024.china.huawei.com (unknown [172.30.72.55]) by szxga02-in.huawei.com (SkyGuard) with ESMTP id 4NMfSZ67kyzRpfP; Wed, 30 Nov 2022 21:00:14 +0800 (CST) Received: from dggpeml500003.china.huawei.com (7.185.36.200) by dggpeml500024.china.huawei.com (7.185.36.10) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2375.31; Wed, 30 Nov 2022 21:00:55 +0800 Received: from huawei.com (10.175.127.227) by dggpeml500003.china.huawei.com (7.185.36.200) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2375.31; Wed, 30 Nov 2022 21:00:54 +0800 From: Li Nan <linan122@huawei.com> To: <tj@kernel.org>, <josef@toxicpanda.com>, <axboe@kernel.dk> CC: <cgroups@vger.kernel.org>, <linux-block@vger.kernel.org>, <linux-kernel@vger.kernel.org>, <linan122@huawei.com>, <yukuai3@huawei.com>, <yi.zhang@huawei.com> Subject: [PATCH -next v2 9/9] blk-iocost: fix walk_list corruption Date: Wed, 30 Nov 2022 21:21:56 +0800 Message-ID: <20221130132156.2836184-10-linan122@huawei.com> X-Mailer: git-send-email 2.31.1 In-Reply-To: <20221130132156.2836184-1-linan122@huawei.com> References: <20221130132156.2836184-1-linan122@huawei.com> MIME-Version: 1.0 Content-Transfer-Encoding: 7BIT Content-Type: text/plain; charset=US-ASCII X-Originating-IP: [10.175.127.227] X-ClientProxiedBy: dggems706-chm.china.huawei.com (10.3.19.183) To dggpeml500003.china.huawei.com (7.185.36.200) X-CFilter-Loop: Reflected X-Spam-Status: No, score=-4.2 required=5.0 tests=BAYES_00,RCVD_IN_DNSWL_MED, SPF_HELO_NONE,SPF_PASS autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: <linux-kernel.vger.kernel.org> X-Mailing-List: linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1750927405729975786?= X-GMAIL-MSGID: =?utf-8?q?1750927405729975786?= |
Series |
iocost bugfix
|
|
Commit Message
Li Nan
Nov. 30, 2022, 1:21 p.m. UTC
From: Yu Kuai <yukuai3@huawei.com> Our test report a problem: ------------[ cut here ]------------ list_del corruption. next->prev should be ffff888127e0c4b0, but was ffff888127e090b0 WARNING: CPU: 2 PID: 3117789 at lib/list_debug.c:62 __list_del_entry_valid+0x119/0x130 RIP: 0010:__list_del_entry_valid+0x119/0x130 RIP: 0010:__list_del_entry_valid+0x119/0x130 Call Trace: <IRQ> iocg_flush_stat.isra.0+0x11e/0x230 ? ioc_rqos_done+0x230/0x230 ? ioc_now+0x14f/0x180 ioc_timer_fn+0x569/0x1640 We haven't reporduced it yet, but we think this is due to parent iocg is freed before child iocg, and then in ioc_timer_fn, walk_list is corrupted. 1) Remove child cgroup can concurrent with remove parent cgroup, and ioc_pd_free for parent iocg can be called before child iocg. This can be fixed by moving the handle of walk_list to ioc_pd_offline, since that offline from child is ensured to be called before parent. 2) ioc_pd_free can be triggered from both removing device and removing cgroup, this patch fix the problem by deleting timer before deactivating policy, so that free parent iocg first in this case won't matter. Signed-off-by: Yu Kuai <yukuai3@huawei.com> Signed-off-by: Li Nan <linan122@huawei.com> --- block/blk-iocost.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-)
Comments
On Wed, Nov 30, 2022 at 09:21:56PM +0800, Li Nan wrote: > From: Yu Kuai <yukuai3@huawei.com> > > Our test report a problem: > > ------------[ cut here ]------------ > list_del corruption. next->prev should be ffff888127e0c4b0, but was ffff888127e090b0 > WARNING: CPU: 2 PID: 3117789 at lib/list_debug.c:62 __list_del_entry_valid+0x119/0x130 > RIP: 0010:__list_del_entry_valid+0x119/0x130 > RIP: 0010:__list_del_entry_valid+0x119/0x130 > Call Trace: > <IRQ> > iocg_flush_stat.isra.0+0x11e/0x230 > ? ioc_rqos_done+0x230/0x230 > ? ioc_now+0x14f/0x180 > ioc_timer_fn+0x569/0x1640 > > We haven't reporduced it yet, but we think this is due to parent iocg is > freed before child iocg, and then in ioc_timer_fn, walk_list is > corrupted. > > 1) Remove child cgroup can concurrent with remove parent cgroup, and > ioc_pd_free for parent iocg can be called before child iocg. This can be > fixed by moving the handle of walk_list to ioc_pd_offline, since that > offline from child is ensured to be called before parent. Which you already did in a previous patch, right? > 2) ioc_pd_free can be triggered from both removing device and removing > cgroup, this patch fix the problem by deleting timer before deactivating > policy, so that free parent iocg first in this case won't matter. Okay, so, yeah, css's pin parents but blkg's don't. I think the right thing to do here is making sure that a child blkg pins its parent (and eventually ioc). > Signed-off-by: Yu Kuai <yukuai3@huawei.com> > Signed-off-by: Li Nan <linan122@huawei.com> > --- > block/blk-iocost.c | 3 ++- > 1 file changed, 2 insertions(+), 1 deletion(-) > > diff --git a/block/blk-iocost.c b/block/blk-iocost.c > index 710cf63a1643..d2b873908f88 100644 > --- a/block/blk-iocost.c > +++ b/block/blk-iocost.c > @@ -2813,13 +2813,14 @@ static void ioc_rqos_exit(struct rq_qos *rqos) > { > struct ioc *ioc = rqos_to_ioc(rqos); > > + del_timer_sync(&ioc->timer); > + > blkcg_deactivate_policy(rqos->q, &blkcg_policy_iocost); > > spin_lock_irq(&ioc->lock); > ioc->running = IOC_STOP; > spin_unlock_irq(&ioc->lock); > > - del_timer_sync(&ioc->timer); I don't about this workaround. Let's fix properly?
Hi, 在 2022/12/01 4:59, Tejun Heo 写道: > On Wed, Nov 30, 2022 at 09:21:56PM +0800, Li Nan wrote: >> From: Yu Kuai <yukuai3@huawei.com> >> >> Our test report a problem: >> >> ------------[ cut here ]------------ >> list_del corruption. next->prev should be ffff888127e0c4b0, but was ffff888127e090b0 >> WARNING: CPU: 2 PID: 3117789 at lib/list_debug.c:62 __list_del_entry_valid+0x119/0x130 >> RIP: 0010:__list_del_entry_valid+0x119/0x130 >> RIP: 0010:__list_del_entry_valid+0x119/0x130 >> Call Trace: >> <IRQ> >> iocg_flush_stat.isra.0+0x11e/0x230 >> ? ioc_rqos_done+0x230/0x230 >> ? ioc_now+0x14f/0x180 >> ioc_timer_fn+0x569/0x1640 >> >> We haven't reporduced it yet, but we think this is due to parent iocg is >> freed before child iocg, and then in ioc_timer_fn, walk_list is >> corrupted. >> >> 1) Remove child cgroup can concurrent with remove parent cgroup, and >> ioc_pd_free for parent iocg can be called before child iocg. This can be >> fixed by moving the handle of walk_list to ioc_pd_offline, since that >> offline from child is ensured to be called before parent. > > Which you already did in a previous patch, right? yes, this is already did in patch 7. > >> 2) ioc_pd_free can be triggered from both removing device and removing >> cgroup, this patch fix the problem by deleting timer before deactivating >> policy, so that free parent iocg first in this case won't matter. > > Okay, so, yeah, css's pin parents but blkg's don't. I think the right thing > to do here is making sure that a child blkg pins its parent (and eventually > ioc). Ok, I can try to do that. > >> Signed-off-by: Yu Kuai <yukuai3@huawei.com> >> Signed-off-by: Li Nan <linan122@huawei.com> >> --- >> block/blk-iocost.c | 3 ++- >> 1 file changed, 2 insertions(+), 1 deletion(-) >> >> diff --git a/block/blk-iocost.c b/block/blk-iocost.c >> index 710cf63a1643..d2b873908f88 100644 >> --- a/block/blk-iocost.c >> +++ b/block/blk-iocost.c >> @@ -2813,13 +2813,14 @@ static void ioc_rqos_exit(struct rq_qos *rqos) >> { >> struct ioc *ioc = rqos_to_ioc(rqos); >> >> + del_timer_sync(&ioc->timer); >> + >> blkcg_deactivate_policy(rqos->q, &blkcg_policy_iocost); >> >> spin_lock_irq(&ioc->lock); >> ioc->running = IOC_STOP; >> spin_unlock_irq(&ioc->lock); >> >> - del_timer_sync(&ioc->timer); > > I don't about this workaround. Let's fix properly? Ok, and by the way, is there any reason to delete timer after deactivate policy? This seems a litter wreid to me. Thanks, Kuai >
On Thu, Dec 01, 2022 at 09:19:54AM +0800, Yu Kuai wrote: > > > diff --git a/block/blk-iocost.c b/block/blk-iocost.c > > > index 710cf63a1643..d2b873908f88 100644 > > > --- a/block/blk-iocost.c > > > +++ b/block/blk-iocost.c > > > @@ -2813,13 +2813,14 @@ static void ioc_rqos_exit(struct rq_qos *rqos) > > > { > > > struct ioc *ioc = rqos_to_ioc(rqos); > > > + del_timer_sync(&ioc->timer); > > > + > > > blkcg_deactivate_policy(rqos->q, &blkcg_policy_iocost); > > > spin_lock_irq(&ioc->lock); > > > ioc->running = IOC_STOP; > > > spin_unlock_irq(&ioc->lock); > > > - del_timer_sync(&ioc->timer); > > > > I don't about this workaround. Let's fix properly? > > Ok, and by the way, is there any reason to delete timer after > deactivate policy? This seems a litter wreid to me. ioc->running is what controls whether the timer gets rescheduled or not. If we don't shut that down, the timer may as well get rescheduled after being deleted. Here, the only extra activation point is IO issue which shouldn't trigger during rq_qos_exit, so the ordering shouldn't matter but this is the right order for anything which can get restarted. Thanks.
Hi, 在 2022/12/01 18:00, Tejun Heo 写道: > On Thu, Dec 01, 2022 at 09:19:54AM +0800, Yu Kuai wrote: >>>> diff --git a/block/blk-iocost.c b/block/blk-iocost.c >>>> index 710cf63a1643..d2b873908f88 100644 >>>> --- a/block/blk-iocost.c >>>> +++ b/block/blk-iocost.c >>>> @@ -2813,13 +2813,14 @@ static void ioc_rqos_exit(struct rq_qos *rqos) >>>> { >>>> struct ioc *ioc = rqos_to_ioc(rqos); >>>> + del_timer_sync(&ioc->timer); >>>> + >>>> blkcg_deactivate_policy(rqos->q, &blkcg_policy_iocost); >>>> spin_lock_irq(&ioc->lock); >>>> ioc->running = IOC_STOP; >>>> spin_unlock_irq(&ioc->lock); >>>> - del_timer_sync(&ioc->timer); >>> >>> I don't about this workaround. Let's fix properly? >> >> Ok, and by the way, is there any reason to delete timer after >> deactivate policy? This seems a litter wreid to me. > > ioc->running is what controls whether the timer gets rescheduled or not. If > we don't shut that down, the timer may as well get rescheduled after being > deleted. Here, the only extra activation point is IO issue which shouldn't > trigger during rq_qos_exit, so the ordering shouldn't matter but this is the > right order for anything which can get restarted. Thanks for the explanation. I'm trying to figure out how to make sure child blkg pins it's parent, btw, do you think following cleanup make sense? diff --git a/block/blk-iocost.c b/block/blk-iocost.c index a645184aba4a..6ad8791af9d7 100644 --- a/block/blk-iocost.c +++ b/block/blk-iocost.c @@ -2810,13 +2810,13 @@ static void ioc_rqos_exit(struct rq_qos *rqos) { struct ioc *ioc = rqos_to_ioc(rqos); - blkcg_deactivate_policy(rqos->q, &blkcg_policy_iocost); - spin_lock_irq(&ioc->lock); ioc->running = IOC_STOP; spin_unlock_irq(&ioc->lock); del_timer_sync(&ioc->timer); + blkcg_deactivate_policy(rqos->q, &blkcg_policy_iocost); + free_percpu(ioc->pcpu_stat); kfree(ioc); } Thanks, Kuai
On Thu, Dec 01, 2022 at 06:14:32PM +0800, Yu Kuai wrote: > Hi, > > 在 2022/12/01 18:00, Tejun Heo 写道: > > On Thu, Dec 01, 2022 at 09:19:54AM +0800, Yu Kuai wrote: > > > > > diff --git a/block/blk-iocost.c b/block/blk-iocost.c > > > > > index 710cf63a1643..d2b873908f88 100644 > > > > > --- a/block/blk-iocost.c > > > > > +++ b/block/blk-iocost.c > > > > > @@ -2813,13 +2813,14 @@ static void ioc_rqos_exit(struct rq_qos *rqos) > > > > > { > > > > > struct ioc *ioc = rqos_to_ioc(rqos); > > > > > + del_timer_sync(&ioc->timer); > > > > > + > > > > > blkcg_deactivate_policy(rqos->q, &blkcg_policy_iocost); > > > > > spin_lock_irq(&ioc->lock); > > > > > ioc->running = IOC_STOP; > > > > > spin_unlock_irq(&ioc->lock); > > > > > - del_timer_sync(&ioc->timer); > > > > > > > > I don't about this workaround. Let's fix properly? > > > > > > Ok, and by the way, is there any reason to delete timer after > > > deactivate policy? This seems a litter wreid to me. > > > > ioc->running is what controls whether the timer gets rescheduled or not. If > > we don't shut that down, the timer may as well get rescheduled after being > > deleted. Here, the only extra activation point is IO issue which shouldn't > > trigger during rq_qos_exit, so the ordering shouldn't matter but this is the > > right order for anything which can get restarted. > > Thanks for the explanation. > > I'm trying to figure out how to make sure child blkg pins it's parent, > btw, do you think following cleanup make sense? It's on you to explain why any change that you're suggesting is better and safe. I know it's not intentional but you're repeatedly suggesting operation reorderings in code paths which are really sensitive to ordering at least seemingly without putting much effort into thinking through the side effects. This costs disproportionate amount of review bandwidth, and increases the chance of new subtle bugs. Can you please slow down a bit and be more deliberate? Thanks.
在 2022/12/01 18:29, Tejun Heo 写道: > On Thu, Dec 01, 2022 at 06:14:32PM +0800, Yu Kuai wrote: >> Hi, >> >> 在 2022/12/01 18:00, Tejun Heo 写道: >>> On Thu, Dec 01, 2022 at 09:19:54AM +0800, Yu Kuai wrote: >>>>>> diff --git a/block/blk-iocost.c b/block/blk-iocost.c >>>>>> index 710cf63a1643..d2b873908f88 100644 >>>>>> --- a/block/blk-iocost.c >>>>>> +++ b/block/blk-iocost.c >>>>>> @@ -2813,13 +2813,14 @@ static void ioc_rqos_exit(struct rq_qos *rqos) >>>>>> { >>>>>> struct ioc *ioc = rqos_to_ioc(rqos); >>>>>> + del_timer_sync(&ioc->timer); >>>>>> + >>>>>> blkcg_deactivate_policy(rqos->q, &blkcg_policy_iocost); >>>>>> spin_lock_irq(&ioc->lock); >>>>>> ioc->running = IOC_STOP; >>>>>> spin_unlock_irq(&ioc->lock); >>>>>> - del_timer_sync(&ioc->timer); >>>>> >>>>> I don't about this workaround. Let's fix properly? >>>> >>>> Ok, and by the way, is there any reason to delete timer after >>>> deactivate policy? This seems a litter wreid to me. >>> >>> ioc->running is what controls whether the timer gets rescheduled or not. If >>> we don't shut that down, the timer may as well get rescheduled after being >>> deleted. Here, the only extra activation point is IO issue which shouldn't >>> trigger during rq_qos_exit, so the ordering shouldn't matter but this is the >>> right order for anything which can get restarted. >> >> Thanks for the explanation. >> >> I'm trying to figure out how to make sure child blkg pins it's parent, >> btw, do you think following cleanup make sense? > > It's on you to explain why any change that you're suggesting is better and > safe. I know it's not intentional but you're repeatedly suggesting operation > reorderings in code paths which are really sensitive to ordering at least > seemingly without putting much effort into thinking through the side > effects. This costs disproportionate amount of review bandwidth, and > increases the chance of new subtle bugs. Can you please slow down a bit and > be more deliberate? Thanks for the suggestion, I'll pay close attention to explain this "why the change is better and safe". And sorry for the review pressure. 😔 > > Thanks. >
Hi, Tejun 在 2022/12/01 4:59, Tejun Heo 写道: > On Wed, Nov 30, 2022 at 09:21:56PM +0800, Li Nan wrote: >> From: Yu Kuai <yukuai3@huawei.com> >> >> Our test report a problem: >> >> ------------[ cut here ]------------ >> list_del corruption. next->prev should be ffff888127e0c4b0, but was ffff888127e090b0 >> WARNING: CPU: 2 PID: 3117789 at lib/list_debug.c:62 __list_del_entry_valid+0x119/0x130 >> RIP: 0010:__list_del_entry_valid+0x119/0x130 >> RIP: 0010:__list_del_entry_valid+0x119/0x130 >> Call Trace: >> <IRQ> >> iocg_flush_stat.isra.0+0x11e/0x230 >> ? ioc_rqos_done+0x230/0x230 >> ? ioc_now+0x14f/0x180 >> ioc_timer_fn+0x569/0x1640 >> >> We haven't reporduced it yet, but we think this is due to parent iocg is >> freed before child iocg, and then in ioc_timer_fn, walk_list is >> corrupted. >> >> 1) Remove child cgroup can concurrent with remove parent cgroup, and >> ioc_pd_free for parent iocg can be called before child iocg. This can be >> fixed by moving the handle of walk_list to ioc_pd_offline, since that >> offline from child is ensured to be called before parent. > > Which you already did in a previous patch, right? > >> 2) ioc_pd_free can be triggered from both removing device and removing >> cgroup, this patch fix the problem by deleting timer before deactivating >> policy, so that free parent iocg first in this case won't matter. > > Okay, so, yeah, css's pin parents but blkg's don't. I think the right thing > to do here is making sure that a child blkg pins its parent (and eventually > ioc). Sorry about this, actually it's can be ensured that pd_offline from child will be called before parent. Hence just moving he handle of walk_list to ioc_pd_offline can fix this problem thoroughly. Thanks, Kuai
diff --git a/block/blk-iocost.c b/block/blk-iocost.c index 710cf63a1643..d2b873908f88 100644 --- a/block/blk-iocost.c +++ b/block/blk-iocost.c @@ -2813,13 +2813,14 @@ static void ioc_rqos_exit(struct rq_qos *rqos) { struct ioc *ioc = rqos_to_ioc(rqos); + del_timer_sync(&ioc->timer); + blkcg_deactivate_policy(rqos->q, &blkcg_policy_iocost); spin_lock_irq(&ioc->lock); ioc->running = IOC_STOP; spin_unlock_irq(&ioc->lock); - del_timer_sync(&ioc->timer); free_percpu(ioc->pcpu_stat); kfree(ioc); }