History log of /drivers/s390/crypto/ap_bus.c
Revision Date Author Comments (<<< Hide modified files) (Show modified files >>>)
75464960fc0ccc505527edc1459c8ad191fbc0cc 01-Dec-2011 Holger Dengler <hd@linux.vnet.ibm.com> [S390] ap: Setup timer for sending messages after reset.

Setup timer for processing messages in request queue after a
successful AP bus device reset.

Signed-off-by: Holger Dengler <hd@linux.vnet.ibm.com>
Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
/drivers/s390/crypto/ap_bus.c
bc615deaf35ab06e7fe5672b0efb3c7a0b2dcf1a 14-Nov-2011 Holger Dengler <hd@linux.vnet.ibm.com> [S390] ap: Setup processing for messages in request queue.

Setup timer for processing messages in request queue, if sending an AP
message returns with reason code AP_RESPONSE_RESET_IN_PROGRESS.

Signed-off-by: Holger Dengler <hd@linux.vnet.ibm.com>
Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
/drivers/s390/crypto/ap_bus.c
60063497a95e716c9a689af3be2687d261f115b4 27-Jul-2011 Arun Sharma <asharma@fb.com> atomic: use <linux/atomic.h>

This allows us to move duplicated code in <asm/atomic.h>
(atomic_inc_not_zero() for now) to <linux/atomic.h>

Signed-off-by: Arun Sharma <asharma@fb.com>
Reviewed-by: Eric Dumazet <eric.dumazet@gmail.com>
Cc: Ingo Molnar <mingo@elte.hu>
Cc: David Miller <davem@davemloft.net>
Cc: Eric Dumazet <eric.dumazet@gmail.com>
Acked-by: Mike Frysinger <vapier@gentoo.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
/drivers/s390/crypto/ap_bus.c
6bed05bcbc8e5932e06059f0c3be1acdf30a39d4 24-Jul-2011 Holger Dengler <hd@linux.vnet.ibm.com> [S390] ap: toleration support for ap device type 10

Add toleration support for ap devices with device type 10.

Signed-off-by: Holger Dengler <hd@linux.vnet.ibm.com>
Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
/drivers/s390/crypto/ap_bus.c
cf2d007bd43bc254d5254fe9d30af3e73ed5b98a 23-May-2011 Holger Dengler <hd@linux.vnet.ibm.com> [S390] ap: skip device registration on type probe failure

The registration of an ap device will be skipped, if the device type
probing fails.
Add names of current crypto adapters to the Kconfig help.

Signed-off-by: Holger Dengler <hd@linux.vnet.ibm.com>
Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
/drivers/s390/crypto/ap_bus.c
b1f933da570576d1f290ea4dc9b896404cbd285d 05-Jan-2011 Felix Beck <felix.beck@de.ibm.com> [S390] zcrypt: Introduce check for 4096 bit support.

Implemented an asm in the ap bus and made it accessible for the card
specific parts of the zcrypt driver. Thus when a cex3a is recognized
a check can be performed to dermine whether the card supports 4096 bit
RSA keys.

Signed-off-by: Felix Beck <felix.beck@de.ibm.com>
Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
/drivers/s390/crypto/ap_bus.c
62d146ffe3adfed2747fc36138476c8417ce73a7 05-Jan-2011 Holger Dengler <hd@linux.vnet.ibm.com> [S390] ap bus: add support for irq statistics

Add support for AP Bus I/O interrupt statistics in /proc/interrupts.

Signed-off-by: Holger Dengler <hd@linux.vnet.ibm.com>
Signed-off-by: Felix Beck <felix.beck@de.ibm.com>
Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
/drivers/s390/crypto/ap_bus.c
53ec24b1e6c7118a127cf029a1519a2ce55268ec 05-Jan-2011 Felix Beck <felix.beck@de.ibm.com> [S390] zcrypt: Fix check to look for facility bits 2 & 65

Fix the check for ap interupts to look for facility bits 2 and 65.
Make sure that we only register interrupts for aps, if the machine
has ap interrupt support.

This patch is relevant only for the 2.6.37 stable series.

Cc: stable@kernel.org
Signed-off-by: Felix Beck <felix.beck@de.ibm.com>
Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
/drivers/s390/crypto/ap_bus.c
14375bc4eb8dd0fb0e765390650564c35bb31068 25-Oct-2010 Martin Schwidefsky <schwidefsky@de.ibm.com> [S390] cleanup facility list handling

Store the facility list once at system startup with stfl/stfle and
reuse the result for all facility tests.

Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
/drivers/s390/crypto/ap_bus.c
5a0e3ad6af8660be21ca98a971cd00f331318c05 24-Mar-2010 Tejun Heo <tj@kernel.org> include cleanup: Update gfp.h and slab.h includes to prepare for breaking implicit slab.h inclusion from percpu.h

percpu.h is included by sched.h and module.h and thus ends up being
included when building most .c files. percpu.h includes slab.h which
in turn includes gfp.h making everything defined by the two files
universally available and complicating inclusion dependencies.

percpu.h -> slab.h dependency is about to be removed. Prepare for
this change by updating users of gfp and slab facilities include those
headers directly instead of assuming availability. As this conversion
needs to touch large number of source files, the following script is
used as the basis of conversion.

http://userweb.kernel.org/~tj/misc/slabh-sweep.py

The script does the followings.

* Scan files for gfp and slab usages and update includes such that
only the necessary includes are there. ie. if only gfp is used,
gfp.h, if slab is used, slab.h.

* When the script inserts a new include, it looks at the include
blocks and try to put the new include such that its order conforms
to its surrounding. It's put in the include block which contains
core kernel includes, in the same order that the rest are ordered -
alphabetical, Christmas tree, rev-Xmas-tree or at the end if there
doesn't seem to be any matching order.

* If the script can't find a place to put a new include (mostly
because the file doesn't have fitting include block), it prints out
an error message indicating which .h file needs to be added to the
file.

The conversion was done in the following steps.

1. The initial automatic conversion of all .c files updated slightly
over 4000 files, deleting around 700 includes and adding ~480 gfp.h
and ~3000 slab.h inclusions. The script emitted errors for ~400
files.

2. Each error was manually checked. Some didn't need the inclusion,
some needed manual addition while adding it to implementation .h or
embedding .c file was more appropriate for others. This step added
inclusions to around 150 files.

3. The script was run again and the output was compared to the edits
from #2 to make sure no file was left behind.

4. Several build tests were done and a couple of problems were fixed.
e.g. lib/decompress_*.c used malloc/free() wrappers around slab
APIs requiring slab.h to be added manually.

5. The script was run on all .h files but without automatically
editing them as sprinkling gfp.h and slab.h inclusions around .h
files could easily lead to inclusion dependency hell. Most gfp.h
inclusion directives were ignored as stuff from gfp.h was usually
wildly available and often used in preprocessor macros. Each
slab.h inclusion directive was examined and added manually as
necessary.

6. percpu.h was updated not to include slab.h.

7. Build test were done on the following configurations and failures
were fixed. CONFIG_GCOV_KERNEL was turned off for all tests (as my
distributed build env didn't work with gcov compiles) and a few
more options had to be turned off depending on archs to make things
build (like ipr on powerpc/64 which failed due to missing writeq).

* x86 and x86_64 UP and SMP allmodconfig and a custom test config.
* powerpc and powerpc64 SMP allmodconfig
* sparc and sparc64 SMP allmodconfig
* ia64 SMP allmodconfig
* s390 SMP allmodconfig
* alpha SMP allmodconfig
* um on x86_64 SMP allmodconfig

8. percpu.h modifications were reverted so that it could be applied as
a separate patch and serve as bisection point.

Given the fact that I had only a couple of failures from tests on step
6, I'm fairly confident about the coverage of this conversion patch.
If there is a breakage, it's likely to be something in one of the arch
headers which should be easily discoverable easily on most builds of
the specific arch.

Signed-off-by: Tejun Heo <tj@kernel.org>
Guess-its-ok-by: Christoph Lameter <cl@linux-foundation.org>
Cc: Ingo Molnar <mingo@redhat.com>
Cc: Lee Schermerhorn <Lee.Schermerhorn@hp.com>
/drivers/s390/crypto/ap_bus.c
93521314cb3132f40a4bf6d76b4bbcdbc9e59dfb 07-Dec-2009 Felix Beck <felix.beck@de.ibm.com> [S390] zcrypt: Do not simultaneously schedule hrtimer

Protect the hrtimer ap_poll_timer from being scheduled at the same
time from several processes.

Signed-off-by: Felix Beck <felix.beck@de.ibm.com>
Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
/drivers/s390/crypto/ap_bus.c
a6a5d73a56540b5e59dff83bc8f2b2725591346a 07-Dec-2009 Felix Beck <felix.beck@de.ibm.com> [S390] zcrypt: special command support for cex3 exploitation

Support for special command is implemented in the AP Bus in the NQAP
function __ap_send. This is extended for a further parameter special.
When set, the special bit, in GR0 will be set. Therefor the ap_message
struct is extended for a further bit. Thus calling functions of
__ap_send can use the special parameter in ap_message to give to
__ap_send. Affected is in the first place ap_queue_message, which is
called by the actual card driver. The second part of this support is
that the card driver for the CEX3C needs to set this special bit, when
an according CPRB is sent to the driver.

Signed-off-by: Felix Beck <felix.beck@de.ibm.com>
Signed-off-by: Ralph Wuerthner <ralph.wuerthner@de.ibm.com>
Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
/drivers/s390/crypto/ap_bus.c
5314af693da5149c2361d290bb184cf18ee21cdd 22-Sep-2009 Felix Beck <felix.beck@de.ibm.com> [S390] zcrypt: Do not add/remove devices in s/r callbacks

Devices are no longer removed or added in the suspend and resume
callbacks. Instead they are marked unregistered in suspend. In the
resume callback the ap_scan_bus method is scheduled. The bus scan
function will remove the old device and add new ones. This way all
the device handling will be done in only one function. Additionaly
the case where the domain might change during suspend/resume is
caught. In that case the devices qid needs to re-calculated in
order of having it found by the scan method.

Signed-off-by: Felix Beck <felix.beck@de.ibm.com>
Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
/drivers/s390/crypto/ap_bus.c
edc44fa03ed7bc9847787e080190cf1d7ed68ceb 11-Sep-2009 Felix Beck <felix.beck@de.ibm.com> [S390] zcrypt: Free ap_device if dev_set_name fails.

If dev_set_name fails during scanning the AP bus, the reserved memory
has to be freed.

Signed-off-by: Felix Beck <felix.beck@de.ibm.com>
Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
/drivers/s390/crypto/ap_bus.c
95f1556c35529a162cef50296f3dc7f978852048 11-Sep-2009 Felix Beck <felix.beck@de.ibm.com> [S390] zcrypt: Use spin_lock_bh in suspend callback

Fix lock dependency warning.

inconsistent {IN-SOFTIRQ-W} -> {SOFTIRQ-ON-W} usage.
bash/1442 [HC0[0]:SC0[0]:HE1:SE1] takes:
(&ap_dev->lock){+.?...}, at: [<000003e001280404>] __ap_poll_device+0x40/0x3e8 [ap]
{IN-SOFTIRQ-W} state was registered at:
[<000000000017f094>] __lock_acquire+0xb78/0x182c
[<000000000017fe8e>] lock_acquire+0x146/0x178
[<0000000000549cf2>] _spin_lock+0x5a/0x98
[<000003e001280404>] __ap_poll_device+0x40/0x3e8 [ap]
[<000003e001280afe>] ap_poll_all+0xaa/0x1a4 [ap]
[<000000000014fa82>] tasklet_action+0xfe/0x1f4
[<0000000000150a56>] __do_softirq+0x116/0x284
[<0000000000111058>] do_softirq+0xe4/0xe8
[<00000000001504ba>] irq_exit+0xba/0xd8
[<00000000003dd04a>] do_IRQ+0x176/0x1fc
[<000000000011823c>] io_return+0x0/0x8
[<0000004bfbfd2c0e>] 0x4bfbfd2c0e

Signed-off-by: Felix Beck <felix.beck@de.ibm.com>
Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
/drivers/s390/crypto/ap_bus.c
c6304933274f8e3cc6983d496456757ac8ab2e0b 11-Sep-2009 Sebastian Ott <sebott@linux.vnet.ibm.com> [S390] proper use of device register

Don't use kfree directly after device registration started.

Signed-off-by: Sebastian Ott <sebott@linux.vnet.ibm.com>
Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
/drivers/s390/crypto/ap_bus.c
8d406c6de2e67b5bae3c43b62b492c4ff63afb92 24-Jul-2009 Felix Beck <felix.beck@de.ibm.com> [S390] zcrypt: fix scheduling of hrtimer ap_poll_timer

Every time a request is enqueued or there is some work outstanding
from the ap_tasklet, the ap_poll_timer is scheduled again.
Unfortunately it was permanently called. It looked as if it was
started in the past and thus imediately expired.
This has been changed. First it is checked if the hrtimer is already
expired. Then the expiring time is forwarded and the timer restarted.

Signed-off-by: Felix Beck <felix.beck@de.ibm.com>
Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
/drivers/s390/crypto/ap_bus.c
772f54720ab82a6e88f0a8a84d76e7af15ca1f0c 22-Jun-2009 Felix Beck <felix.beck@de.ibm.com> [S390] ap/zcrypt: Suspend/Resume ap bus and zcrypt

Add Suspend/Resume support to ap bus and zcrypt. All enhancements are
done in the ap bus. No changes in the crypto card specific part are
necessary.

Signed-off-by: Felix Beck <felix.beck@de.ibm.com>
Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
/drivers/s390/crypto/ap_bus.c
035da16fb529c0383ac27c712a5bbade5c11cafe 15-Dec-2008 Mark McLoughlin <markmc@redhat.com> s390: remove s390_root_dev_*()

Replace s390_root_dev_register() with root_device_register() etc.

[Includes fix from Cornelia Huck]

Signed-off-by: Mark McLoughlin <markmc@redhat.com>
Cc: Cornelia Huck <cornelia.huck@de.ibm.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
/drivers/s390/crypto/ap_bus.c
136f7a1c4239be91e3e0f53532944b9aab7b58f8 25-Dec-2008 Martin Schwidefsky <schwidefsky@de.ibm.com> [S390] convert ap_bus printks to pr_xxx macros.

Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
/drivers/s390/crypto/ap_bus.c
43c207e6e5b7e591b59294ee4fc9860b0e3de3b8 25-Dec-2008 Christian Maaser <cmaaser@de.ibm.com> [S390] ap: Minor code beautification.

Changed some symbol names for a better and clearer code.

Signed-off-by: Christian Maaser <cmaaser@de.ibm.com>
Signed-off-by: Felix Beck <beckf@de.ibm.com>
Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
/drivers/s390/crypto/ap_bus.c
cb17a6364a29b4dfe5bbb00696032fb63d780157 25-Dec-2008 Felix Beck <felix.beck@de.ibm.com> [S390] zcrypt: Use of Thin Interrupts

When the machine supports AP adapter interrupts polling will be
switched off at module initialization and the driver will work in
interrupt mode.

Signed-off-by: Felix Beck <felix.beck@de.ibm.com>
Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
/drivers/s390/crypto/ap_bus.c
651dab4264e4ba0e563f5ff56f748127246e9065 17-Oct-2008 Arjan van de Ven <arjan@linux.intel.com> Merge commit 'linus/master' into merge-linus

Conflicts:

arch/x86/kvm/i8254.c
1bf5b2853925cf92bfc5f0eddb68a8ed18782845 10-Oct-2008 Cornelia Huck <cornelia.huck@de.ibm.com> [S390] bus_id -> dev_set_name() changes

Convert most s390 users setting bus_id to dev_set_name().
css and ccw busses are deferred since they need some special
treatment.

Signed-off-by: Cornelia Huck <cornelia.huck@de.ibm.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
/drivers/s390/crypto/ap_bus.c
6c644eaeb2e000a08f0e20653b0835bb90a93e4a 02-Sep-2008 Arjan van de Ven <arjan@linux.intel.com> hrtimer: convert s390 to the new hrtimer apis

In order to be able to do range hrtimers we need to use accessor functions
to the "expire" member of the hrtimer struct.
This patch converts s390 to these accessors.

Signed-off-by: Arjan van de Ven <arjan@linux.intel.com>
/drivers/s390/crypto/ap_bus.c
fe1372306149d8c8a68d43765e7caea2377003b6 14-Jul-2008 Felix Beck <felix.beck@de.ibm.com> [S390] ap: Use high-resolution timer for polling

The ap poll mechanism is converted to use a high-resolution timer for
polling. This allows more specific polling. With this a new sysfs
attribute is introduced to specify the polling rate in nanoseconds.

Signed-off-by: Felix Beck <felix.beck@de.ibm.com>
Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
Signed-off-by: Heiko Carstens <heiko.carstens@de.ibm.com>
/drivers/s390/crypto/ap_bus.c
1749a81d629b1295b38071914728cc2e72066f4d 17-Apr-2008 Felix Beck <felix.beck@de.ibm.com> [S390] zcrypt: Comments and kernel-doc cleanup

Comments, which suggested to be kernel-doc but were not in the right
formatting, have been corrected. Additionally some minor cleanup in
the comments has been done.

Signed-off-by: Felix Beck <felix.beck@de.ibm.com>
Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
Signed-off-by: Heiko Carstens <heiko.carstens@de.ibm.com>
/drivers/s390/crypto/ap_bus.c
faa582ca8014d2e1ede5568a813fb0e5c3c078df 05-Mar-2008 Ralph Wuerthner <rwuerthn@de.ibm.com> [S390] zcrypt: fix ap_device_list handling

In ap_device_probe() we can add the new ap device to the internal
device list only if the device probe function successfully returns.
Otherwise we might end up with an invalid device in the internal ap
device list.

Signed-off-by: Ralph Wuerthner <rwuerthn@de.ibm.com>
Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
/drivers/s390/crypto/ap_bus.c
b90b34c6802865d07f482650eff82a4b38df6d79 09-Feb-2008 Felix Beck <felix.beck@de.ibm.com> [S390] zcrypt: Do not start ap poll thread per default

Do not start ap poll thread per default to increase perfomance with
z/VM.

Signed-off-by: Felix Beck <felix.beck@de.ibm.com>
Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
/drivers/s390/crypto/ap_bus.c
efefc6eb38d43b8e5daef482f575d767b002004e 13-Oct-2007 Linus Torvalds <torvalds@woody.linux-foundation.org> Merge master.kernel.org:/pub/scm/linux/kernel/git/gregkh/driver-2.6

* master.kernel.org:/pub/scm/linux/kernel/git/gregkh/driver-2.6: (75 commits)
PM: merge device power-management source files
sysfs: add copyrights
kobject: update the copyrights
kset: add some kerneldoc to help describe what these strange things are
Driver core: rename ktype_edd and ktype_efivar
Driver core: rename ktype_driver
Driver core: rename ktype_device
Driver core: rename ktype_class
driver core: remove subsystem_init()
sysfs: move sysfs file poll implementation to sysfs_open_dirent
sysfs: implement sysfs_open_dirent
sysfs: move sysfs_dirent->s_children into sysfs_dirent->s_dir
sysfs: make sysfs_root a regular directory dirent
sysfs: open code sysfs_attach_dentry()
sysfs: make s_elem an anonymous union
sysfs: make bin attr open get active reference of parent too
sysfs: kill unnecessary NULL pointer check in sysfs_release()
sysfs: kill unnecessary sysfs_get() in open paths
sysfs: reposition sysfs_dirent->s_mode.
sysfs: kill sysfs_update_file()
...
7eff2e7a8b65c25920207324e56611150eb1cd9a 14-Aug-2007 Kay Sievers <kay.sievers@vrfy.org> Driver core: change add_uevent_var to use a struct

This changes the uevent buffer functions to use a struct instead of a
long list of parameters. It does no longer require the caller to do the
proper buffer termination and size accounting, which is currently wrong
in some places. It fixes a known bug where parts of the uevent
environment are overwritten because of wrong index calculations.

Many thanks to Mathieu Desnoyers for finding bugs and improving the
error handling.

Signed-off-by: Kay Sievers <kay.sievers@vrfy.org>
Cc: Mathieu Desnoyers <mathieu.desnoyers@polymtl.ca>
Cc: Cornelia Huck <cornelia.huck@de.ibm.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
/drivers/s390/crypto/ap_bus.c
39aa7cf612cc4e7f688c18f04c35afb51c57472e 12-Oct-2007 Ralph Wuerthner <rwuerthn@de.ibm.com> [S390] zcrypt: fix ap_reset_domain()

Resetting of a all queues within a domain requires that a domain must
be selected first.

Signed-off-by: Ralph Wuerthner <rwuerthn@de.ibm.com>
Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
/drivers/s390/crypto/ap_bus.c
af512ed0f8a7e6a3c6fd93b2b5882c8e837a6939 10-Jul-2007 Ralph Wuerthner <rwuerthn@de.ibm.com> [S390] zcrypt: fix request timeout handling

Under very high load zcrypt requests may timeout while waiting on the
request queue. Modify zcrypt that timeouts are based on crypto adapter
responses. A timeout occurs only if a crypto adapter does not respond
within a given time frame to sumitted requests.

Signed-off-by: Ralph Wuerthner <rwuerthn@de.ibm.com>
Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
/drivers/s390/crypto/ap_bus.c
bf62456eb91f3d2ef0736081583d09b0b3c8b7ea 31-Mar-2007 Eric Rannaud <eric.rannaud@gmail.com> uevent: use add_uevent_var() instead of open coding it

Make use of add_uevent_var() instead of (often incorrectly) open coding it.

Signed-off-by: Michael Ellerman <michael@ellerman.id.au>
Signed-off-by: Eric Rannaud <eric.rannaud@gmail.com>
Cc: Kay Sievers <kay.sievers@vrfy.org>
Cc: Cornelia Huck <cornelia.huck@de.ibm.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
/drivers/s390/crypto/ap_bus.c
e675c0d2bf523a80098c843603ccc091d3720fb4 26-Mar-2007 Ralph Wuerthner <rwuerthn@de.ibm.com> [S390] zcrypt: Fix ap_poll_requests counter in lost requests error path.

In the unlikely event that an AP device lost requests, don't forget to
update the ap_poll_requests counter too. Same must happen in case an AP
device is removed while there are still outstanding requests.

Cc: Martin Schwidefsky <schwidefsky@de.ibm.com>
Signed-off-by: Ralph Wuerthner <rwuerthn@de.ibm.com>
Signed-off-by: Heiko Carstens <heiko.carstens@de.ibm.com>
/drivers/s390/crypto/ap_bus.c
c6a48264739e3486f66e5b21a543c9573b713621 26-Mar-2007 Ralph Wuerthner <rwuerthn@de.ibm.com> [S390] zcrypt: Fix possible dead lock in AP bus module.

If a AP device is unconfigured __ap_poll_all() will call
device_unregister() in software interrupt context which can cause
dead locks. To fix this the device will be only marked as unconfigured
and the device_unregister() call will be done later by either
ap_scan_bus() or ap_queue_message() in process context.

Cc: Martin Schwidefsky <schwidefsky@de.ibm.com>
Signed-off-by: Ralph Wuerthner <rwuerthn@de.ibm.com>
Signed-off-by: Heiko Carstens <heiko.carstens@de.ibm.com>
/drivers/s390/crypto/ap_bus.c
cf352ce0b9104dc6a1c11df52db9f910f1f6cd2e 19-Mar-2007 Ralph Wuerthner <rwuerthn@de.ibm.com> [S390] zcrypt: fix possible dead lock in AP bus module

AP bus module uses bus_for_each_dev() in software interrupt context to
poll for completed requests which might cause dead locks. Solution: use
private AP device list for polling in software interrupt context.

Signed-off-by: Ralph Wuerthner <rwuerthn@de.ibm.com>
Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
/drivers/s390/crypto/ap_bus.c
4d284cac76d0bfebc42d76b428c4e44d921200a9 05-Feb-2007 Heiko Carstens <heiko.carstens@de.ibm.com> [S390] Avoid excessive inlining.

Signed-off-by: Heiko Carstens <heiko.carstens@de.ibm.com>
Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
/drivers/s390/crypto/ap_bus.c
13e742babda8cda7df55b8d1ca67d46b4f8dea84 15-Dec-2006 Ralph Wuerthner <rwuerthn@de.ibm.com> [S390] zcrypt: module unload fixes.

Add code to reset all queues for a domain and add missing tasklet_kill
call to ap bus module exit code.

Signed-off-by: Ralph Wuerthner <rwuerthn@de.ibm.com>
Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
/drivers/s390/crypto/ap_bus.c
85eca8503997cf3a869b159954f703530c865299 08-Dec-2006 Ralph Wuerthner <rwuerthn@de.ibm.com> [S390] add reset call handler to the ap bus.

Signed-off-by: Ralph Wuerthner <rwuerthn@de.ibm.com>
Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
/drivers/s390/crypto/ap_bus.c
4927b3f74c6a2fd92226dcf1542a598be9738808 06-Dec-2006 Al Viro <viro@ftp.linux.org.uk> [PATCH] More work_struct induced breakage (s390)

Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
/drivers/s390/crypto/ap_bus.c
66a4263b991097397823b46377a43ae35541ec26 04-Dec-2006 Cornelia Huck <cornelia.huck@de.ibm.com> [S390] Add MODALIAS= to the uevent for the ap bus.

Signed-off-by: Cornelia Huck <cornelia.huck@de.ibm.com>
Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
/drivers/s390/crypto/ap_bus.c
f3b017d8c9915cbaa8bab178dde1bd9dbbf5012c 27-Oct-2006 Ralph Wuerthner <rwuerthn@de.ibm.com> [S390] Improve AP bus device removal.

Added a call to device_unregister() in ap_scan_bus() to actively
remove unavailable AP bus devices with every bus scan. Previously
devices were only removed in ap_queue_message() or __ap_poll_all().

Signed-off-by: Ralph Wuerthner <rwuerthn@de.ibm.com>
Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
/drivers/s390/crypto/ap_bus.c
d83682b3971d6707d6d668b3b62d416ab7dd1ab3 06-Oct-2006 Christian Borntraeger <cborntra@de.ibm.com> [S390] ap bus poll thread priority.

The ap bus is supposed to have a low priority. We must use 19 instead
of -20, which is just the opposite.

Signed-off-by: Christian Borntraeger <cborntra@de.ibm.com>
Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
/drivers/s390/crypto/ap_bus.c
4e56296d471a827fdd244cfdb6a1e62fc3af7af0 04-Oct-2006 Ralph Wuerthner <rwuerthn@de.ibm.com> [S390] zcrypt device registration/unregistration race.

Fix a race condition during AP device registration and unregistration.

Signed-off-by: Ralph Wuerthner <rwuerthn@de.ibm.com>
Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
/drivers/s390/crypto/ap_bus.c
1534c3820c26aca4e2567f97b8add8bea40e7e2b 20-Sep-2006 Martin Schwidefsky <schwidefsky@de.ibm.com> [S390] zcrypt adjunct processor bus.

Add a bus for the adjunct processor interface. Up to 64 devices can
be connect to the ap bus interface, each device with 16 domains. That
makes 1024 message queues. The interface is asynchronous, the answer
to a message sent to a queue needs to be received at some later point
in time. Unfortunately the interface does not provide interrupts when
a message reply is pending. So the ap bus needs to implement some
fancy polling, each active queue is polled once per 1/HZ second or
continuously if an idle cpus exsists and the poll thread is activ
(see poll_thread parameter).

The ap bus uses the sysfs path /sys/bus/ap and has two bus attributes,
ap_domain and config_time. The ap_domain selects one of the 16 domains
to be used for this system. This limits the maximum number of ap devices
to 64. The config_time attribute contains the number of seconds between
two ap bus scans to find new devices.

The ap bus uses the modalias entries of the form "ap:tN" to autoload
the ap driver for hardware type N. Currently known types are:
3 - PCICC, 4 - PCICA, 5 - PCIXCC, 6 - CEX2A and 7 - CEX2C.

Signed-off-by: Cornelia Huck <cornelia.huck@de.ibm.com>
Signed-off-by: Ralph Wuerthner <rwuerthn@de.ibm.com>
Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
/drivers/s390/crypto/ap_bus.c