<feed xmlns='http://www.w3.org/2005/Atom'>
<title>linux/arch/arc/kernel/mcip.c, branch v4.9</title>
<subtitle>Mirror of https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/
</subtitle>
<id>https://git.shady.money/linux/atom?h=v4.9</id>
<link rel='self' href='https://git.shady.money/linux/atom?h=v4.9'/>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/'/>
<updated>2016-11-08T20:22:52Z</updated>
<entry>
<title>ARCv2: MCIP: Use IDU_M_DISTRI_DEST mode if there is only 1 destination core</title>
<updated>2016-11-08T20:22:52Z</updated>
<author>
<name>Yuriy Kolerov</name>
<email>yuriy.kolerov@synopsys.com</email>
</author>
<published>2016-11-08T07:08:32Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=0a0a047def15b7c8bcd27671d2be2de3d37fb30d'/>
<id>urn:sha1:0a0a047def15b7c8bcd27671d2be2de3d37fb30d</id>
<content type='text'>
ARC linux uses 2 distribution modes for common interrupts: round robin
mode (IDU_M_DISTRI_RR) and a simple destination mode (IDU_M_DISTRI_DEST).
The first one is used when more than 1 cores may handle a common interrupt
and the second one is used when only 1 core may handle a common interrupt.

However idu_irq_set_affinity() always sets IDU_M_DISTRI_RR for all affinity
values. But there is no sense in setting of such mode if only 1 core must
handle a common interrupt.

Signed-off-by: Yuriy Kolerov &lt;yuriy.kolerov@synopsys.com&gt;
Signed-off-by: Vineet Gupta &lt;vgupta@synopsys.com&gt;
</content>
</entry>
<entry>
<title>ARC: IRQ: Do not use hwirq as virq and vice versa</title>
<updated>2016-11-08T20:05:10Z</updated>
<author>
<name>Yuriy Kolerov</name>
<email>yuriy.kolerov@synopsys.com</email>
</author>
<published>2016-11-08T07:08:31Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=34e71e4cbb8eb467dbcfb3afbd2b95ff2b08f482'/>
<id>urn:sha1:34e71e4cbb8eb467dbcfb3afbd2b95ff2b08f482</id>
<content type='text'>
This came up when reviewing code to address missing IRQ affinity
setting in AXS103 platform and/or implementing hierarchical IRQ domains

- smp_ipi_irq_setup() callers pass hwirq but in turn calls
  request_percpu_irq() which expects a linux virq. So invoke
  irq_find_mapping() to do the conversion
  (also explicitify this in code by renaming the args appropriately)

- idu_of_init()/idu_cascade_isr() were similarly using linux virq where
  hwirq is expected, so do the conversion using irqd_to_hwirq() helper

Signed-off-by: Yuriy Kolerov &lt;yuriy.kolerov@synopsys.com&gt;
[vgupta: made changelog a bit concise a bit]
Signed-off-by: Vineet Gupta &lt;vgupta@synopsys.com&gt;
</content>
</entry>
<entry>
<title>ARCv2: intc: untangle SMP, MCIP and IDU</title>
<updated>2016-10-16T22:49:07Z</updated>
<author>
<name>Vineet Gupta</name>
<email>vgupta@synopsys.com</email>
</author>
<published>2016-09-29T17:00:14Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=3ce0fefc51bd56381b1b9a92835cf8f9db3f2ef8'/>
<id>urn:sha1:3ce0fefc51bd56381b1b9a92835cf8f9db3f2ef8</id>
<content type='text'>
The IDU intc is technically part of MCIP (Multi-core IP) hence
historically was only available in a SMP hardware build (and thus only
in a SMP kernel build). Now that hardware restriction has been lifted,
so a UP kernel needs to support it.

This requires breaking mcip.c into parts which are strictly SMP
(inter-core interrupts) and IDU which in reality is just another
intc and thus has no bearing on SMP.

This change allows IDU in UP builds and with a suitable device tree, we
can have the cascaded intc system

    ARCv2 core intc &lt;---&gt; ARCv2 IDU intc &lt;---&gt; periperals

Signed-off-by: Vineet Gupta &lt;vgupta@synopsys.com&gt;
</content>
</entry>
<entry>
<title>ARC: irq: export some IRQs again</title>
<updated>2016-05-09T04:02:30Z</updated>
<author>
<name>Vineet Gupta</name>
<email>vgupta@synopsys.com</email>
</author>
<published>2016-03-30T13:05:28Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=88555cc584d93e658722f090d3f8fb84d5fa15a5'/>
<id>urn:sha1:88555cc584d93e658722f090d3f8fb84d5fa15a5</id>
<content type='text'>
This will be needed for switching to linear irq domain as
irq_create_mapping() called by intr code needs the IRQ numbers
in addition to existing usage in mcip.c for requesting the irq

Signed-off-by: Vineet Gupta &lt;vgupta@synopsys.com&gt;
</content>
</entry>
<entry>
<title>ARC: clocksource: DT based probe</title>
<updated>2016-05-09T04:02:30Z</updated>
<author>
<name>Vineet Gupta</name>
<email>vgupta@synopsys.com</email>
</author>
<published>2016-01-01T12:35:48Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=e608b53ea863a92eb458cb1ec7c2fcf3ca2b043a'/>
<id>urn:sha1:e608b53ea863a92eb458cb1ec7c2fcf3ca2b043a</id>
<content type='text'>
- Remove explicit clocksource setup and let it be done by OF framework
  by defining CLOCKSOURCE_OF_DECLARE() for various timers

- This allows multiple clocksources to be potentially registered
  simultaneouly: previously we could only do one - as all of them had
  same arc_counter_setup() routine for registration

- Setup routines also ensure that the underlying timer actually exists.

- Remove some of the panic() calls if underlying timer is NOT detected as
  fallback clocksource might still be available
  1. If GRFC doesn't exist, jiffies clocksource gets registered anyways
  2. if RTC doesn't exist, TIMER1 can take over (as it is always
     present)

Cc: Daniel Lezcano &lt;daniel.lezcano@linaro.org&gt;
Signed-off-by: Vineet Gupta &lt;vgupta@synopsys.com&gt;
</content>
</entry>
<entry>
<title>arc: SMP: CONFIG_ARC_IPI_DBG cleanup</title>
<updated>2016-02-24T08:45:39Z</updated>
<author>
<name>Valentin Rothberg</name>
<email>valentinrothberg@gmail.com</email>
</author>
<published>2016-02-24T08:40:22Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=9ef2d8be55652804205a34dcbfec78b933c0ea30'/>
<id>urn:sha1:9ef2d8be55652804205a34dcbfec78b933c0ea30</id>
<content type='text'>
Previous Commit ("ARC: SMP: No need for CONFIG_ARC_IPI_DBG") removed
the Kconfig option ARC_IPI_DBG.  Remove the last reference on this
option.

Signed-off-by: Valentin Rothberg &lt;valentinrothberg@gmail.com&gt;
Signed-off-by: Vineet Gupta &lt;vgupta@synopsys.com&gt;
</content>
</entry>
<entry>
<title>ARC: SMP: No need for CONFIG_ARC_IPI_DBG</title>
<updated>2016-02-24T05:37:32Z</updated>
<author>
<name>Vineet Gupta</name>
<email>vgupta@synopsys.com</email>
</author>
<published>2016-02-19T02:48:11Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=d73b73f5626ac0b131b31b7b9457e19201bc570b'/>
<id>urn:sha1:d73b73f5626ac0b131b31b7b9457e19201bc570b</id>
<content type='text'>
This was more relevant during SMP bringup.

The warning for bogus msg better be visible always.

Signed-off-by: Vineet Gupta &lt;vgupta@synopsys.com&gt;
</content>
</entry>
<entry>
<title>ARCv2: Elide sending new cross core intr if receiver didn't ack prev</title>
<updated>2016-02-24T05:37:31Z</updated>
<author>
<name>Vineet Gupta</name>
<email>vgupta@synopsys.com</email>
</author>
<published>2016-02-19T02:27:41Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=3dea30ca5bef0e013abe857057a952a9d6757fe5'/>
<id>urn:sha1:3dea30ca5bef0e013abe857057a952a9d6757fe5</id>
<content type='text'>
ARConnect/MCIP IPI sending has a retry-wait loop in case caller had
not seen a previous such interrupt. Turns out that it is not needed at
all. Linux cross core calling allows coalescing multiple IPIs to same
receiver - it is fine as long as there is one.

This logic is built into upper layer already, at a higher level of
abstraction. ipi_send_msg_one() sets the actual msg payload, but it only
calls MCIP IPI sending if msg holder was empty (using
atomic-set-new-and-get-old construct). Thus it is unlikely that the
retry-wait looping was ever getting exercised at all.

Cc: Chuck Jordan &lt;cjordan@synopsys.com&gt;
Cc: Peter Zijlstra &lt;peterz@infradead.org&gt;
Signed-off-by: Vineet Gupta &lt;vgupta@synopsys.com&gt;
</content>
</entry>
<entry>
<title>ARCv2: SMP: Push IPI_IRQ into IPI provider</title>
<updated>2016-02-24T05:37:31Z</updated>
<author>
<name>Vineet Gupta</name>
<email>vgupta@synopsys.com</email>
</author>
<published>2016-02-23T08:05:12Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=9681787930cec7cee77db0a93c747153ef962b8a'/>
<id>urn:sha1:9681787930cec7cee77db0a93c747153ef962b8a</id>
<content type='text'>
Signed-off-by: Vineet Gupta &lt;vgupta@synopsys.com&gt;
</content>
</entry>
<entry>
<title>ARCv2: SMP: Emulate IPI to self using software triggered interrupt</title>
<updated>2016-02-24T05:37:28Z</updated>
<author>
<name>Vineet Gupta</name>
<email>vgupta@synopsys.com</email>
</author>
<published>2016-02-23T06:25:16Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=bb143f814ea488769ca2e79e0b376139cb5f134b'/>
<id>urn:sha1:bb143f814ea488769ca2e79e0b376139cb5f134b</id>
<content type='text'>
ARConnect/MCIP Inter-Core-Interrupt module can't send interrupt to
local core. So use core intc capability to trigger software
interrupt to self, using an unsued IRQ #21.

This showed up as csd deadlock with LTP trace_sched on a dual core
system. This test acts as scheduler fuzzer, triggering all sorts of
schedulting activity. Trouble starts with IPI to self, which doesn't get
delivered (effectively lost due to H/w capability), but the msg intended
to be sent remain enqueued in per-cpu @ipi_data.

All subsequent IPIs to this core from other cores get elided due to the
IPI coalescing optimization in ipi_send_msg_one() where a pending msg
implies an IPI already sent and assumes other core is yet to ack it.
After the elided IPI, other core simply goes into csd_lock_wait()
but never comes out as this core never sees the interrupt.

Fixes STAR 9001008624

Cc: Peter Zijlstra &lt;peterz@infradead.org&gt;
Cc: &lt;stable@vger.kernel.org&gt;        [4.2]
Signed-off-by: Vineet Gupta &lt;vgupta@synopsys.com&gt;
</content>
</entry>
</feed>
