Re: [RFC 00/10] Introduce In Field Scan driver

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Mon, Mar 14, 2022 at 04:10:39PM -0700, Luck, Tony wrote:
> On Tue, Mar 01, 2022 at 09:14:26PM +0100, Greg KH wrote:
> > On Tue, Mar 01, 2022 at 09:10:20PM +0100, Greg KH wrote:
> > > On Tue, Mar 01, 2022 at 11:54:47AM -0800, Jithu Joseph wrote:
> > > > Note to Maintainers:
> > > > Requesting x86 Maintainers to take a look at patch01 as it
> > > > touches arch/x86 portion of the kernel. Also would like to guide them
> > > > to patch07 which sets up hotplug notifiers and creates kthreads.
> > > > 
> > > > Patch 2/10 - Adds Documentation. Requesting Documentation maintainer to review it.
> > > > 
> > > > Requesting Greg KH to review the sysfs changes added by patch08.
> > > 
> > > "RFC" means you are not comfortable submitting the changes yet, so you
> > > don't need my review at this point in time.  Become confident in your
> > > changes before asking for others to review the code please.
> > 
> > Hint, it needs work, sysfs_emit() for one thing, lack of reference
> > counting on your cpu objects is another...
> 
> Greg,
> 
> Thanks for the comments. They triggered a bunch of internal
> re-thinking of the interface.  One idea that has some traction
> (Credit/Blame: Dan Williams) is to:

First off, I did not pay attention to this thread at all, given that the
very basics of this patch series had such obvious problems.  I only saw
the contents, not the context in which you wanted to make these changes.

So I have no real thoughts as to what your design should be, as I have
no idea what it is you even want to accomplish at all.

That being said, I do have one comment:

> 1) Don't put anything in /sys/devices/system/cpu/*
> 2) Driver creates some info/control files in its own
>    corner of /sys/devices/.../ifs
> 3) No per-cpu files ... run a test with:
>    # echo ${cpu} > /sys/devices/.../ifs/run_test
> 4) No test result files.
>    When tests complete they report using uevents
> 
> Using uevent to report means that we can easily have
> mutiple parts to the result (pass/fail/incomplete status, as well
> as diagnostic details about the reason for the failure,
> or why the test was not completed).
> 
> This seems a novel use of uevent ... is it OK, or is is abuse?

Don't create "novel" uses of uevents.  They are there to express a
change in state of a device so that userspace can then go and do
something with that information.  If that pattern fits here, wonderful.

I doubt you can report "test results" via a uevent in a way that the
current uevent states and messages would properly convey, but hey, maybe
I'm wrong.

good luck!

greg k-h



[Index of Archives]     [Kernel Newbies]     [Security]     [Netfilter]     [Bugtraq]     [Linux FS]     [Yosemite Forum]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Samba]     [Video 4 Linux]     [Device Mapper]     [Linux Resources]

  Powered by Linux