linux-fsdevel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Christoph Hellwig <hch@infradead.org>
To: "Darrick J. Wong" <djwong@kernel.org>
Cc: Sukrit Bhatnagar <Sukrit.Bhatnagar@sony.com>,
	"Rafael J. Wysocki" <rafael@kernel.org>,
	Pavel Machek <pavel@ucw.cz>,
	Christian Brauner <brauner@kernel.org>,
	Andrew Morton <akpm@linux-foundation.org>,
	linux-xfs@vger.kernel.org, linux-pm@vger.kernel.org,
	linux-fsdevel@vger.kernel.org, linux-kernel@vger.kernel.org,
	linux-mm@kvack.org
Subject: Re: [PATCH 2/2] mm: swap: print starting physical block offset in swapon
Date: Wed, 22 May 2024 07:59:35 -0700	[thread overview]
Message-ID: <Zk4IV53Q_fyx9Vx4@infradead.org> (raw)
In-Reply-To: <20240522145637.GV25518@frogsfrogsfrogs>

On Wed, May 22, 2024 at 07:56:37AM -0700, Darrick J. Wong wrote:
> On Wed, May 22, 2024 at 04:46:58PM +0900, Sukrit Bhatnagar wrote:
> > When a swapfile is created for hibernation purposes, we always need
> > the starting physical block offset, which is usually determined using
> > userspace commands such as filefrag.
> 
> If you always need this value, then shouldn't it be exported via sysfs
> or somewhere so that you can always get to it?  The kernel ringbuffer
> can overwrite log messages, swapfiles can get disabled, etc.

Scraping a block address from anything is just broken.

Wher is the code using this?  It needs a proper kernel interface.

Same about the warning crap in patch 1.

  reply	other threads:[~2024-05-22 14:59 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-05-22  7:46 [PATCH 0/2] Improve dmesg output for swapfile+hibernation Sukrit Bhatnagar
2024-05-22  7:46 ` [PATCH 1/2] iomap: swap: print warning for unaligned swapfile Sukrit Bhatnagar
2024-05-22 18:02   ` Chris Li
2024-05-27 10:54     ` Sukrit.Bhatnagar
2024-05-22  7:46 ` [PATCH 2/2] mm: swap: print starting physical block offset in swapon Sukrit Bhatnagar
2024-05-22 14:56   ` Darrick J. Wong
2024-05-22 14:59     ` Christoph Hellwig [this message]
2024-05-27 11:02     ` Sukrit.Bhatnagar
2024-05-23 19:45 ` [PATCH 0/2] Improve dmesg output for swapfile+hibernation Pavel Machek
2024-05-27 11:06   ` Sukrit.Bhatnagar
2024-05-27 11:20     ` Christoph Hellwig
2024-05-27 12:51       ` Sukrit.Bhatnagar
2024-05-27 12:58         ` Christoph Hellwig
2024-05-31 14:15           ` Sukrit.Bhatnagar

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=Zk4IV53Q_fyx9Vx4@infradead.org \
    --to=hch@infradead.org \
    --cc=Sukrit.Bhatnagar@sony.com \
    --cc=akpm@linux-foundation.org \
    --cc=brauner@kernel.org \
    --cc=djwong@kernel.org \
    --cc=linux-fsdevel@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mm@kvack.org \
    --cc=linux-pm@vger.kernel.org \
    --cc=linux-xfs@vger.kernel.org \
    --cc=pavel@ucw.cz \
    --cc=rafael@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).