<feed xmlns='http://www.w3.org/2005/Atom'>
<title>kernel/linux.git/drivers/net/ipa/ipa_endpoint.c, branch v5.15.7</title>
<subtitle>Linux kernel stable tree (mirror)</subtitle>
<id>https://git.radix-linux.su/kernel/linux.git/atom?h=v5.15.7</id>
<link rel='self' href='https://git.radix-linux.su/kernel/linux.git/atom?h=v5.15.7'/>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/'/>
<updated>2021-12-01T08:04:51+00:00</updated>
<entry>
<title>net: ipa: kill ipa_cmd_pipeline_clear()</title>
<updated>2021-12-01T08:04:51+00:00</updated>
<author>
<name>Alex Elder</name>
<email>elder@linaro.org</email>
</author>
<published>2021-11-23T01:16:40+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=d815f7ca8bd7fb67a77916c922113fad9c3e82e4'/>
<id>urn:sha1:d815f7ca8bd7fb67a77916c922113fad9c3e82e4</id>
<content type='text'>
[ Upstream commit e4e9bfb7c93d7e78aa4ad7e1c411a8df15386062 ]

Calling ipa_cmd_pipeline_clear() after stopping the channel
underlying the AP&lt;-modem RX endpoint can lead to a deadlock.

This occurs in the -&gt;runtime_suspend device power operation for the
IPA driver.  While this callback is in progress, any other requests
for power will block until the callback returns.

Stopping the AP&lt;-modem RX channel does not prevent the modem from
sending another packet to this endpoint.  If a packet arrives for an
RX channel when the channel is stopped, an SUSPEND IPA interrupt
condition will be pending.  Handling an IPA interrupt requires
power, so ipa_isr_thread() calls pm_runtime_get_sync() first thing.

The problem occurs because a "pipeline clear" command will not
complete while such a SUSPEND interrupt condition exists.  So the
SUSPEND IPA interrupt handler won't proceed until it gets power;
that won't happen until the -&gt;runtime_suspend callback (and its
"pipeline clear" command) completes; and that can't happen while
the SUSPEND interrupt condition exists.

It turns out that in this case there is no need to use the "pipeline
clear" command.  There are scenarios in which clearing the pipeline
is required while suspending, but those are not (yet) supported
upstream.  So a simple fix, avoiding the potential deadlock, is to
stop calling ipa_cmd_pipeline_clear() in ipa_endpoint_suspend().
This removes the only user of ipa_cmd_pipeline_clear(), so get rid
of that function.  It can be restored again whenever it's needed.

This is basically a manual revert along with an explanation for
commit 6cb63ea6a39ea ("net: ipa: introduce ipa_cmd_tag_process()").

Fixes: 6cb63ea6a39ea ("net: ipa: introduce ipa_cmd_tag_process()")
Signed-off-by: Alex Elder &lt;elder@linaro.org&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
Signed-off-by: Sasha Levin &lt;sashal@kernel.org&gt;
</content>
</entry>
<entry>
<title>net: ipa: disable HOLB drop when updating timer</title>
<updated>2021-11-25T08:48:34+00:00</updated>
<author>
<name>Alex Elder</name>
<email>elder@linaro.org</email>
</author>
<published>2021-11-12T22:22:10+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=05a48cba24593c683e2514914f36bbd14df410b5'/>
<id>urn:sha1:05a48cba24593c683e2514914f36bbd14df410b5</id>
<content type='text'>
[ Upstream commit 816316cacad2b5abd5b41423cf04e4845239abd4 ]

The head-of-line blocking timer should only be modified when
head-of-line drop is disabled.

One of the steps in recovering from a modem crash is to enable
dropping of packets with timeout of 0 (immediate).  We don't know
how the modem configured its endpoints, so before we program the
timer, we need to ensure HOL_BLOCK is disabled.

Fixes: 84f9bd12d46db ("soc: qcom: ipa: IPA endpoints")
Signed-off-by: Alex Elder &lt;elder@linaro.org&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
Signed-off-by: Sasha Levin &lt;sashal@kernel.org&gt;
</content>
</entry>
<entry>
<title>net: ipa: HOLB register sometimes must be written twice</title>
<updated>2021-11-25T08:48:34+00:00</updated>
<author>
<name>Alex Elder</name>
<email>elder@linaro.org</email>
</author>
<published>2021-11-12T22:22:09+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=0f3de700c6951e710b1122b6f338c6f8966cee34'/>
<id>urn:sha1:0f3de700c6951e710b1122b6f338c6f8966cee34</id>
<content type='text'>
[ Upstream commit 6e228d8cbb1cc6ba78022d406340e901e08d26e0 ]

Starting with IPA v4.5, the HOL_BLOCK_EN register must be written
twice when enabling head-of-line blocking avoidance.

Fixes: 84f9bd12d46db ("soc: qcom: ipa: IPA endpoints")
Signed-off-by: Alex Elder &lt;elder@linaro.org&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
Signed-off-by: Sasha Levin &lt;sashal@kernel.org&gt;
</content>
</entry>
<entry>
<title>net: ipa: rename "ipa_clock.c"</title>
<updated>2021-08-22T08:44:17+00:00</updated>
<author>
<name>Alex Elder</name>
<email>elder@linaro.org</email>
</author>
<published>2021-08-20T16:01:29+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=2775cbc5afeb63f1ddd8c05df216763450772ad9'/>
<id>urn:sha1:2775cbc5afeb63f1ddd8c05df216763450772ad9</id>
<content type='text'>
Finally, rename "ipa_clock.c" to be "ipa_power.c" and "ipa_clock.h"
to be "ipa_power.h".

Signed-off-by: Alex Elder &lt;elder@linaro.org&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</content>
</entry>
<entry>
<title>net: ipa: rename ipa_clock_* symbols</title>
<updated>2021-08-22T08:44:17+00:00</updated>
<author>
<name>Alex Elder</name>
<email>elder@linaro.org</email>
</author>
<published>2021-08-20T16:01:28+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=7aa0e8b8bd5b252c94900b19f2af8b7ec8a4e11d'/>
<id>urn:sha1:7aa0e8b8bd5b252c94900b19f2af8b7ec8a4e11d</id>
<content type='text'>
Rename a number of functions to clarify that there is no longer a
notion of an "IPA clock," but rather that the functions are more
generally related to IPA power management.

  ipa_clock_enable() -&gt; ipa_power_enable()
  ipa_clock_disable() -&gt; ipa_power_disable()
  ipa_clock_rate() -&gt; ipa_core_clock_rate()
  ipa_clock_init() -&gt; ipa_power_init()
  ipa_clock_exit() -&gt; ipa_power_exit()

Rename the ipa_clock structure to be ipa_power.  Rename all
variables and fields using that structure type "power" rather
than "clock".

Rename the ipa_clock_data structure to be ipa_power_data, and more
broadly, just substitute "power" for "clock" in places that
previously represented things related to the "IPA clock".

Update comments throughout.

Signed-off-by: Alex Elder &lt;elder@linaro.org&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</content>
</entry>
<entry>
<title>net: ipa: use gsi-&gt;version for channel suspend/resume</title>
<updated>2021-08-04T09:12:05+00:00</updated>
<author>
<name>Alex Elder</name>
<email>elder@linaro.org</email>
</author>
<published>2021-08-03T14:00:58+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=decfef0fa6b21508657a6e54a01508196988bc95'/>
<id>urn:sha1:decfef0fa6b21508657a6e54a01508196988bc95</id>
<content type='text'>
The GSI layer has the IPA version now, so there's no need for
version-specific flags to be passed from IPA.  One instance of
this is in gsi_channel_suspend() and gsi_channel_resume(), which
indicate whether or not the endpoint suspend is implemented by
GSI stopping the channel.  We can make that determination based
on gsi-&gt;version, eliminating the need for a Boolean flag in those
functions.

Signed-off-by: Alex Elder &lt;elder@linaro.org&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</content>
</entry>
<entry>
<title>net: ipa: use WARN_ON() rather than assertions</title>
<updated>2021-07-26T21:38:11+00:00</updated>
<author>
<name>Alex Elder</name>
<email>elder@linaro.org</email>
</author>
<published>2021-07-26T17:40:10+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=5bc5588466a1f8b48fb04f56c46474a30508a3d6'/>
<id>urn:sha1:5bc5588466a1f8b48fb04f56c46474a30508a3d6</id>
<content type='text'>
I've added commented assertions to record certain properties that
can be assumed to hold in certain places in the IPA code.  Convert
these into real WARN_ON() calls so the assertions are actually
checked, using the standard WARN_ON() mechanism.

Where errors can be returned, return an error if a warning is
triggered.

Signed-off-by: Alex Elder &lt;elder@linaro.org&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</content>
</entry>
<entry>
<title>net: ipa: FLAVOR_0 register doesn't exist until IPA v3.5</title>
<updated>2021-06-21T19:30:59+00:00</updated>
<author>
<name>Alex Elder</name>
<email>elder@linaro.org</email>
</author>
<published>2021-06-21T17:56:25+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=110971d1ee4db10f48374a9303e86db158da354e'/>
<id>urn:sha1:110971d1ee4db10f48374a9303e86db158da354e</id>
<content type='text'>
The FLAVOR_0 version first appears in IPA v3.5, so avoid attempting
to read it for versions prior to that.

This register contains a concise definition of the number and
direction of endpoints supported by the hardware, and without it
we can't verify endpoint configuration in ipa_endpoint_config().
In this case, just indicate that any endpoint number is available
for use.

Originally proposed by AngeloGioacchino Del Regno.

Link: https://lore.kernel.org/netdev/20210211175015.200772-3-angelogioacchino.delregno@somainline.org
Signed-off-by: Alex Elder &lt;elder@linaro.org&gt;
Acked-by: AngeloGioacchino Del Regno
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</content>
</entry>
<entry>
<title>net: ipa: make endpoint data validation unconditional</title>
<updated>2021-06-11T21:13:18+00:00</updated>
<author>
<name>Alex Elder</name>
<email>elder@linaro.org</email>
</author>
<published>2021-06-11T20:39:38+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=9e8fb7bf9c8033e0617515d9a06c2ae9f58b812f'/>
<id>urn:sha1:9e8fb7bf9c8033e0617515d9a06c2ae9f58b812f</id>
<content type='text'>
The cost of validating the endpoint configuration data is not all
that high, so just do it unconditionally, rather than doing so only
when IPA_VALIDATAION is defined.

Suggested-by: Leon Romanovsky &lt;leon@kernel.org&gt;
Signed-off-by: Alex Elder &lt;elder@linaro.org&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</content>
</entry>
<entry>
<title>Revert "net: ipa: disable checksum offload for IPA v4.5+"</title>
<updated>2021-06-03T22:09:40+00:00</updated>
<author>
<name>Alex Elder</name>
<email>elder@linaro.org</email>
</author>
<published>2021-06-02T12:41:31+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=d15ec1933309a4677d0a667738dc64329ec3fd69'/>
<id>urn:sha1:d15ec1933309a4677d0a667738dc64329ec3fd69</id>
<content type='text'>
This reverts commit c88c34fcf8f501d588c0a999aa7e51e18552c5f0.

The RMNet driver now supports inline checksum offload.

Signed-off-by: Alex Elder &lt;elder@linaro.org&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</content>
</entry>
</feed>
