From: Greg KH <gregkh@linuxfoundation.org>
To: "Winkler, Tomas" <tomas.winkler@intel.com>
Cc: "arnd@arndb.de" <arnd@arndb.de>,
"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
"Ovsyanikov, Natalia" <natalia.ovsyanikov@intel.com>
Subject: Re: [char-misc-next 2/3] mei: adding sysfs fw_status attribute
Date: Thu, 1 Aug 2013 15:32:40 +0800 [thread overview]
Message-ID: <20130801073240.GA5419@kroah.com> (raw)
In-Reply-To: <5B8DA87D05A7694D9FA63FD143655C1B1AE7AC90@HASMSX106.ger.corp.intel.com>
On Thu, Aug 01, 2013 at 07:21:30AM +0000, Winkler, Tomas wrote:
> >
> > On Mon, Jul 29, 2013 at 11:08:52PM +0000, Winkler, Tomas wrote:
> > > How do I add new device specific sysfs in non-race way if my entry
> > > point is the pci probe function.
> >
> > You do it in the device creation for the device you add below the PCI device
> > in sysfs, by setting the groups field in the device.
> >
> > You don't create files in the sysfs directory for the PCI device itself, those are
> > owned by the PCI bus core.
> >
> > This is why you are your own "bus" here, use it :)
>
> > If you still have questions, how about we take it to code, post what you have,
> > and I'll see what needs to be changed.
> >
> > hope this helps,
>
> Right but this is not related to mei_cl_bus, which is an abstraction
> in MEI protocol level, I wanted to augment the pci device.
Then do that in the pci core :)
> We'd I've tried to expose is the FW status register from pci config
> space, (I' know the pci config space Is already exposed through syfs),
> the issue is that the offset of the registers changes between
> different HW, so I wished that there Is a sysfs entry called fw_status
> always points to the correct offset. An application that tries to
> query fw status can be oblivious to underlying HW SKU.
>
> I guess that sysfs is not good interface for that now. I will just
> resend the two other patches w/o sysfs
No, you would be adding "random" files to a pci device in sysfs, how
would userspace ever know about something like this?
If this is a PCI-standard thing, then add it to the PCI core please.
Otherwise, it belongs on your "controller" as it is a child of the PCI
device, and should be able to live there just fine.
thanks,
greg k-h
next prev parent reply other threads:[~2013-08-01 7:37 UTC|newest]
Thread overview: 17+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-07-24 15:41 [char-misc-next 0/3] mei: export fw status register through sysfs Tomas Winkler
2013-07-24 15:41 ` [char-misc-next 1/3] mei me: add handler for me_hw_ops fw_status Tomas Winkler
2013-07-24 15:41 ` [char-misc-next 2/3] mei: adding sysfs fw_status attribute Tomas Winkler
2013-07-24 16:00 ` Greg KH
2013-07-24 16:20 ` Winkler, Tomas
2013-07-24 16:26 ` Greg KH
2013-07-24 18:04 ` Winkler, Tomas
2013-07-24 20:29 ` Greg KH
2013-07-28 8:48 ` Winkler, Tomas
2013-07-28 15:31 ` Greg KH
2013-07-29 22:27 ` Winkler, Tomas
2013-07-29 22:38 ` Greg KH
2013-07-29 23:08 ` Winkler, Tomas
2013-07-29 23:17 ` Greg KH
2013-08-01 7:21 ` Winkler, Tomas
2013-08-01 7:32 ` Greg KH [this message]
2013-07-24 15:41 ` [char-misc-next 3/3] mei: update ABI for fw_status register exported through sysfs Tomas Winkler
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=20130801073240.GA5419@kroah.com \
--to=gregkh@linuxfoundation.org \
--cc=arnd@arndb.de \
--cc=linux-kernel@vger.kernel.org \
--cc=natalia.ovsyanikov@intel.com \
--cc=tomas.winkler@intel.com \
/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