Linux RAID subsystem development
 help / color / mirror / Atom feed
From: Neil Brown <neilb@cse.unsw.edu.au>
To: Andrew Morton <akpm@osdl.org>
Cc: linux-raid@vger.kernel.org
Subject: Re: [PATCH] md - 8 of 8 - Support reshaping raid1 arrays - adding or removing drives.
Date: Fri, 28 May 2004 18:41:30 +1000	[thread overview]
Message-ID: <16566.64314.889124.856138@cse.unsw.edu.au> (raw)
In-Reply-To: message from Andrew Morton on Friday May 28

On Friday May 28, akpm@osdl.org wrote:
> NeilBrown <neilb@cse.unsw.edu.au> wrote:
> >
> > This requires allocating a new pool of "r1bio" structures which a different
> >  number of bios, suspending IO, and swapping the new pool in place of the old.
> >  (and a few other related changes).
> 
> Wanna send me the missing hunk?
> 

Blush. thats what you get for writing your own patch management
software...




diff ./include/linux/raid/raid1.h~current~ ./include/linux/raid/raid1.h
--- ./include/linux/raid/raid1.h~current~	2004-05-28 18:30:13.000000000 +1000
+++ ./include/linux/raid/raid1.h	2004-05-28 18:36:52.000000000 +1000
@@ -10,6 +10,20 @@ struct mirror_info {
 	sector_t	head_position;
 };
 
+/*
+ * memory pools need a pointer to the mddev, so they can force an unplug
+ * when memory is tight, and a count of the number of drives that the
+ * pool was allocated for, so they know how much to allocate and free.
+ * mddev->raid_disks cannot be used, as it can change while a pool is active
+ * These two datums are stored in a kmalloced struct.
+ */
+
+struct pool_info {
+	mddev_t *mddev;
+	int	raid_disks;
+};
+
+
 typedef struct r1bio_s r1bio_t;
 
 struct r1_private_data_s {
@@ -31,6 +45,8 @@ struct r1_private_data_s {
 	wait_queue_head_t	wait_idle;
 	wait_queue_head_t	wait_resume;
 
+	struct pool_info	*poolinfo;
+
 	mempool_t *r1bio_pool;
 	mempool_t *r1buf_pool;
 };


  reply	other threads:[~2004-05-28  8:41 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2004-05-28  6:45 [PATCH] md - 0 of 8 - Introduction NeilBrown
2004-05-28  6:45 ` [PATCH] md - 4 of 8 - Make sure the size of a raid5/6 array is a multiple of the chunk size NeilBrown
2004-05-28  6:45 ` [PATCH] md - 8 of 8 - Support reshaping raid1 arrays - adding or removing drives NeilBrown
2004-05-28  7:31   ` Andrew Morton
2004-05-28  8:41     ` Neil Brown [this message]
2004-05-28 13:32   ` Mario 'BitKoenig' Holbe
2004-05-28 22:47     ` Neil Brown
2004-05-28  6:45 ` [PATCH] md - 2 of 8 - Make sure md_check_recovery will remove a faulty device when ->nr_pending hits 0 NeilBrown
2004-05-28  6:45 ` [PATCH] md - 1 of 8 - Rationalise device selection in md/multipath NeilBrown
2004-05-28  6:45 ` [PATCH] md - 5 of 8 - Handle hot-add for arrays with non-persistent superblocks NeilBrown
2004-05-28  6:45 ` [PATCH] md - 6 of 8 - Abort the resync of raid1 there is only one device NeilBrown
2004-05-28  6:45 ` [PATCH] md - 3 of 8 - Allow an md personality to refuse a hot-remove request NeilBrown
2004-05-28 18:35   ` 3ware 7506-8 and Tyan Thunder 2500, S1867, anyone? buggz
2004-05-28  6:45 ` [PATCH] md - 7 of 8 - Allow md arrays to be resized if devices are large enough NeilBrown

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=16566.64314.889124.856138@cse.unsw.edu.au \
    --to=neilb@cse.unsw.edu.au \
    --cc=akpm@osdl.org \
    --cc=linux-raid@vger.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