All of lore.kernel.org
 help / color / mirror / Atom feed
From: Mike Snitzer <snitzer@redhat.com>
To: Akira Hayakawa <ruby.wktk@gmail.com>
Cc: devel@driverdev.osuosl.org, gregkh@linuxfoundation.org,
	linux-kernel@vger.kernel.org, dm-devel@redhat.com,
	agk@redhat.com, joe@perches.com, akpm@linux-foundation.org,
	dan.carpenter@oracle.com, ejt@redhat.com, cesarb@cesarb.net,
	m.chehab@samsung.com
Subject: Re: Reworking dm-writeboost [was: Re: staging: Add dm-writeboost]
Date: Fri, 27 Sep 2013 14:35:07 -0400	[thread overview]
Message-ID: <20130927183507.GA16553@redhat.com> (raw)
In-Reply-To: <5243922B.6070705@gmail.com>

On Wed, Sep 25 2013 at  9:47pm -0400,
Akira Hayakawa <ruby.wktk@gmail.com> wrote:

> Hi, Mike
> 
> The monolithic source code (3.2k)
> is nicely splitted into almost 20 *.c files
> according to the functionality and
> data strucutures in OOP style.
> 
> The aim of this posting
> is to share how the splitting looks like.
> 
> I believe that
> at least reading the *.h files
> can convince you the splitting is clear.
> 
> The code is now tainted with
> almost 20 version switch macros
> and WB* debug macros
> but I will clean them up
> for sending patch.
> 
> Again,
> the latest code can be cloned by
> git clone https://github.com/akiradeveloper/dm-writeboost.git
> 
> I will make few updates to the source codes on this weekend
> so please track it to follow the latest version.
> Below is only the snapshot.
> 
> Akira
> 
> ---------- Summary ----------
> 33 Makefile
> 10 bigarray.h
> 19 cache-alloc.h
> 10 defer-barrier.h
> 8 dirty-sync.h
> 8 flush-daemon.h
> 10 format-cache.h
> 24 handle-io.h
> 16 hashtable.h
> 18 migrate-daemon.h
> 7 migrate-modulator.h
> 12 queue-flush-job.h
> 8 rambuf.h
> 13 recover.h
> 18 segment.h
> 8 superblock-recorder.h
> 9 target.h
> 30 util.h
> 384 writeboost.h
> 99 bigarray.c
> 192 cache-alloc.c
> 36 defer-barrier.c
> 33 dirty-sync.c
> 85 flush-daemon.c
> 234 format-cache.c
> 553 handle-io.c
> 109 hashtable.c
> 345 migrate-daemon.c
> 41 migrate-modulator.c
> 169 queue-flush-job.c
> 52 rambuf.c
> 308 recover.c
> 118 segment.c
> 61 superblock-recorder.c
> 376 target.c
> 126 util.c

Unfortunately I think you went too far with all these different small
files, I was hoping to see 2 or 3 .c files and a couple .h files.

Maybe fold all the daemon code into a 1 .c and 1 .h ?

The core of the writeboost target in dm-writeboost-target.c ?

And fold all the other data structures into a 1 .c and 1 .h ?

When folding these files together feel free to use dividers in the code
like dm-thin.c and dm-cache-target.c do, e.g.:

/*-----------------------------------------------------------------*/

Mike

WARNING: multiple messages have this Message-ID (diff)
From: Mike Snitzer <snitzer@redhat.com>
To: Akira Hayakawa <ruby.wktk@gmail.com>
Cc: gregkh@linuxfoundation.org, devel@driverdev.osuosl.org,
	linux-kernel@vger.kernel.org, dm-devel@redhat.com,
	cesarb@cesarb.net, joe@perches.com, akpm@linux-foundation.org,
	agk@redhat.com, m.chehab@samsung.com, ejt@redhat.com,
	dan.carpenter@oracle.com
Subject: Re: Reworking dm-writeboost [was: Re: staging: Add dm-writeboost]
Date: Fri, 27 Sep 2013 14:35:07 -0400	[thread overview]
Message-ID: <20130927183507.GA16553@redhat.com> (raw)
In-Reply-To: <5243922B.6070705@gmail.com>

On Wed, Sep 25 2013 at  9:47pm -0400,
Akira Hayakawa <ruby.wktk@gmail.com> wrote:

> Hi, Mike
> 
> The monolithic source code (3.2k)
> is nicely splitted into almost 20 *.c files
> according to the functionality and
> data strucutures in OOP style.
> 
> The aim of this posting
> is to share how the splitting looks like.
> 
> I believe that
> at least reading the *.h files
> can convince you the splitting is clear.
> 
> The code is now tainted with
> almost 20 version switch macros
> and WB* debug macros
> but I will clean them up
> for sending patch.
> 
> Again,
> the latest code can be cloned by
> git clone https://github.com/akiradeveloper/dm-writeboost.git
> 
> I will make few updates to the source codes on this weekend
> so please track it to follow the latest version.
> Below is only the snapshot.
> 
> Akira
> 
> ---------- Summary ----------
> 33 Makefile
> 10 bigarray.h
> 19 cache-alloc.h
> 10 defer-barrier.h
> 8 dirty-sync.h
> 8 flush-daemon.h
> 10 format-cache.h
> 24 handle-io.h
> 16 hashtable.h
> 18 migrate-daemon.h
> 7 migrate-modulator.h
> 12 queue-flush-job.h
> 8 rambuf.h
> 13 recover.h
> 18 segment.h
> 8 superblock-recorder.h
> 9 target.h
> 30 util.h
> 384 writeboost.h
> 99 bigarray.c
> 192 cache-alloc.c
> 36 defer-barrier.c
> 33 dirty-sync.c
> 85 flush-daemon.c
> 234 format-cache.c
> 553 handle-io.c
> 109 hashtable.c
> 345 migrate-daemon.c
> 41 migrate-modulator.c
> 169 queue-flush-job.c
> 52 rambuf.c
> 308 recover.c
> 118 segment.c
> 61 superblock-recorder.c
> 376 target.c
> 126 util.c

Unfortunately I think you went too far with all these different small
files, I was hoping to see 2 or 3 .c files and a couple .h files.

Maybe fold all the daemon code into a 1 .c and 1 .h ?

The core of the writeboost target in dm-writeboost-target.c ?

And fold all the other data structures into a 1 .c and 1 .h ?

When folding these files together feel free to use dividers in the code
like dm-thin.c and dm-cache-target.c do, e.g.:

/*-----------------------------------------------------------------*/

Mike

  reply	other threads:[~2013-09-27 18:35 UTC|newest]

Thread overview: 45+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-09-01 11:10 [PATCH] staging: Add dm-writeboost Akira Hayakawa
2013-09-16 21:53 ` Mike Snitzer
2013-09-16 21:53   ` Mike Snitzer
2013-09-16 22:49   ` Dan Carpenter
2013-09-16 22:49     ` Dan Carpenter
2013-09-17 12:41   ` Akira Hayakawa
2013-09-17 12:41     ` Akira Hayakawa
2013-09-17 20:18     ` Mike Snitzer
2013-09-17 20:18       ` Mike Snitzer
2013-09-17 12:43   ` Akira Hayakawa
2013-09-17 12:43     ` Akira Hayakawa
2013-09-17 20:59     ` Mike Snitzer
2013-09-17 20:59       ` Mike Snitzer
2013-09-22  0:09       ` Reworking dm-writeboost [was: Re: staging: Add dm-writeboost] Akira Hayakawa
2013-09-22  0:09         ` Akira Hayakawa
2013-09-24 12:20         ` Akira Hayakawa
2013-09-24 12:20           ` Akira Hayakawa
2013-09-25 17:37           ` Mike Snitzer
2013-09-25 17:37             ` Mike Snitzer
2013-09-26  1:42             ` Akira Hayakawa
2013-09-26  1:47             ` Akira Hayakawa
2013-09-27 18:35               ` Mike Snitzer [this message]
2013-09-27 18:35                 ` Mike Snitzer
2013-09-28 11:29                 ` Akira Hayakawa
2013-09-28 11:29                   ` Akira Hayakawa
2013-09-25 23:03           ` Greg KH
2013-09-25 23:03             ` Greg KH
2013-09-26  3:43           ` Dave Chinner
2013-10-01  8:26             ` Joe Thornber
2013-10-01  8:26               ` Joe Thornber
2013-10-03  0:01               ` Mikulas Patocka
2013-10-03  0:01                 ` [dm-devel] " Mikulas Patocka
2013-10-04  2:04                 ` Dave Chinner
2013-10-04  2:04                   ` Dave Chinner
2013-10-05  7:51                   ` Akira Hayakawa
2013-10-07 23:43                     ` Dave Chinner
2013-10-08  9:41                       ` Christoph Hellwig
2013-10-08  9:41                         ` Christoph Hellwig
2013-10-08 10:37                         ` Akira Hayakawa
2013-10-08 10:37                           ` Akira Hayakawa
2013-10-08 15:29                           ` Mike Snitzer
2013-10-09  1:07                             ` Akira Hayakawa
2013-10-09  1:07                               ` Akira Hayakawa
2013-10-08 10:57                       ` [dm-devel] " Akira Hayakawa
2013-10-08 10:57                         ` Akira Hayakawa

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=20130927183507.GA16553@redhat.com \
    --to=snitzer@redhat.com \
    --cc=agk@redhat.com \
    --cc=akpm@linux-foundation.org \
    --cc=cesarb@cesarb.net \
    --cc=dan.carpenter@oracle.com \
    --cc=devel@driverdev.osuosl.org \
    --cc=dm-devel@redhat.com \
    --cc=ejt@redhat.com \
    --cc=gregkh@linuxfoundation.org \
    --cc=joe@perches.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=m.chehab@samsung.com \
    --cc=ruby.wktk@gmail.com \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.