Re: [PATCH v2] drivers/virt/vSMP: new driver
From: Czerwacki, Eial
Date: Wed Sep 07 2022 - 02:31:05 EST
>On Tue, Sep 06, 2022 at 03:50:37PM +0200, Greg Kroah-Hartman wrote:
>> On Thu, Aug 25, 2022 at 06:24:02AM +0000, Czerwacki, Eial wrote:
>> > --- /dev/null
>> > +++ b/drivers/virt/vsmp/Kconfig
>> > @@ -0,0 +1,11 @@
>> > +# SPDX-License-Identifier: GPL-2.0-only
>> > +config VSMP
>> > + tristate "vSMP Guest Support"
>> > + depends on SYS_HYPERVISOR && X86_64 && PCI
>> > + help
>> > + Support for vSMP Guest Driver.
>> > +
>> > + This driver allows information gathering of data from the vSMP hypervisor when
>> > + running on top of a vSMP-based hypervisor.
>> > +
>> > + If unsure, say no.
>>
>> In wanting to test this out, I tried it but this depends line is wrong,
>> you have to set SYS_HYPERVISOR, you can not depend on it otherwise your
>> code will never be selected :(
>
>Ok, based on the conversation happening on the staging list, I took a
>look at the code here again and have deleted a ton of it and added a
>framework for you to add some sysfs files in the hypervisor location,
>but this is NOT where the device/board files go, that's a different
>add-on patch on top of this.
>
>Here's an updated patch, much smaller, and hopefully simpler to
>understand and follow. I didn't touch the Documentation/ABI/ entry, but
>if you run this you should see 4 sysfs files, "version1-3" that just
>print a single number, and "version_length" that does some i/o and gets
>the length that you wanted to use in the past to show how to tie this
>into the device-specific information (and not have any static
>information.)
>
>Feel free to build on this for your next submission. And if you have
>any questions about this, please let me know.
>
>Note, I have only built this code, not tested it, for obvious reasons :)
>
>thanks,
>
oh wow! thanks a lot!
I'll try it and of course will learn from it
Eial