Commit 88ed806a authored by Linus Torvalds's avatar Linus Torvalds
Browse files

Merge tag 'md/3.18' of git://neil.brown.name/md

Pull md updates from Neil Brown:
 - a few minor bug fixes
 - quite a lot of code tidy-up and simplification
 - remove PRINT_RAID_DEBUG ioctl.  I'm fairly sure it is unused, and it
   isn't particularly useful.

* tag 'md/3.18' of git://neil.brown.name/md: (21 commits)
  lib/raid6: Add log level to printks
  md: move EXPORT_SYMBOL to after function in md.c
  md: discard PRINT_RAID_DEBUG ioctl
  md: remove MD_BUG()
  md: clean up 'exit' labels in md_ioctl().
  md: remove unnecessary test for MD_MAJOR in md_ioctl()
  md: don't allow "-sync" to be set for device in an active array.
  md: remove unwanted white space from md.c
  md: don't start resync thread directly from md thread.
  md: Just use RCU when checking for overlap between arrays.
  md: avoid potential long delay under pers_lock
  md: simplify export_array()
  md: discard find_rdev_nr in favour of find_rdev_nr_rcu
  md: use wait_event() to simplify md_super_wait()
  md: be more relaxed about stopping an array which isn't started.
  md/raid1: process_checks doesn't use its return value.
  md/raid5: fix init_stripe() inconsistencies
  md/raid10: another memory leak due to reshape.
  md: use set_bit/clear_bit instead of shift/mask for bi_flags changes.
  md/raid1: minor typos and reformatting.
  ...
parents e56d9fcc b395f75e
Loading
Loading
Loading
Loading
+6 −10
Original line number Diff line number Diff line
@@ -879,7 +879,6 @@ void bitmap_unplug(struct bitmap *bitmap)
{
	unsigned long i;
	int dirty, need_write;
	int wait = 0;

	if (!bitmap || !bitmap->storage.filemap ||
	    test_bit(BITMAP_STALE, &bitmap->flags))
@@ -897,16 +896,13 @@ void bitmap_unplug(struct bitmap *bitmap)
			clear_page_attr(bitmap, i, BITMAP_PAGE_PENDING);
			write_page(bitmap, bitmap->storage.filemap[i], 0);
		}
		if (dirty)
			wait = 1;
	}
	if (wait) { /* if any writes were performed, we need to wait on them */
	if (bitmap->storage.file)
		wait_event(bitmap->write_wait,
			   atomic_read(&bitmap->pending_writes)==0);
	else
		md_super_wait(bitmap->mddev);
	}

	if (test_bit(BITMAP_WRITE_ERROR, &bitmap->flags))
		bitmap_file_kick(bitmap);
}
+3 −5
Original line number Diff line number Diff line
@@ -355,7 +355,6 @@ static void linear_status (struct seq_file *seq, struct mddev *mddev)
	seq_printf(seq, " %dk rounding", mddev->chunk_sectors / 2);
}


static struct md_personality linear_personality =
{
	.name		= "linear",
@@ -379,7 +378,6 @@ static void linear_exit (void)
	unregister_md_personality (&linear_personality);
}


module_init(linear_init);
module_exit(linear_exit);
MODULE_LICENSE("GPL");
+195 −406

File changed.

Preview size limit exceeded, changes collapsed.

+16 −18
Original line number Diff line number Diff line
@@ -439,7 +439,6 @@ struct mddev {
	void (*sync_super)(struct mddev *mddev, struct md_rdev *rdev);
};


static inline void rdev_dec_pending(struct md_rdev *rdev, struct mddev *mddev)
{
	int faulty = test_bit(Faulty, &rdev->flags);
@@ -493,7 +492,6 @@ struct md_personality
	void *(*takeover) (struct mddev *mddev);
};


struct md_sysfs_entry {
	struct attribute attr;
	ssize_t (*show)(struct mddev *, char *);
+11 −17
Original line number Diff line number Diff line
@@ -31,7 +31,6 @@

#define	NR_RESERVED_BUFS	32


static int multipath_map (struct mpconf *conf)
{
	int i, disks = conf->raid_disks;
@@ -68,7 +67,6 @@ static void multipath_reschedule_retry (struct multipath_bh *mp_bh)
	md_wakeup_thread(mddev->thread);
}


/*
 * multipath_end_bh_io() is called when we have finished servicing a multipathed
 * operation and are ready to return a success/failure code to the buffer
@@ -242,7 +240,6 @@ static void print_multipath_conf (struct mpconf *conf)
	}
}


static int multipath_add_disk(struct mddev *mddev, struct md_rdev *rdev)
{
	struct mpconf *conf = mddev->private;
@@ -325,8 +322,6 @@ abort:
	return err;
}



/*
 * This is a kernel thread which:
 *
@@ -512,7 +507,6 @@ out:
	return -EIO;
}


static int multipath_stop (struct mddev *mddev)
{
	struct mpconf *conf = mddev->private;
Loading