Re: [char-misc-next 08/11] mei: nfc: Initial nfc implementation

From: Samuel Ortiz
Date: Thu Feb 07 2013 - 17:41:45 EST


Hi Arnd,

On Thu, Feb 07, 2013 at 10:26:42PM +0000, Arnd Bergmann wrote:
> On Thursday 07 February 2013, Tomas Winkler wrote:
> >
> > From: Samuel Ortiz <sameo@xxxxxxxxxxxxxxx>
> >
> > NFC ME client is exported through mei bus to be consumed by the
> > NFC subsystem.
> >
> > NFC is represented by two mei clients: An info one and the actual
> > NFC one. In order for correct connection we first need to retrieve the
> > firmware information from the info client.
> >
> > Signed-off-by: Samuel Ortiz <sameo@xxxxxxxxxxxxxxx>
> > Signed-off-by: Tomas Winkler <tomas.winkler@xxxxxxxxx>
>
> Shouldn't this be moved to the drivers/nfc directory? Generally speaking,
> all drivers nowadays tend to live in the directories of the subsystems
> they are implementing support for, not the subsystems that they are
> implemented with.
This is a bit on the edge: This part of the MEI bus code doesn't implement
support for any NFC chipset in particular but for the MEI specific commands to
send and receive NFC HCI payloads.
So the drivers under driver/nfc call into the MEI bus I/O API which then call
this code to encapsulate the HCI payload into MEI (HECI) commands. The
microread driver in my nfc-next git.kernel.org tree uses the MEI bus API for
example.
Moreover this code actually talks to the ME at init time to understand which
exact NFC chipset is living behind the ME and add the correct device string to
the bus. So it really needs to access the MEI internal API to do so.

Cheers,
Samuel.

--
Intel Open Source Technology Centre
http://oss.intel.com/
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/