cgroups.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Vivek Goyal <vgoyal@redhat.com>
To: Tejun Heo <tj@kernel.org>
Cc: Jens Axboe <axboe@kernel.dk>,
	linux-kernel@vger.kernel.org, Li Zefan <lizefan@huawei.com>,
	cgroups@vger.kernel.org
Subject: Re: [PATCH RFC] blkcg: prepare blkcg knobs for default hierarchy
Date: Tue, 27 May 2014 08:49:12 -0400	[thread overview]
Message-ID: <20140527124912.GC10994@redhat.com> (raw)
In-Reply-To: <20140523173957.GA31780@htj.dyndns.org>

On Fri, May 23, 2014 at 01:39:57PM -0400, Tejun Heo wrote:
> Hello, Vivek.
> 
> On Wed, Apr 23, 2014 at 03:21:09PM -0400, Vivek Goyal wrote:
> > What about sync/async differentiation? Throttling layer seems to flag a request sync
> > only if bio->bi_rw flag has REQ_SYNC set. While CFQ seems to consider
> > request sync if bio is either read or bio->bi_rw has REQ_SYNC flag set.
> 
> Working on this again, AFAICS, both treat REQ_SYNC the same way as far
> as stats are concerned.  If SYNC is set, it's sync; otherwise, it's
> accounted as async whether read or write.

Ok, that seems to be the case.

static inline void blkg_rwstat_add(struct blkg_rwstat *rwstat,
                                   int rw, uint64_t val)
{
        u64_stats_update_begin(&rwstat->syncp);

        if (rw & REQ_SYNC)
                rwstat->cnt[BLKG_RWSTAT_SYNC] += val;
        else
                rwstat->cnt[BLKG_RWSTAT_ASYNC] += val;

        u64_stats_update_end(&rwstat->syncp);
}


So sync will represent not policy specific interpretation of sync but
based on sync flag on request.

I guess it is fine. So far nobody seems to be complaining.

Thanks
Vivek

      reply	other threads:[~2014-05-27 12:49 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-04-13  1:32 [PATCH RFC] blkcg: prepare blkcg knobs for default hierarchy Tejun Heo
2014-04-14 18:08 ` Vivek Goyal
2014-04-14 19:32   ` Tejun Heo
     [not found]     ` <20140414193214.GC16835-Gd/HAXX7CRxy/B6EtB590w@public.gmane.org>
2014-04-15 13:53       ` Vivek Goyal
     [not found]         ` <20140415135359.GA13033-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org>
2014-04-15 14:06           ` Tejun Heo
2014-04-15 14:18             ` Vivek Goyal
     [not found]               ` <20140415141826.GB17018-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org>
2014-04-23 17:01                 ` Tejun Heo
     [not found]                   ` <20140423170141.GJ4781-Gd/HAXX7CRxy/B6EtB590w@public.gmane.org>
2014-04-23 17:17                     ` Vivek Goyal
2014-04-23 18:52                       ` Tejun Heo
     [not found]                         ` <20140423185231.GA4163-9pTldWuhBndy/B6EtB590w@public.gmane.org>
2014-04-23 18:58                           ` Vivek Goyal
2014-04-23 19:00                             ` Tejun Heo
     [not found]                               ` <20140423190043.GB4163-9pTldWuhBndy/B6EtB590w@public.gmane.org>
2014-04-23 19:21                                 ` Vivek Goyal
2014-04-23 19:27                                   ` Tejun Heo
2014-05-23 17:39                                   ` Tejun Heo
2014-05-27 12:49                                     ` Vivek Goyal [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20140527124912.GC10994@redhat.com \
    --to=vgoyal@redhat.com \
    --cc=axboe@kernel.dk \
    --cc=cgroups@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=lizefan@huawei.com \
    --cc=tj@kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).