From: Dan Williams <dan.j.williams@intel.com>
To: neilb@suse.de
Cc: linux-raid@vger.kernel.org, krzysztof.wojcik@intel.com,
ed.ciechanowski@intel.com, maciej.patelczyk@intel.com
Subject: [mdadm PATCH 02/12] imsm: kill close() of component device
Date: Tue, 13 Oct 2009 19:10:26 -0700 [thread overview]
Message-ID: <20091014021026.31570.69803.stgit@dwillia2-linux.ch.intel.com> (raw)
In-Reply-To: <20091014020739.31570.36408.stgit@dwillia2-linux.ch.intel.com>
None of the other formats close the passed in fd at load, and this
becomes a problem when trying to support --update where we need O_EXCL
protection across the entire operation.
Signed-off-by: Dan Williams <dan.j.williams@intel.com>
---
super-intel.c | 4 +---
1 files changed, 1 insertions(+), 3 deletions(-)
diff --git a/super-intel.c b/super-intel.c
index 9f57a68..80cd6c5 100644
--- a/super-intel.c
+++ b/super-intel.c
@@ -1685,10 +1685,8 @@ load_imsm_disk(int fd, struct intel_super *super, char *devname, int keep_fd)
serialcpy(dl->serial, serial);
dl->index = -2;
dl->e = NULL;
- } else if (keep_fd) {
- close(dl->fd);
+ } else if (keep_fd)
dl->fd = fd;
- }
/* look up this disk's index in the current anchor */
for (i = 0; i < super->anchor->num_disks; i++) {
next prev parent reply other threads:[~2009-10-14 2:10 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-10-14 2:10 [mdadm PATCH 00/12] External metadata updates and other fixes for 3.0.3 Dan Williams
2009-10-14 2:10 ` [mdadm PATCH 01/12] imsm: cleanup disk status tests Dan Williams
2009-10-14 2:10 ` Dan Williams [this message]
2009-10-14 2:10 ` [mdadm PATCH 03/12] imsm: disambiguate family_num Dan Williams
2009-10-14 2:10 ` [mdadm PATCH 04/12] imsm: fix spare record writeout race Dan Williams
2009-10-14 2:10 ` [mdadm PATCH 05/12] imsm: fix/support --update Dan Williams
2009-10-14 2:10 ` [mdadm PATCH 06/12] ddf: prevent superblock being zeroed on --update Dan Williams
2009-10-14 2:10 ` [mdadm PATCH 07/12] imsm: add --update=uuid support Dan Williams
2009-10-14 2:10 ` [mdadm PATCH 08/12] imsm: regression test for prodigal array member scenario Dan Williams
2009-10-14 2:11 ` [mdadm PATCH 09/12] Detail: export MD_UUID from mapfile Dan Williams
2009-10-14 2:11 ` [mdadm PATCH 10/12] mdmon: avoid writes in the startup path for mdmon on root arrays Dan Williams
2009-10-14 2:11 ` [mdadm PATCH 11/12] mdmon: exec(2) when the switchroot argument is not "/" Dan Williams
2009-10-19 1:57 ` Neil Brown
2009-10-14 2:11 ` [mdadm PATCH 12/12] mdmon: preserve socket over chroot Dan Williams
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=20091014021026.31570.69803.stgit@dwillia2-linux.ch.intel.com \
--to=dan.j.williams@intel.com \
--cc=ed.ciechanowski@intel.com \
--cc=krzysztof.wojcik@intel.com \
--cc=linux-raid@vger.kernel.org \
--cc=maciej.patelczyk@intel.com \
--cc=neilb@suse.de \
/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).