lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Date:	Thu, 1 Aug 2013 15:32:40 +0800
From:	Greg KH <gregkh@...uxfoundation.org>
To:	"Winkler, Tomas" <tomas.winkler@...el.com>
Cc:	"arnd@...db.de" <arnd@...db.de>,
	"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
	"Ovsyanikov, Natalia" <natalia.ovsyanikov@...el.com>
Subject: Re: [char-misc-next 2/3] mei: adding sysfs fw_status attribute

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
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ