<feed xmlns='http://www.w3.org/2005/Atom'>
<title>kernel.git/kernel/irq/internals.h, branch linux-2.6.37.y</title>
<subtitle>Hosts the 0x221E linux distro kernel.
</subtitle>
<id>https://git.0xinfinity.dev/distro/kernel.git/atom?h=linux-2.6.37.y</id>
<link rel='self' href='https://git.0xinfinity.dev/distro/kernel.git/atom?h=linux-2.6.37.y'/>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/'/>
<updated>2011-02-24T22:54:40Z</updated>
<entry>
<title>genirq: Prevent access beyond allocated_irqs bitmap</title>
<updated>2011-02-24T22:54:40Z</updated>
<author>
<name>Thomas Gleixner</name>
</author>
<published>2011-02-17T16:45:15Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=761870db432d30bef879da1df276a388b949ffc6'/>
<id>urn:sha1:761870db432d30bef879da1df276a388b949ffc6</id>
<content type='text'>
commit c1ee6264280e740a9d3ff3feef38642cf0a57013 upstream.

Lars-Peter Clausen pointed out:

   I stumbled upon this while looking through the existing archs using
   SPARSE_IRQ.  Even with SPARSE_IRQ the NR_IRQS is still the upper
   limit for the number of IRQs.

   Both PXA and MMP set NR_IRQS to IRQ_BOARD_START, with
   IRQ_BOARD_START being the number of IRQs used by the core.

   In various machine files the nr_irqs field of the ARM machine
   defintion struct is then set to "IRQ_BOARD_START + NR_BOARD_IRQS".

   As a result "nr_irqs" will greater then NR_IRQS which then again
   causes the "allocated_irqs" bitmap in the core irq code to be
   accessed beyond its size overwriting unrelated data.

The core code really misses a sanity check there.

This went unnoticed so far as by chance the compiler/linker places
data behind that bitmap which gets initialized later on those affected
platforms.

So the obvious fix would be to add a sanity check in early_irq_init()
and break all affected platforms. Though that check wants to be
backported to stable as well, which will require to fix all known
problematic platforms and probably some more yet not known ones as
well. Lots of churn.

A way simpler solution is to allocate a slightly larger bitmap and
avoid the whole churn w/o breaking anything. Add a few warnings when
an arch returns utter crap.

Reported-by: Lars-Peter Clausen &lt;lars@metafoo.de&gt;
Signed-off-by: Thomas Gleixner &lt;tglx@linutronix.de&gt;
Cc: Haojian Zhuang &lt;haojian.zhuang@marvell.com&gt;
Cc: Eric Miao &lt;eric.y.miao@gmail.com&gt;
Cc: Peter Zijlstra &lt;peterz@infradead.org&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@suse.de&gt;

</content>
</entry>
<entry>
<title>genirq: Remove the now unused sparse irq leftovers</title>
<updated>2010-10-12T14:53:44Z</updated>
<author>
<name>Thomas Gleixner</name>
</author>
<published>2010-09-29T15:18:47Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=78f90d91f395cd0dc1ef3f21e0c5cd6fd50d202c'/>
<id>urn:sha1:78f90d91f395cd0dc1ef3f21e0c5cd6fd50d202c</id>
<content type='text'>
The move_irq_desc() function was only used due to the problem that the
allocator did not free the old descriptors. So the descriptors had to
be moved in create_irq_nr(). That's history.

The code would have never been able to move active interrupt
descriptors on affinity settings. That can be done in a completely
different way w/o all this horror.

Remove all of it.

Signed-off-by: Thomas Gleixner &lt;tglx@linutronix.de&gt;
Reviewed-by: Ingo Molnar &lt;mingo@elte.hu&gt;
</content>
</entry>
<entry>
<title>genirq: Sanitize dynamic irq handling</title>
<updated>2010-10-12T14:53:44Z</updated>
<author>
<name>Thomas Gleixner</name>
</author>
<published>2010-09-29T16:46:55Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=b7b29338dc7111ed8bd4d6555d84afae13ebe752'/>
<id>urn:sha1:b7b29338dc7111ed8bd4d6555d84afae13ebe752</id>
<content type='text'>
Use the cleanup functions of the dynamic allocator. No need to have
separate implementations.

Signed-off-by: Thomas Gleixner &lt;tglx@linutronix.de&gt;
Reviewed-by: Ingo Molnar &lt;mingo@elte.hu&gt;
</content>
</entry>
<entry>
<title>genirq: Prepare proc for real sparse irq support</title>
<updated>2010-10-12T14:39:07Z</updated>
<author>
<name>Thomas Gleixner</name>
</author>
<published>2010-09-30T00:46:07Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=13bfe99e09123ef5edb6acb81ba337d2db600b53'/>
<id>urn:sha1:13bfe99e09123ef5edb6acb81ba337d2db600b53</id>
<content type='text'>
/proc/irq never removes any entries, but when irq descriptors can be
freed for real this is necessary. Otherwise we'd reference a freed
descriptor in /proc/irq/N

Signed-off-by: Thomas Gleixner &lt;tglx@linutronix.de&gt;
Reviewed-by: Ingo Molnar &lt;mingo@elte.hu&gt;
</content>
</entry>
<entry>
<title>genirq: Distangle irq.h</title>
<updated>2010-10-12T14:39:04Z</updated>
<author>
<name>Thomas Gleixner</name>
</author>
<published>2010-10-01T14:03:45Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=e144710b302525de5b90b9c3ba43562458d8957f'/>
<id>urn:sha1:e144710b302525de5b90b9c3ba43562458d8957f</id>
<content type='text'>
Move irq_desc and internal functions out of irq.h

Signed-off-by: Thomas Gleixner &lt;tglx@linutronix.de&gt;
Reviewed-by: Ingo Molnar &lt;mingo@elte.hu&gt;
</content>
</entry>
<entry>
<title>genirq: Provide config option to disable deprecated code</title>
<updated>2010-10-04T11:40:24Z</updated>
<author>
<name>Thomas Gleixner</name>
</author>
<published>2010-10-01T13:17:14Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=bd151412263a67b5321e9dd1d5b4bf6d96fdebf3'/>
<id>urn:sha1:bd151412263a67b5321e9dd1d5b4bf6d96fdebf3</id>
<content type='text'>
This option covers now the old chip functions and the irq_desc data
fields which are moving to struct irq_data. More stuff will follow.

Pretty handy for testing a conversion, whether something broke or not.

Signed-off-by: Thomas Gleixner &lt;tglx@linutronix.de&gt;
Reviewed-by: Ingo Molnar &lt;mingo@elte.hu&gt;
</content>
</entry>
<entry>
<title>genirq: Provide compat handling for bus_lock/bus_sync_unlock</title>
<updated>2010-10-04T10:43:35Z</updated>
<author>
<name>Thomas Gleixner</name>
</author>
<published>2010-09-27T12:44:35Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=3876ec9ef3775d062345b3760d3271ecb8cd3fea'/>
<id>urn:sha1:3876ec9ef3775d062345b3760d3271ecb8cd3fea</id>
<content type='text'>
Wrap the old chip functions for bus_lock/bus_sync_unlock until the
migration is complete and the old chip functions are removed.

Signed-off-by: Thomas Gleixner &lt;tglx@linutronix.de&gt;
Cc: Peter Zijlstra &lt;peterz@infradead.org&gt;
LKML-Reference: &lt;20100927121841.842536121@linutronix.de&gt;
Reviewed-by: H. Peter Anvin &lt;hpa@zytor.com&gt;
Reviewed-by: Ingo Molnar &lt;mingo@elte.hu&gt;
</content>
</entry>
<entry>
<title>genirq: Add new functions to dummy chips</title>
<updated>2010-10-04T10:43:34Z</updated>
<author>
<name>Thomas Gleixner</name>
</author>
<published>2010-10-01T12:44:58Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=a77c4635915021c646cc017f22239e66d1aab4d5'/>
<id>urn:sha1:a77c4635915021c646cc017f22239e66d1aab4d5</id>
<content type='text'>
The compat functions go away when the core code is converted.

Signed-off-by: Thomas Gleixner &lt;tglx@linutronix.de&gt;
Reviewed-by: Ingo Molnar &lt;mingo@elte.hu&gt;
</content>
</entry>
<entry>
<title>genirq: Convert core code to irq_data</title>
<updated>2010-10-04T10:36:26Z</updated>
<author>
<name>Thomas Gleixner</name>
</author>
<published>2010-10-01T10:58:38Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=6b8ff3120c758340505dddf08ad685ebb841d5d5'/>
<id>urn:sha1:6b8ff3120c758340505dddf08ad685ebb841d5d5</id>
<content type='text'>
Convert all references in the core code to orq, chip, handler_data,
chip_data, msi_desc, affinity to irq_data.*

Signed-off-by: Thomas Gleixner &lt;tglx@linutronix.de&gt;
Reviewed-by: Ingo Molnar &lt;mingo@elte.hu&gt;
</content>
</entry>
<entry>
<title>sparseirq: Change irq_desc_ptrs to static</title>
<updated>2010-02-18T01:27:03Z</updated>
<author>
<name>Yinghai Lu</name>
</author>
<published>2010-02-10T09:20:34Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=99558f0bbe68cb09799ec38adbaa3f3b2dc7ba63'/>
<id>urn:sha1:99558f0bbe68cb09799ec38adbaa3f3b2dc7ba63</id>
<content type='text'>
Add replace_irq_desc() instead of poking at the array directly.

-v2: remove unneeded boundary check in replace_irq_desc

Signed-off-by: Yinghai Lu &lt;yinghai@kernel.org&gt;
LKML-Reference: &lt;1265793639-15071-31-git-send-email-yinghai@kernel.org&gt;
Signed-off-by: H. Peter Anvin &lt;hpa@zytor.com&gt;
</content>
</entry>
</feed>
