<feed xmlns='http://www.w3.org/2005/Atom'>
<title>linux-dev/drivers/hid/intel-ish-hid, branch master</title>
<subtitle>Linux kernel development work - see feature branches</subtitle>
<id>https://git.zx2c4.com/linux-dev/atom/drivers/hid/intel-ish-hid?h=master</id>
<link rel='self' href='https://git.zx2c4.com/linux-dev/atom/drivers/hid/intel-ish-hid?h=master'/>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/linux-dev/'/>
<updated>2022-08-25T13:03:15Z</updated>
<entry>
<title>HID: intel-ish-hid: ipc: Add Meteor Lake PCI device ID</title>
<updated>2022-08-25T13:03:15Z</updated>
<author>
<name>Even Xu</name>
<email>even.xu@intel.com</email>
</author>
<published>2022-08-23T01:10:59Z</published>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/linux-dev/commit/?id=467249a7dff68451868ca79696aef69764193a8a'/>
<id>urn:sha1:467249a7dff68451868ca79696aef69764193a8a</id>
<content type='text'>
Add device ID of Meteor Lake P into ishtp support list.

Signed-off-by: Even Xu &lt;even.xu@intel.com&gt;
Acked-by: Srinivas Pandruvada &lt;srinivas.pandruvada@linux.intel.com&gt;
Signed-off-by: Jiri Kosina &lt;jkosina@suse.cz&gt;
</content>
</entry>
<entry>
<title>hid: intel-ish-hid: ishtp: Fix ishtp client sending disordered message</title>
<updated>2022-08-25T09:35:44Z</updated>
<author>
<name>Even Xu</name>
<email>even.xu@intel.com</email>
</author>
<published>2022-08-04T00:59:19Z</published>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/linux-dev/commit/?id=e1fa076706209cc447d7a2abd0843a18277e5ef7'/>
<id>urn:sha1:e1fa076706209cc447d7a2abd0843a18277e5ef7</id>
<content type='text'>
There is a timing issue captured during ishtp client sending stress tests.
It was observed during stress tests that ISH firmware is getting out of
ordered messages. This is a rare scenario as the current set of ISH client
drivers don't send much data to firmware. But this may not be the case
going forward.

When message size is bigger than IPC MTU, ishtp splits the message into
fragments and uses serialized async method to send message fragments.
The call stack:
ishtp_cl_send_msg_ipc-&gt;ipc_tx_callback(first fregment)-&gt;
ishtp_send_msg(with callback)-&gt;write_ipc_to_queue-&gt;
write_ipc_from_queue-&gt;callback-&gt;ipc_tx_callback(next fregment)......

When an ipc write complete interrupt is received, driver also calls
write_ipc_from_queue-&gt;ipc_tx_callback in ISR to start sending of next fragment.

Through ipc_tx_callback uses spin_lock to protect message splitting, as the
serialized sending method will call back to ipc_tx_callback again, so it doesn't
put sending under spin_lock, it causes driver cannot guarantee all fragments
be sent in order.

Considering this scenario:
ipc_tx_callback just finished a fragment splitting, and not call ishtp_send_msg
yet, there is a write complete interrupt happens, then ISR-&gt;write_ipc_from_queue
-&gt;ipc_tx_callback-&gt;ishtp_send_msg-&gt;write_ipc_to_queue......

Because ISR has higher exec priority than normal thread, this causes the new
fragment be sent out before previous fragment. This disordered message causes
invalid message to firmware.

The solution is, to send fragments synchronously:
Use ishtp_write_message writing fragments into tx queue directly one by one,
instead of ishtp_send_msg only writing one fragment with completion callback.
As no completion callback be used, so change ipc_tx_callback to ipc_tx_send.

Signed-off-by: Even Xu &lt;even.xu@intel.com&gt;
Acked-by: Srinivas Pandruvada &lt;srinivas.pandruvada@intel.com&gt;
Signed-off-by: Jiri Kosina &lt;jkosina@suse.cz&gt;
</content>
</entry>
<entry>
<title>HID: ishtp-hid-clientHID: ishtp-hid-client: Fix comment typo</title>
<updated>2022-08-25T09:35:44Z</updated>
<author>
<name>Jason Wang</name>
<email>wangborong@cdjrlc.com</email>
</author>
<published>2022-08-04T00:58:14Z</published>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/linux-dev/commit/?id=94553f8a218540d676efbf3f7827ed493d1057cf'/>
<id>urn:sha1:94553f8a218540d676efbf3f7827ed493d1057cf</id>
<content type='text'>
The double `like' is duplicated in the comment, remove one.

Signed-off-by: Jason Wang &lt;wangborong@cdjrlc.com&gt;
Signed-off-by: Jiri Kosina &lt;jkosina@suse.cz&gt;
</content>
</entry>
<entry>
<title>ID: intel-ish-hid: hid-client: drop unexpected word "the" in the comments</title>
<updated>2022-07-21T09:56:10Z</updated>
<author>
<name>Jiang Jian</name>
<email>jiangjian@cdjrlc.com</email>
</author>
<published>2022-06-21T12:27:51Z</published>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/linux-dev/commit/?id=92443a9ff1208cdcd932273e141d1ec6bdfb3c0c'/>
<id>urn:sha1:92443a9ff1208cdcd932273e141d1ec6bdfb3c0c</id>
<content type='text'>
there is an unexpected word "the" in the comments that need to be dropped

file: drivers/hid/intel-ish-hid/ishtp-hid-client.c
line: 331
 * @device: Pointer to the the ishtp client device for which this message
changed to
 * @device: Pointer to the ishtp client device for which this message

Signed-off-by: Jiang Jian &lt;jiangjian@cdjrlc.com&gt;
Acked-by: Srinivas Pandruvada &lt;srinivas.pandruvada@linux.intel.com&gt;
Signed-off-by: Jiri Kosina &lt;jkosina@suse.cz&gt;
</content>
</entry>
<entry>
<title>HID: intel-ish-hid: ipc: use time_before to replace "jiffies &lt; a"</title>
<updated>2022-06-08T11:05:45Z</updated>
<author>
<name>Li Qiong</name>
<email>liqiong@nfschina.com</email>
</author>
<published>2022-06-06T13:47:50Z</published>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/linux-dev/commit/?id=15b28156029465e594b462e6dad459a737028697'/>
<id>urn:sha1:15b28156029465e594b462e6dad459a737028697</id>
<content type='text'>
time_before deals with timer wrapping correctly.

Signed-off-by: Li Qiong &lt;liqiong@nfschina.com&gt;
Acked-by: Srinivas Pandruvada &lt;srinivas.pandruvada@linux.intel.com&gt;
Signed-off-by: Jiri Kosina &lt;jkosina@suse.cz&gt;
</content>
</entry>
<entry>
<title>HID: intel-ish-hid: ipc: add ADL and RPL device id</title>
<updated>2022-03-30T15:20:23Z</updated>
<author>
<name>Even Xu</name>
<email>even.xu@intel.com</email>
</author>
<published>2022-03-30T14:27:45Z</published>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/linux-dev/commit/?id=10ec4afd238d82a4840491a46484d2311db39500'/>
<id>urn:sha1:10ec4afd238d82a4840491a46484d2311db39500</id>
<content type='text'>
Add device IDs of Alder Lake N and Raptor Lake S into ishtp support list.

Signed-off-by: Even Xu &lt;even.xu@intel.com&gt;
Acked-by: Srinivas Pandruvada &lt;srinivas.pandruvada@linux.intel.com&gt;
Signed-off-by: Jiri Kosina &lt;jkosina@suse.cz&gt;
</content>
</entry>
<entry>
<title>HID: intel-ish-hid: Use dma_alloc_coherent for firmware update</title>
<updated>2022-03-14T09:39:04Z</updated>
<author>
<name>Gwendal Grignou</name>
<email>gwendal@chromium.org</email>
</author>
<published>2022-02-09T05:09:47Z</published>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/linux-dev/commit/?id=f97ec5d75e9261a5da78dc28a8955b7cc0c4468b'/>
<id>urn:sha1:f97ec5d75e9261a5da78dc28a8955b7cc0c4468b</id>
<content type='text'>
Allocating memory with kmalloc and GPF_DMA32 is not allowed, the
allocator will ignore the attribute.

Instead, use dma_alloc_coherent() API as we allocate a small amount of
memory to transfer firmware fragment to the ISH.

On Arcada chromebook, after the patch the warning:
"Unexpected gfp: 0x4 (GFP_DMA32). Fixing up to gfp: 0xcc0 (GFP_KERNEL).  Fix your code!"
is gone. The ISH firmware is loaded properly and we can interact with
the ISH:
&gt; ectool  --name cros_ish version
...
Build info:    arcada_ish_v2.0.3661+3c1a1c1ae0 2022-02-08 05:37:47 @localhost
Tool version:  v2.0.12300-900b03ec7f 2022-02-08 10:01:48 @localhost

Fixes: commit 91b228107da3 ("HID: intel-ish-hid: ISH firmware loader client driver")
Signed-off-by: Gwendal Grignou &lt;gwendal@chromium.org&gt;
Acked-by: Srinivas Pandruvada &lt;srinivas.pandruvada@linux.intel.com&gt;
Cc: stable@vger.kernel.org
Signed-off-by: Jiri Kosina &lt;jkosina@suse.cz&gt;
</content>
</entry>
<entry>
<title>HID: intel-ish-hid: ishtp-fw-loader: Fix a kernel-doc formatting issue</title>
<updated>2022-01-06T14:39:43Z</updated>
<author>
<name>Yang Li</name>
<email>yang.lee@linux.alibaba.com</email>
</author>
<published>2021-12-16T04:01:46Z</published>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/linux-dev/commit/?id=98b6b62cd5569a158868b62dc7866b5aae5d9a38'/>
<id>urn:sha1:98b6b62cd5569a158868b62dc7866b5aae5d9a38</id>
<content type='text'>
This function had kernel-doc that not used a hash to separate
the function name from the one line description.

The warning was found by running scripts/kernel-doc, which is
caused by using 'make W=1'.

drivers/hid/intel-ish-hid/ishtp-fw-loader.c:271: warning: This comment
starts with '/**', but isn't a kernel-doc comment. Refer
Documentation/doc-guide/kernel-doc.rst

Reported-by: Abaci Robot &lt;abaci@linux.alibaba.com&gt;
Signed-off-by: Yang Li &lt;yang.lee@linux.alibaba.com&gt;
Signed-off-by: Jiri Kosina &lt;jkosina@suse.cz&gt;
</content>
</entry>
<entry>
<title>HID: intel-ish-hid: ipc: Specify no cache snooping on TGL and ADL</title>
<updated>2022-01-06T14:39:43Z</updated>
<author>
<name>Ye Xiang</name>
<email>xiang.ye@intel.com</email>
</author>
<published>2021-12-17T07:45:41Z</published>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/linux-dev/commit/?id=bcad6d1bd9177740176ea79f6d0fc9f5b07e0c43'/>
<id>urn:sha1:bcad6d1bd9177740176ea79f6d0fc9f5b07e0c43</id>
<content type='text'>
Specify that both TGL and ADL don't support DMA cache snooping.

Signed-off-by: Ye Xiang &lt;xiang.ye@intel.com&gt;
Signed-off-by: Jiri Kosina &lt;jkosina@suse.cz&gt;
</content>
</entry>
<entry>
<title>HID: intel-ish-hid: ipc: only enable IRQ wakeup when requested</title>
<updated>2021-12-03T08:32:49Z</updated>
<author>
<name>Thomas Weißschuh</name>
<email>linux@weissschuh.net</email>
</author>
<published>2021-11-30T06:01:17Z</published>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/linux-dev/commit/?id=086e81f6b90e41a07a1a885bb11e93daa6915747'/>
<id>urn:sha1:086e81f6b90e41a07a1a885bb11e93daa6915747</id>
<content type='text'>
Fixes spurious wakeups from s0ix on Lenovo ThinkPad X1 Cargon Gen 9 on
lid close.

These wakeups are generated by interrupts from the ISH on changes to the
lid status.

By disabling the wake IRQ from the ISH we inhibit these spurious
wakeups while keeping the resume from LID open through the ACPI
interrupt.

Reports on the Lenovo forums indicate that Lenovo ThinkPad X1 Yoga Gen6
is also affected.

Fixes: ae02e5d40d5f ("HID: intel-ish-hid: ipc layer")
BugLink: https://bugzilla.kernel.org/show_bug.cgi?id=214855
Signed-off-by: Thomas Weißschuh &lt;linux@weissschuh.net&gt;
Acked-by: Srinivas Pandruvada &lt;srinivas.pandruvada@linux.intel.com&gt;
Signed-off-by: Benjamin Tissoires &lt;benjamin.tissoires@redhat.com&gt;
Link: https://lore.kernel.org/r/20211130060117.3026-1-linux@weissschuh.net
</content>
</entry>
</feed>
