From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S965009AbbJVO0F (ORCPT ); Thu, 22 Oct 2015 10:26:05 -0400 Received: from mx1.redhat.com ([209.132.183.28]:54338 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S964914AbbJVO0B (ORCPT ); Thu, 22 Oct 2015 10:26:01 -0400 From: Jeff Moyer To: Tejun Heo Cc: Jens Axboe , Vivek Goyal , linux-kernel@vger.kernel.org, kernel-team@fb.com Subject: Re: [PATCH block/for-linus] blkcg: fix incorrect read/write sync/async stat accounting References: <20151022002712.GA10199@mtj.duckdns.org> X-PGP-KeyID: 1F78E1B4 X-PGP-CertKey: F6FE 280D 8293 F72C 65FD 5A58 1FF8 A7CA 1F78 E1B4 X-PCLoadLetter: What the f**k does that mean? Date: Thu, 22 Oct 2015 10:25:59 -0400 In-Reply-To: <20151022002712.GA10199@mtj.duckdns.org> (Tejun Heo's message of "Thu, 22 Oct 2015 09:27:12 +0900") Message-ID: User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.3 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Tejun Heo writes: > While unifying how blkcg stats are collected, 77ea733884eb ("blkcg: > move io_service_bytes and io_serviced stats into blkcg_gq") > incorrectly used bio->flags instead of bio->rw to tell the IO type. > This made IOs to be accounted as the wrong type. Fix it. > > Signed-off-by: Tejun Heo > Fixes: 77ea733884eb ("blkcg: move io_service_bytes and io_serviced stats into blkcg_gq") Reviewed-by: Jeff Moyer > --- > include/linux/blk-cgroup.h | 4 ++-- > 1 file changed, 2 insertions(+), 2 deletions(-) > > --- a/include/linux/blk-cgroup.h > +++ b/include/linux/blk-cgroup.h > @@ -713,9 +713,9 @@ static inline bool blkcg_bio_issue_check > > if (!throtl) { > blkg = blkg ?: q->root_blkg; > - blkg_rwstat_add(&blkg->stat_bytes, bio->bi_flags, > + blkg_rwstat_add(&blkg->stat_bytes, bio->bi_rw, > bio->bi_iter.bi_size); > - blkg_rwstat_add(&blkg->stat_ios, bio->bi_flags, 1); > + blkg_rwstat_add(&blkg->stat_ios, bio->bi_rw, 1); > } > > rcu_read_unlock(); > -- > To unsubscribe from this list: send the line "unsubscribe linux-kernel" in > the body of a message to majordomo@vger.kernel.org > More majordomo info at http://vger.kernel.org/majordomo-info.html > Please read the FAQ at http://www.tux.org/lkml/