]> www.infradead.org Git - users/jedix/linux-maple.git/commit
sparc64 sparse irq
authorbob picco <bpicco@meloft.net>
Wed, 12 Jun 2013 20:12:40 +0000 (16:12 -0400)
committerbob picco <bpicco@meloft.net>
Thu, 13 Jun 2013 15:01:31 +0000 (11:01 -0400)
commit9bdd56096df4fd984dd4e19d616a89bc77d105b7
treed8ef9a852618a0ff8041259af54dec3c62952d87
parent26073dcda2e908002a8ade56d1434a92e80015b8
sparc64 sparse irq

This patch does many things. The highlights are:  1) enables SPARSE_IRQ,
2) allocates ivector_table at boot time, 3) default to cookie only VIRQ
mechanism for supported firmware and 4) structures the code some.

The sysino is a deprecated HV mechanism according to the most recent
(impossible to find) SPARC Virtual Machine Specification. HV_GRP_INTR
is what controls the cookie/sysino firmware versioning. The history
appears to be something like this:
major version 2 was dropped.
major version 3 is where a cookie only VIRQ
is possible. Using version 3 means ivector_table isn't required.

The syino ivector_table is default large for major < 3. This is to accomodate
Athena and possibly T4-4. It might be possible to expand by page order on the
fly at boot but not done. Should you fail to boot (BUG_ON), then you'll need
to use the boot line option "num_ivecs" to increase the number of nr_vecs.
Note the BUG_ON sounds too catastrophic but better than indexing beyond
the array bounds like we had!

There are two new boot line options:
num_ivecs - the maximum size of the sysino. Each sysino requires two
extended words (unsigned long). It's default NR value is 0xffff.
It must be physically contiguous.

The other boot option:
hvirq - this is the version for HV_GRP_INTR. This is related to HV API
versioning.  The code attempts major=3 first by default. The option can
be used to override this default.

There are puzzling issues which we carried over into SPARSE_IRQ. The first
two are iclr and imap. The other issue is in sun4v_build_virq -
LDC/VIRQ related: irq_set_status_flags(irq, IRQ_NOAUTOEN);.

Signed-off-by: Bob Picco <bob.picco@oracle.com>
arch/sparc/Kconfig
arch/sparc/include/asm/irq_64.h
arch/sparc/kernel/irq_64.c