[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20201008044849.GA163423@kroah.com>
Date: Thu, 8 Oct 2020 06:48:49 +0200
From: Greg Kroah-Hartman <gregkh@...uxfoundation.org>
To: Tony Asleson <tasleson@...hat.com>
Cc: Christoph Hellwig <hch@...radead.org>, linux-scsi@...r.kernel.org,
linux-block@...r.kernel.org, linux-ide@...r.kernel.org,
Hannes Reinecke <hare@...e.de>, pmladek@...e.com,
David Lehman <dlehman@...hat.com>,
sergey.senozhatsky@...il.com, jbaron@...mai.com,
James.Bottomley@...senpartnership.com,
linux-kernel@...r.kernel.org, rafael@...nel.org,
martin.petersen@...cle.com, kbusch@...nel.org, axboe@...com,
sagi@...mberg.me, akpm@...ux-foundation.org, orson.zhai@...soc.com,
viro@...iv.linux.org.uk
Subject: Re: [v5 01/12] struct device: Add function callback durable_name
On Wed, Oct 07, 2020 at 03:10:17PM -0500, Tony Asleson wrote:
> On 10/1/20 6:48 AM, Greg Kroah-Hartman wrote:
> > On Wed, Sep 30, 2020 at 09:35:52AM -0500, Tony Asleson wrote:
> >> On 9/30/20 2:38 AM, Greg Kroah-Hartman wrote:
> >>> On Tue, Sep 29, 2020 at 05:04:32PM -0500, Tony Asleson wrote:
> >>>> I'm trying to figure out a way to positively identify which storage
> >>>> device an error belongs to over time.
> >>>
> >>> "over time" is not the kernel's responsibility.
> >>>
> >>> This comes up every 5 years or so. The kernel provides you, at runtime,
> >>> a mapping between a hardware device and a "logical" device. It can
> >>> provide information to userspace about this mapping, but once that
> >>> device goes away, the kernel is free to reuse that logical device again.
> >>>
> >>> If you want to track what logical devices match up to what physical
> >>> device, then do it in userspace, by parsing the log files.
> >>
> >> I don't understand why people think it's acceptable to ask user space to
> >> parse text that is subject to change.
> >
> > What text is changing? The format of of the prefix of dev_*() is well
> > known and has been stable for 15+ years now, right? What is difficult
> > in parsing it?
>
> Many of the storage layer messages are using printk, not dev_printk.
Ok, then stop right there. Fix that up. Don't try to route around the
standard way of displaying log messages by creating a totally different
way of doing things.
Just use the dev_*() calls, and all will be fine. Kernel log messages
are not "ABI" in that they have to be preserved in any specific way, so
adding a prefix to them as dev_*() does, will be fine.
thanks,
greg k-h
Powered by blists - more mailing lists