linux-xfs.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: "Darrick J. Wong" <darrick.wong@oracle.com>
To: Christoph Hellwig <hch@infradead.org>
Cc: linux-xfs@vger.kernel.org
Subject: Re: [PATCH 2/3] xfs: refactor unmount record write
Date: Thu, 19 Jul 2018 10:40:17 -0700	[thread overview]
Message-ID: <20180719174017.GJ4813@magnolia> (raw)
In-Reply-To: <20180719163947.GB10151@infradead.org>

On Thu, Jul 19, 2018 at 09:39:47AM -0700, Christoph Hellwig wrote:
> Looks generally fine, but some tiny nitpicks:
> 
> > +	/* the data section must be 32 bit size aligned */
> > +	struct {
> > +		uint16_t magic;
> > +		uint16_t pad1;
> > +		uint32_t pad2; /* may as well make it 64 bits */
> > +	} magic = {
> > +		.magic = XLOG_UNMOUNT_TYPE,
> > +	};
> 
> Can we please give this structure type a name and move it to
> xfs_log_format.h?  They way this had been done always irked me.

Ok.  It gets written to disk, so that makes sense.

> > +	/*
> > +	 * At this point, we're umounting anyway,
> > +	 * so there's no point in transitioning log state
> > +	 * to IOERROR. Just continue...
> > +	 */
> 
> Use up all 80 lines, please.
> 
> > +	if (!(iclog->ic_state == XLOG_STATE_ACTIVE ||
> > +	      iclog->ic_state == XLOG_STATE_DIRTY) &&
> > +	    !XLOG_FORCED_SHUTDOWN(log))
> > +		xlog_wait(&iclog->ic_force_wait, &log->l_icloglock);
> > +	else
> > +		spin_unlock(&log->l_icloglock);
> 
> 	switch (iclog->ic_state) {
> 	default:
> 		if (!XLOG_FORCED_SHUTDOWN(log)) {
> 			xlog_wait(&iclog->ic_force_wait, &log->l_icloglock);
> 			break;
> 		}
> 		/*FALLHRU*/
> 	case XLOG_STATE_ACTIVE:
> 	case XLOG_STATE_DIRTY:
> 		spin_unlock(&log->l_icloglock);
> 		break;

<nod>

--D

> 
> --
> To unsubscribe from this list: send the line "unsubscribe linux-xfs" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at  http://vger.kernel.org/majordomo-info.html

  reply	other threads:[~2018-07-19 18:24 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-07-18 23:39 [PATCH 0/3] xfs-4.19: fix bogus summary counters on mount Darrick J. Wong
2018-07-18 23:39 ` [PATCH 1/3] xfs: detect and fix bad summary counts at mount Darrick J. Wong
2018-07-19 16:36   ` Christoph Hellwig
2018-07-18 23:39 ` [PATCH 2/3] xfs: refactor unmount record write Darrick J. Wong
2018-07-19 16:39   ` Christoph Hellwig
2018-07-19 17:40     ` Darrick J. Wong [this message]
2018-07-19 17:41   ` [PATCH v2 " Darrick J. Wong
2018-07-20 16:04     ` Christoph Hellwig
2018-07-18 23:39 ` [PATCH 3/3] xfs: force summary counter recalc at next mount Darrick J. Wong
2018-07-19 16:40   ` Christoph Hellwig
2018-07-19 16:44     ` Darrick J. Wong
2018-07-19 16:45 ` [RFC PATCH 4/3] xfstests: test mount time summary counter check and fix Darrick J. Wong

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=20180719174017.GJ4813@magnolia \
    --to=darrick.wong@oracle.com \
    --cc=hch@infradead.org \
    --cc=linux-xfs@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;
as well as URLs for NNTP newsgroup(s).