public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
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>,
	"Usyskin, Alexander" <alexander.usyskin@intel.com>
Subject: Re: [char-misc-next 3/3] mei: add WPT second mei interface
Date: Tue, 27 May 2014 15:06:30 -0700	[thread overview]
Message-ID: <20140527220630.GA7924@kroah.com> (raw)
In-Reply-To: <5B8DA87D05A7694D9FA63FD143655C1B1AFFBCDC@HASMSX106.ger.corp.intel.com>

On Tue, May 27, 2014 at 09:42:19PM +0000, Winkler, Tomas wrote:
> > > +/* PCH devices MEI 2 interface */
> > > +const struct mei_cfg mei_me_pch_2_cfg = {
> > > +	MEI_CFG_PCH_HFS,
> > > +	.mei_id = 1
> > 
> > That's going to be a recipe for disaster.  Have the MEI core allocate
> > the id numbers as things are registered, don't have the individual
> > drivers create their id.
> 
> I'm don't think can ensure the enumeration order.

You should not be relying on the order to get anything right.

> This is per device not per driver configuration structure.
> Each pci device is actually just  another head to one MEI device but heads are not equal the name/id matters
> Yes I assume it looks odd at the first glance, anyhow we are open to any reasonable suggestions 

Just dynamically allocate the numbers like all other subsystems do?

Then userspace can open the device nodes it cares about, it should be
able to somehow tell what device is what somehow, right?  If not, you
are doing something wrong with the interface as you can't rely on minor
numbers.

thanks,

greg k-h

  reply	other threads:[~2014-05-27 22:02 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-05-13  8:21 [char-misc-next 0/3] mei support more devices Tomas Winkler
2014-05-13  8:21 ` [char-misc-next 1/3] mei: move from misc to char device Tomas Winkler
2014-05-27 21:20   ` Greg KH
2014-05-13  8:22 ` [char-misc-next 2/3] mei: sysfs: add Documentation mei class attributes Tomas Winkler
2014-05-13  8:22 ` [char-misc-next 3/3] mei: add WPT second mei interface Tomas Winkler
2014-05-27 21:22   ` Greg KH
2014-05-27 21:42     ` Winkler, Tomas
2014-05-27 22:06       ` Greg KH [this message]
2014-05-27 23:47         ` Winkler, Tomas
2014-05-28  0:35           ` Greg KH

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=20140527220630.GA7924@kroah.com \
    --to=gregkh@linuxfoundation.org \
    --cc=alexander.usyskin@intel.com \
    --cc=arnd@arndb.de \
    --cc=linux-kernel@vger.kernel.org \
    --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