<feed xmlns='http://www.w3.org/2005/Atom'>
<title>linux.git/drivers/staging/mei, branch v3.0</title>
<subtitle>Linux kernel source tree</subtitle>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux.git/'/>
<entry>
<title>Staging: mei: fix suspend failure</title>
<updated>2011-06-27T21:19:21+00:00</updated>
<author>
<name>Tomas Winkler</name>
<email>tomas.winkler@intel.com</email>
</author>
<published>2011-06-13T13:39:31+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux.git/commit/?id=a534bb6eea72c0d082dd2faab85450e5554ba1c8'/>
<id>a534bb6eea72c0d082dd2faab85450e5554ba1c8</id>
<content type='text'>
wait_event_interruptible_timeout return value was wrongly used.
The remaining timeout was used as the error code.
This fix translated wait_event_interruptible_timeout return value
into error code that can be propagated.

[10291.674121] pci_pm_suspend(): mei_pci_suspend+0x0/0x8b [mei] returns 2500
It's thinkpad t400 with
00:03.0 Communication controller [0780]: Intel Corporation Mobile 4 Series Chipset MEI Controller [8086:2a44] (rev 07)

Reported-by: Arkadiusz Miskiewicz &lt;a.miskiewicz@gmail.com&gt;
Signed-off-by: Tomas Winkler &lt;tomas.winkler@intel.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@suse.de&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
wait_event_interruptible_timeout return value was wrongly used.
The remaining timeout was used as the error code.
This fix translated wait_event_interruptible_timeout return value
into error code that can be propagated.

[10291.674121] pci_pm_suspend(): mei_pci_suspend+0x0/0x8b [mei] returns 2500
It's thinkpad t400 with
00:03.0 Communication controller [0780]: Intel Corporation Mobile 4 Series Chipset MEI Controller [8086:2a44] (rev 07)

Reported-by: Arkadiusz Miskiewicz &lt;a.miskiewicz@gmail.com&gt;
Signed-off-by: Tomas Winkler &lt;tomas.winkler@intel.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@suse.de&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>Staging: mei: fix debug code</title>
<updated>2011-06-09T17:07:47+00:00</updated>
<author>
<name>Dan Carpenter</name>
<email>error27@gmail.com</email>
</author>
<published>2011-06-09T07:18:23+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux.git/commit/?id=8eb73c6c2675f708283822bd058ad1e416836ba2'/>
<id>8eb73c6c2675f708283822bd058ad1e416836ba2</id>
<content type='text'>
! has higher precedence than !=.  H_RDY is 8 and since neither 0 nor
1 are equal to 8 the original condition was always true.

Signed-off-by: Dan Carpenter &lt;error27@gmail.com&gt;
Acked-by: Tomas Winkler &lt;tomas.winkler@intel.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@suse.de&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
! has higher precedence than !=.  H_RDY is 8 and since neither 0 nor
1 are equal to 8 the original condition was always true.

Signed-off-by: Dan Carpenter &lt;error27@gmail.com&gt;
Acked-by: Tomas Winkler &lt;tomas.winkler@intel.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@suse.de&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>staging: fix mei build when PM is not enabled</title>
<updated>2011-05-19T22:34:31+00:00</updated>
<author>
<name>Randy Dunlap</name>
<email>randy.dunlap@oracle.com</email>
</author>
<published>2011-05-19T15:52:34+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux.git/commit/?id=2d9903621dbfa6524e7e98fded2fae31ef09f484'/>
<id>2d9903621dbfa6524e7e98fded2fae31ef09f484</id>
<content type='text'>
Fix mei build when CONFIG_PM is not enabled (i.e., fix typo):

drivers/staging/mei/main.c:1159: error: 'MEI_PM_OPS' undeclared here (not in a function)

Signed-off-by: Randy Dunlap &lt;randy.dunlap@oracle.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@suse.de&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Fix mei build when CONFIG_PM is not enabled (i.e., fix typo):

drivers/staging/mei/main.c:1159: error: 'MEI_PM_OPS' undeclared here (not in a function)

Signed-off-by: Randy Dunlap &lt;randy.dunlap@oracle.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@suse.de&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>staging/mei: add mei to staging Kbuild</title>
<updated>2011-05-18T15:30:59+00:00</updated>
<author>
<name>Oren Weil</name>
<email>oren.jer.weil@intel.com</email>
</author>
<published>2011-05-15T10:43:48+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux.git/commit/?id=6b8aae5aceb689ace3b8997393fe222b83956e53'/>
<id>6b8aae5aceb689ace3b8997393fe222b83956e53</id>
<content type='text'>
Add mei to Kconfig and Makefile in drivers/staging

Signed-off-by: Tomas Winkler &lt;tomas.winkler@intel.com&gt;
Signed-off-by: Itzhak Tzeel-Krupp &lt;itzhak.tzeel-krupp@intel.com&gt;
Signed-off-by: Oren Weil &lt;oren.jer.weil@intel.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@suse.de&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Add mei to Kconfig and Makefile in drivers/staging

Signed-off-by: Tomas Winkler &lt;tomas.winkler@intel.com&gt;
Signed-off-by: Itzhak Tzeel-Krupp &lt;itzhak.tzeel-krupp@intel.com&gt;
Signed-off-by: Oren Weil &lt;oren.jer.weil@intel.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@suse.de&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>staging/mei: AMT Watchdog</title>
<updated>2011-05-18T15:30:58+00:00</updated>
<author>
<name>Oren Weil</name>
<email>oren.jer.weil@intel.com</email>
</author>
<published>2011-05-15T10:43:47+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux.git/commit/?id=3ceb3e66a072b7a41ec065aeb120a38c05bc8b7a'/>
<id>3ceb3e66a072b7a41ec065aeb120a38c05bc8b7a</id>
<content type='text'>
code that open connection and invoke
heartbeats to the AMT Watchdog client/feature, if exists

Connect to WD Client, if exists Send Start WD Command.
Every 2 secs send heartbeats.
On System shutdown/suspends, send Stop WD command.

This is intermediate stage before moving this code to standalone watchdog
driver.

Signed-off-by: Tomas Winkler &lt;tomas.winkler@intel.com&gt;
Signed-off-by: Itzhak Tzeel-Krupp &lt;itzhak.tzeel-krupp@intel.com&gt;
Signed-off-by: Oren Weil &lt;oren.jer.weil@intel.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@suse.de&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
code that open connection and invoke
heartbeats to the AMT Watchdog client/feature, if exists

Connect to WD Client, if exists Send Start WD Command.
Every 2 secs send heartbeats.
On System shutdown/suspends, send Stop WD command.

This is intermediate stage before moving this code to standalone watchdog
driver.

Signed-off-by: Tomas Winkler &lt;tomas.winkler@intel.com&gt;
Signed-off-by: Itzhak Tzeel-Krupp &lt;itzhak.tzeel-krupp@intel.com&gt;
Signed-off-by: Oren Weil &lt;oren.jer.weil@intel.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@suse.de&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>staging/mei: mei.h defining user space interface</title>
<updated>2011-05-18T15:30:58+00:00</updated>
<author>
<name>Oren Weil</name>
<email>oren.jer.weil@intel.com</email>
</author>
<published>2011-05-15T10:43:46+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux.git/commit/?id=334aab1dba74161daa336f0c48333545fee01c99'/>
<id>334aab1dba74161daa336f0c48333545fee01c99</id>
<content type='text'>
define IOCTL_MEI_CONNECT_CLIENT and its associated structure

When the user wants to connect to a ME feature/client after
it open a file descriptor to the driver, he need to use Connect
IOCTL.

This IOCTL received a struct that contains a union of 2 other structs.

1st struct - Input Parameters:
	UUID - a predefine unique that identify the ME feature, this
		 id per feature is constant all over the chipsets
		 and versions.

2nd struct Output Parameters:
	MaxMessageLen - 	maximum message length that allowed
				to be send to the feature
	ProtocolVersion ME feature current protocol version.

Signed-off-by: Tomas Winkler &lt;tomas.winkler@intel.com&gt;
Signed-off-by: Itzhak Tzeel-Krupp &lt;itzhak.tzeel-krupp@intel.com&gt;
Signed-off-by: Oren Weil &lt;oren.jer.weil@intel.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@suse.de&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
define IOCTL_MEI_CONNECT_CLIENT and its associated structure

When the user wants to connect to a ME feature/client after
it open a file descriptor to the driver, he need to use Connect
IOCTL.

This IOCTL received a struct that contains a union of 2 other structs.

1st struct - Input Parameters:
	UUID - a predefine unique that identify the ME feature, this
		 id per feature is constant all over the chipsets
		 and versions.

2nd struct Output Parameters:
	MaxMessageLen - 	maximum message length that allowed
				to be send to the feature
	ProtocolVersion ME feature current protocol version.

Signed-off-by: Tomas Winkler &lt;tomas.winkler@intel.com&gt;
Signed-off-by: Itzhak Tzeel-Krupp &lt;itzhak.tzeel-krupp@intel.com&gt;
Signed-off-by: Oren Weil &lt;oren.jer.weil@intel.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@suse.de&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>staging/mei: Hardware and MEI driver internal struct definition</title>
<updated>2011-05-18T15:30:58+00:00</updated>
<author>
<name>Oren Weil</name>
<email>oren.jer.weil@intel.com</email>
</author>
<published>2011-05-15T10:43:45+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux.git/commit/?id=5a6003f25f83b47f38a0f52a6202f18013287996'/>
<id>5a6003f25f83b47f38a0f52a6202f18013287996</id>
<content type='text'>
define the MEI protocol msg structs and
HW registers, also define the MEI internal status and struct

Signed-off-by: Tomas Winkler &lt;tomas.winkler@intel.com&gt;
Signed-off-by: Itzhak Tzeel-Krupp &lt;itzhak.tzeel-krupp@intel.com&gt;
Signed-off-by: Oren Weil &lt;oren.jer.weil@intel.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@suse.de&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
define the MEI protocol msg structs and
HW registers, also define the MEI internal status and struct

Signed-off-by: Tomas Winkler &lt;tomas.winkler@intel.com&gt;
Signed-off-by: Itzhak Tzeel-Krupp &lt;itzhak.tzeel-krupp@intel.com&gt;
Signed-off-by: Oren Weil &lt;oren.jer.weil@intel.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@suse.de&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>staging/mei: MEI driver init flow.</title>
<updated>2011-05-18T15:30:57+00:00</updated>
<author>
<name>Oren Weil</name>
<email>oren.jer.weil@intel.com</email>
</author>
<published>2011-05-15T10:43:44+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux.git/commit/?id=91f01c6d45e634b98dd68439afdb04b674a95eee'/>
<id>91f01c6d45e634b98dd68439afdb04b674a95eee</id>
<content type='text'>
Init driver list and queue, MEI Hardware reset flow,
init of driver specific host client.

MEI Init/reset flow:
- Ack all waiting interrupts
- Hardware reset flow (Set Reset Bit, Generate Interrupt, Clear Reset Bit
  Generate Interrupt)
- Wait for ME Ready Bit (done in interrupt thread)
- Set ME Ready Bit (done in interrupt thread)
- Send Start request (done in interrupt thread)
- wait for answer
- Send Enumerate Clients request (done in interrupt thread)
- wait for answer
- Send Get Client property for each client request (done in interrupt thread)
- Wait for answers
- Init Done.

MEI Driver connect internally to 2 ME clients/features:
AMTHI and AMT watchdog.

Signed-off-by: Tomas Winkler &lt;tomas.winkler@intel.com&gt;
Signed-off-by: Itzhak Tzeel-Krupp &lt;itzhak.tzeel-krupp@intel.com&gt;
Signed-off-by: Oren Weil &lt;oren.jer.weil@intel.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@suse.de&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Init driver list and queue, MEI Hardware reset flow,
init of driver specific host client.

MEI Init/reset flow:
- Ack all waiting interrupts
- Hardware reset flow (Set Reset Bit, Generate Interrupt, Clear Reset Bit
  Generate Interrupt)
- Wait for ME Ready Bit (done in interrupt thread)
- Set ME Ready Bit (done in interrupt thread)
- Send Start request (done in interrupt thread)
- wait for answer
- Send Enumerate Clients request (done in interrupt thread)
- wait for answer
- Send Get Client property for each client request (done in interrupt thread)
- Wait for answers
- Init Done.

MEI Driver connect internally to 2 ME clients/features:
AMTHI and AMT watchdog.

Signed-off-by: Tomas Winkler &lt;tomas.winkler@intel.com&gt;
Signed-off-by: Itzhak Tzeel-Krupp &lt;itzhak.tzeel-krupp@intel.com&gt;
Signed-off-by: Oren Weil &lt;oren.jer.weil@intel.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@suse.de&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>staging/mei: MEI link layer</title>
<updated>2011-05-18T15:30:57+00:00</updated>
<author>
<name>Oren Weil</name>
<email>oren.jer.weil@intel.com</email>
</author>
<published>2011-05-15T10:43:43+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux.git/commit/?id=3ce72726c6790ffcf492c0689e5ee3a758bfb00e'/>
<id>3ce72726c6790ffcf492c0689e5ee3a758bfb00e</id>
<content type='text'>
Implementation of the communication between host and ME.
connect/disconnect to/from a client, send MEI message,
read MEI message, flow control handling.

Each MEI message has mei_msg_hdr followed by a payload.
Driver is oblivious the payload.

ME Address/ID 	- This is the logical address of the ME
		feature/client of that message.
Host Address/ID	- This is the logical address of the Host
		  client of that message
Length 		- This is the Length of message payload in bytes
Reserved 	-  reserved for future use.
Message Complete - This bit is used to indicative that
		this is the last message of multi message
		MEI transfer of a client message that is larger
		then the MEI circular buffer.
Payload		- Message payload (data) up to 512bytes

The HW data registers are consist two circular buffers,
one for data from ME and other data from Host application.
Each buffer has two pointers, read_ptr (H_CBRP)
and write_ptr (H_CBWP).
The buffers size is defined by depth value that exists
in the status registers (H_CBD and ME_CBD_HRA).
Every read from ME circular buffer cause read_ptr++
Every write to the Host  circular buffer write_ptr++

Flow control MEI message that ME and MEI Driver use to notify
each other that a ME feature/client or Host client buffer is ready
to receive data.

Signed-off-by: Tomas Winkler &lt;tomas.winkler@intel.com&gt;
Signed-off-by: Itzhak Tzeel-Krupp &lt;itzhak.tzeel-krupp@intel.com&gt;
Signed-off-by: Oren Weil &lt;oren.jer.weil@intel.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@suse.de&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Implementation of the communication between host and ME.
connect/disconnect to/from a client, send MEI message,
read MEI message, flow control handling.

Each MEI message has mei_msg_hdr followed by a payload.
Driver is oblivious the payload.

ME Address/ID 	- This is the logical address of the ME
		feature/client of that message.
Host Address/ID	- This is the logical address of the Host
		  client of that message
Length 		- This is the Length of message payload in bytes
Reserved 	-  reserved for future use.
Message Complete - This bit is used to indicative that
		this is the last message of multi message
		MEI transfer of a client message that is larger
		then the MEI circular buffer.
Payload		- Message payload (data) up to 512bytes

The HW data registers are consist two circular buffers,
one for data from ME and other data from Host application.
Each buffer has two pointers, read_ptr (H_CBRP)
and write_ptr (H_CBWP).
The buffers size is defined by depth value that exists
in the status registers (H_CBD and ME_CBD_HRA).
Every read from ME circular buffer cause read_ptr++
Every write to the Host  circular buffer write_ptr++

Flow control MEI message that ME and MEI Driver use to notify
each other that a ME feature/client or Host client buffer is ready
to receive data.

Signed-off-by: Tomas Winkler &lt;tomas.winkler@intel.com&gt;
Signed-off-by: Itzhak Tzeel-Krupp &lt;itzhak.tzeel-krupp@intel.com&gt;
Signed-off-by: Oren Weil &lt;oren.jer.weil@intel.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@suse.de&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>staging/mei: Interrupt handling.</title>
<updated>2011-05-18T15:30:56+00:00</updated>
<author>
<name>Oren Weil</name>
<email>oren.jer.weil@intel.com</email>
</author>
<published>2011-05-15T10:43:42+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux.git/commit/?id=fb7d879f3b15056bf4f818e56b368ce76de2d5f3'/>
<id>fb7d879f3b15056bf4f818e56b368ce76de2d5f3</id>
<content type='text'>
ISR and interrupt thread for handling incoming data.
e.g. read bus message, read client message, handle reset requests.

quick handler:
	As MEI may share interrupt with GFX and/or USB
	the HW register need to be checked and acknowledged.

thread handler:
	Check if HW has data for read.
	Write data to HW if possible.
	May init reset flow on error

there can be two types of messages:
1) bus messages:
	Management messages between MEI Driver and ME e.g.
		Connect request/response,
		Disconnect request/response
		Enum clients request/response
		Flow control request/response
	those message are indicated by
	ME Address/ID == 0 &amp;&amp; Host Address/ID == 0

2) feature/client messages:
	message that are sends between ME Feature/Client and
	an application, the struct of the message is defined
	by the ME Feature Protocol (e.g. APF Protocol, AMTHI Protocol)
	those message are indicated by
	ME Address/ID != 0 &amp;&amp; Host Address/ID != 0

MEI Initialization state machine is also managed by this patch.
After MEI Reset is preform:
	Send Start request
		wait for answer
	Send Enumerate Clients request
		wait for answer
	Send Get Client property for each client request
		wait for answers
	Init Done.

Signed-off-by: Tomas Winkler &lt;tomas.winkler@intel.com&gt;
Signed-off-by: Itzhak Tzeel-Krupp &lt;itzhak.tzeel-krupp@intel.com&gt;
Signed-off-by: Oren Weil &lt;oren.jer.weil@intel.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@suse.de&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
ISR and interrupt thread for handling incoming data.
e.g. read bus message, read client message, handle reset requests.

quick handler:
	As MEI may share interrupt with GFX and/or USB
	the HW register need to be checked and acknowledged.

thread handler:
	Check if HW has data for read.
	Write data to HW if possible.
	May init reset flow on error

there can be two types of messages:
1) bus messages:
	Management messages between MEI Driver and ME e.g.
		Connect request/response,
		Disconnect request/response
		Enum clients request/response
		Flow control request/response
	those message are indicated by
	ME Address/ID == 0 &amp;&amp; Host Address/ID == 0

2) feature/client messages:
	message that are sends between ME Feature/Client and
	an application, the struct of the message is defined
	by the ME Feature Protocol (e.g. APF Protocol, AMTHI Protocol)
	those message are indicated by
	ME Address/ID != 0 &amp;&amp; Host Address/ID != 0

MEI Initialization state machine is also managed by this patch.
After MEI Reset is preform:
	Send Start request
		wait for answer
	Send Enumerate Clients request
		wait for answer
	Send Get Client property for each client request
		wait for answers
	Init Done.

Signed-off-by: Tomas Winkler &lt;tomas.winkler@intel.com&gt;
Signed-off-by: Itzhak Tzeel-Krupp &lt;itzhak.tzeel-krupp@intel.com&gt;
Signed-off-by: Oren Weil &lt;oren.jer.weil@intel.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@suse.de&gt;
</pre>
</div>
</content>
</entry>
</feed>
