aboutsummaryrefslogtreecommitdiff
AgeCommit message (Collapse)AuthorFilesLines
2011-01-05[S390] mutex: Introduce arch_mutex_cpu_relax()Gerald Schaefer6-2/+13
The spinning mutex implementation uses cpu_relax() in busy loops as a compiler barrier. Depending on the architecture, cpu_relax() may do more than needed in this specific mutex spin loops. On System z we also give up the time slice of the virtual cpu in cpu_relax(), which prevents effective spinning on the mutex. This patch replaces cpu_relax() in the spinning mutex code with arch_mutex_cpu_relax(), which can be defined by each architecture that selects HAVE_ARCH_MUTEX_CPU_RELAX. The default is still cpu_relax(), so this patch should not affect other architectures than System z for now. Signed-off-by: Gerald Schaefer <[email protected]> Signed-off-by: Peter Zijlstra <[email protected]> LKML-Reference: <1290437256.7455.4.camel@thinkpad> Signed-off-by: Ingo Molnar <[email protected]>
2011-01-05[S390] cio: fix ccwgroup unregistration race conditionPeter Oberparleiter1-38/+40
A race condition exists in the ccwgroup device unregistration code which can cause a kernel panic due to a use-after-free bug. This race condition might be triggered when all ccw devices associated with a ccwgroup device are removed at the same time (e.g. because the corresponding channel path becomes no longer available). Fix this race condition by clearing the references from the associated ccw devices to the ccw group device during unregistration of the ccw group device. Signed-off-by: Peter Oberparleiter <[email protected]> Signed-off-by: Martin Schwidefsky <[email protected]>
2011-01-05[S390] perf: add DWARF register lookup for s390Heiko Carstens2-0/+26
Signed-off-by: Heiko Carstens <[email protected]> Signed-off-by: Martin Schwidefsky <[email protected]>
2011-01-05[S390] cleanup ftrace backend functionsMartin Schwidefsky4-171/+135
Signed-off-by: Martin Schwidefsky <[email protected]>
2011-01-05[S390] ptrace cleanupMartin Schwidefsky15-263/+347
Overhaul program event recording and the code dealing with the ptrace user space interface. Signed-off-by: Martin Schwidefsky <[email protected]>
2011-01-05[S390] smp/idle: call init_idle() before starting a new cpuHeiko Carstens3-7/+5
Call init_idle() which (re-)initializes the idle task structure before it gets used on a new cpu. That way we can also get rid of the odd preempt_enable_no_resched() call we have in the cpu offline path within cpu_idle(). That call prevented preempt count imbalances between cpu hotplug operations. Signed-off-by: Heiko Carstens <[email protected]> Signed-off-by: Martin Schwidefsky <[email protected]>
2011-01-05[S390] smp: delay idle task creationHeiko Carstens1-15/+26
Delay idle task creation until a cpu gets set online instead of creating them for all possible cpus at system startup. For one cpu system this should safe more than 1 MB. On my debug system with lots of debug stuff enabled this saves 2 MB. Same as on x86. Signed-off-by: Heiko Carstens <[email protected]> Signed-off-by: Martin Schwidefsky <[email protected]>
2011-01-05[S390] dasd: Correct retry counter for terminated I/O.Stefan Haberland1-1/+0
In case the DASD driver needs to term a running I/O the retry counter is decreased twice. Remove the unnecessary retry counter decrease in das_term_IO. Signed-off-by: Stefan Haberland <[email protected]> Signed-off-by: Martin Schwidefsky <[email protected]>
2011-01-05[S390] dasd: Add support for raw ECKD access.Stefan Haberland5-8/+268
Normal I/O operations through the DASD device driver give only access to the data fields of an ECKD device even for track based I/O. This patch extends the DASD device driver to give access to whole ECKD tracks including count, key and data fields. Signed-off-by: Stefan Haberland <[email protected]> Signed-off-by: Martin Schwidefsky <[email protected]>
2011-01-05[S390] dasd: Prevent deadlock during suspend/resume.Stefan Haberland1-3/+4
The freeze callback may set a stop bit so that a worker thread could not start I/O. The discipline specific freeze function waits for the worker to be completed. Set the stop_bit after the discipline specific freeze function has returned and no worker is running. Signed-off-by: Stefan Haberland <[email protected]> Signed-off-by: Martin Schwidefsky <[email protected]>
2011-01-05[S390] dasd: Improve handling of stolen DASD reservationStefan Weinhuber7-69/+189
If a DASD device has been reserved by a Linux system, and later this reservation is ‘stolen’ by a second system by means of an unconditional reserve, then the first system receives a notification about this fact. With this patch such an event can be either ignored, as before, or it can be used to let the device fail all I/O request, so that the device will not block anymore. Signed-off-by: Stefan Weinhuber <[email protected]> Signed-off-by: Martin Schwidefsky <[email protected]>
2011-01-05[S390] dasd: do path verification for paths added at runtimeStefan Weinhuber9-100/+418
When a new path is added at runtime, the CIO layer will call the drivers path_event callback. The DASD device driver uses this callback to trigger a path verification for the new path. The driver will use only those paths for I/O, which have been successfully verified. Signed-off-by: Stefan Weinhuber <[email protected]> Signed-off-by: Martin Schwidefsky <[email protected]>
2011-01-05[S390] dasd: add High Performance FICON multitrack supportStefan Weinhuber3-46/+122
Some storage systems support multitrack High Performance FICON requests, which read or write data to more than one track. This patch enables the DASD device driver to generate multitrack High Performance FICON requests. Signed-off-by: Stefan Weinhuber <[email protected]> Signed-off-by: Martin Schwidefsky <[email protected]>
2011-01-05[S390] cio: reduce memory consumption of itcw structuresStefan Weinhuber1-10/+52
Any list of indirect data adresses (TIDAL) used by a TCW must not cross a page boundary. The original itcw implementation complies with this restriction by allocating allmost twice as much memory as actually needed, so that in any case there is enough room for the full TIDAL, either above or below the page boundary. This patch implements an alternative method, by using a TTIC TIDAW to connect TIDAL parts below and above a page boundary. Signed-off-by: Stefan Weinhuber <[email protected]> Signed-off-by: Martin Schwidefsky <[email protected]>
2011-01-05[S390] nmi: enable machine checks earlyHeiko Carstens1-0/+2
Until now machine checks for the swapper process of the IPL cpu are just implicitly (and more or less accidently) enabled when the first time the idle process goes into idle state and loads an enabled wait psw. Before that machine checks are disabled. So let's enable them explicitly in trap_init() so we have a well defined time when machine checks are enabled. Signed-off-by: Heiko Carstens <[email protected]> Signed-off-by: Martin Schwidefsky <[email protected]>
2011-01-05[S390] qeth: buffer count imbalanceJan Glauber1-1/+1
The used buffers counter is not incremented in case of an error so the counter can become negative. Increment the used buffers counter before checking for errors. Signed-off-by: Jan Glauber <[email protected]> Signed-off-by: Martin Schwidefsky <[email protected]>
2011-01-05[S390] css: update subchannel descriptorSebastian Ott1-0/+8
Update the subchannel descriptor if we receive a "Installed parameters modified" crw. Signed-off-by: Sebastian Ott <[email protected]> Signed-off-by: Martin Schwidefsky <[email protected]>
2011-01-05[S390] 31 bit entry.S update.Martin Schwidefsky1-103/+109
Make the code in the 31 bit entry.S code as similar as possible to the 64 bit version in entry64.S. That makes it easier to add new code to the first level interrupt handler that affects both 31 and 64 bit kernels. Signed-off-by: Martin Schwidefsky <[email protected]>
2011-01-05[S390] cio: obtain mdc value per channel pathSebastian Ott4-0/+79
Add support to accumulate the number of 64K-bytes blocks all paths to a device at least support for a transport command. Signed-off-by: Sebastian Ott <[email protected]> Signed-off-by: Martin Schwidefsky <[email protected]>
2011-01-05[S390] nohz: optimize arch_needs_cpu()Heiko Carstens1-1/+1
arch_needs_cpu() gets always executed on the current cpu. Therefore the cpu parameter can be ignored it is possible to use __get_cpu_var() instead of per_cpu() to access the per_cpu variable, which will generate better code. Signed-off-by: Heiko Carstens <[email protected]> Signed-off-by: Martin Schwidefsky <[email protected]>
2011-01-05[S390] qdio: cleanup SIGA syncJan Glauber3-55/+44
Simplify the SIGA sync code and add unlikely annotations. In polling mode SBALs may be accessed without interrupt, so call SIGA sync before every scan. Signed-off-by: Jan Glauber <[email protected]> Signed-off-by: Martin Schwidefsky <[email protected]>
2011-01-05[S390] qdio: remove enhanced SIGAJan Glauber2-44/+15
HiperSocket devices only use one SBAL per qdio call without the enhanced SIGA feature. Since that feature is currently not used remove it from the qdio code so the compiler can generate better code for the HiperSocket outbound path. While at it mark the SIGA error conditions as unlikely. Signed-off-by: Jan Glauber <[email protected]> Signed-off-by: Martin Schwidefsky <[email protected]>
2011-01-05[S390] qdio: use proper QEBSM operand for SIGA-R and SIGA-SJan Glauber2-15/+34
If QIOASSIST is enabled for a qdio device the SIGA instruction requires a modified function code. This function code modifier was missing for SIGA-R and SIGA-S which can lead to a kernel panic caused by an operand exception. Cc: [email protected] Signed-off-by: Jan Glauber <[email protected]> Signed-off-by: Martin Schwidefsky <[email protected]>
2011-01-05[S390] qdio: outbound queue full counterJan Glauber3-0/+5
Add a counter for outbound queue full events to the qdio statistics. Signed-off-by: Jan Glauber <[email protected]> Signed-off-by: Martin Schwidefsky <[email protected]>
2011-01-05[S390] qdio: outbound tasklet scan thresholdJan Glauber6-1/+15
Introduce a scan treshold for the qdio outbound queues. By setting the threshold the driver can tell qdio after how much used SBALs qdio should schedule the outbound tasklet that scans the queue for finished SBALs. The threshold is specific by the drivers because a Hipersockets device is much faster in utilizing outbound buffers than a ZFCP or OSA device. The default values after how many used SBALs the tasklet should run are: OSA: > 31 SBALs Hipersockets: > 7 SBALs zfcp: > 55 SBALs Signed-off-by: Jan Glauber <[email protected]> Signed-off-by: Martin Schwidefsky <[email protected]>
2011-01-05[S390] qdio: prevent race for shared indicatorsJan Glauber3-49/+13
If the shared indicator is used the following race leads to an inbound stall: Device CPU0 CPU1 ======================================================== non-shared DSCI =>1 ALSI => 1 Thin INT ALSI => 0 non-shared DSCI tasklets scheduled shared DSCI => 1 ALSI => 1 shared DSCI => 0 ALSI ? -> set Thin INT ALSI => 0 ALSI was set, shared DSCI => 1 After that no more interrupts occur because the DSCI is still set. Fix that race by only resetting the shared DSCI if it was actually set so the tasklets for all shared devices are scheduled and will run after the interrupt. Signed-off-by: Jan Glauber <[email protected]> Signed-off-by: Martin Schwidefsky <[email protected]>
2011-01-05[S390] Handling of 4096 bit RSA keys in CRT format.Felix Beck1-2/+10
Also process 4096 bit RSA keys in CRT format. Handle them like the smaller keys and take care of the zero padding. Signed-off-by: Felix Beck <[email protected]> Signed-off-by: Martin Schwidefsky <[email protected]>
2011-01-05[S390] zcrypt: cope with cca restriction of cex3Felix Beck5-1/+21
The cca on the crypto adapter has a restriction in the size of the exponent if a key with a modulus bigger than 2048 bit is used. Thus in that case we have to avoid that the crypto device driver thinks the adapter is defect and sets it offline. Therfore a new member for the zcrypt_device struct called max_exp_bit_length is introduced. This will be set the first time the cca returns the error code function not implemented. If this is done with an adapter twice it will return -EINVAL. Signed-off-by: Felix Beck <[email protected]> Signed-off-by: Martin Schwidefsky <[email protected]>
2011-01-05[S390] zcrypt: support for 4096 bit keys for cex3cFelix Beck1-2/+2
Definitions for CEX3 card types are changed to support 4096 bit RSA keys in the coprocessor. Signed-off-by: Felix Beck <[email protected]> Signed-off-by: Ralph Wuerthner <[email protected]> Signed-off-by: Martin Schwidefsky <[email protected]>
2011-01-05[S390] zcrypt: support for 4096 bit keys for cex3aFelix Beck2-16/+87
Definitions for CEX3 card types are changed to support 4096 bit RSA keys. Also new structs for the accelerator mode are needed. Additionaly when checking the length of key parts, the case for bigger (4096 bit) keys is needed. Signed-off-by: Felix Beck <[email protected]> Signed-off-by: Ralph Wuerthner <[email protected]> Signed-off-by: Martin Schwidefsky <[email protected]>
2011-01-05[S390] zcrypt: Introduce check for 4096 bit support.Felix Beck2-0/+65
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 <[email protected]> Signed-off-by: Martin Schwidefsky <[email protected]>
2011-01-05[S390] hypfs: Move buffer allocation from open to readMichael Holzheu6-118/+195
Currently the buffer for diagnose data is allocated in the open function of the debugfs file and is released in the close function. This has the drawback that a user (root) can pin that memory by not closing the file. This patch moves the buffer allocation to the read function. The buffer is automatically released after the buffer is copied to userspace. Signed-off-by: Michael Holzheu <[email protected]> Signed-off-by: Martin Schwidefsky <[email protected]>
2011-01-05[S390] current_thread_info optimizationMartin Schwidefsky1-1/+1
Use thread_info lowcore field for current_thread_info(), saves an unnecessary calculation. Signed-off-by: Martin Schwidefsky <[email protected]>
2011-01-05[S390] extint: get rid of early code plus cleanupHeiko Carstens2-103/+51
Get rid of register/unregister_early_external_interrupt() and clean up the code while at it. Signed-off-by: Heiko Carstens <[email protected]> Signed-off-by: Martin Schwidefsky <[email protected]>
2011-01-05[S390] sclp: use register_external_interrupt()Heiko Carstens1-9/+3
Use register_external_interrupt() instead of register_early_external_interrupt(). The early variant is not necessary since kmalloc works already. Signed-off-by: Heiko Carstens <[email protected]> Signed-off-by: Martin Schwidefsky <[email protected]>
2011-01-05[S390] pfault: delay register of pfault interruptHeiko Carstens3-15/+15
Use an early init call to initialize pfault. That way it is possible to use the register_external_interrupt() instead of the early variant. No need to enable pfault any earlier since it has only effect if user space processes are running. Signed-off-by: Heiko Carstens <[email protected]> Signed-off-by: Martin Schwidefsky <[email protected]>
2011-01-05[S390] ap bus: add support for irq statisticsHolger Dengler3-0/+4
Add support for AP Bus I/O interrupt statistics in /proc/interrupts. Signed-off-by: Holger Dengler <[email protected]> Signed-off-by: Felix Beck <[email protected]> Signed-off-by: Martin Schwidefsky <[email protected]>
2011-01-05[S390] ctc: add support for irq statisticsHeiko Carstens3-0/+4
Add support for CTC I/O interrupt statistics in /proc/interrupts. Signed-off-by: Heiko Carstens <[email protected]> Signed-off-by: Martin Schwidefsky <[email protected]>
2011-01-05[S390] claw: add support for irq statisticsHeiko Carstens3-0/+4
Add support for CLAW I/O interrupt statistics in /proc/interrupts. Signed-off-by: Heiko Carstens <[email protected]> Signed-off-by: Martin Schwidefsky <[email protected]>
2011-01-05[S390] lcs: add support for irq statisticsHeiko Carstens3-0/+4
Add support for LCS I/O interrupt statistics in /proc/interrupts. Signed-off-by: Heiko Carstens <[email protected]> Signed-off-by: Martin Schwidefsky <[email protected]>
2011-01-05[S390] vmur: add support for irq statisticsHeiko Carstens3-0/+4
Add support for VMUR I/O interrupt statistics in /proc/interrupts. Signed-off-by: Heiko Carstens <[email protected]> Signed-off-by: Martin Schwidefsky <[email protected]>
2011-01-05[S390] tape: add support for irq statisticsHeiko Carstens3-0/+4
Add support for ccw based tape I/O interrupt statistics in /proc/interrupts. Signed-off-by: Heiko Carstens <[email protected]> Signed-off-by: Martin Schwidefsky <[email protected]>
2011-01-05[S390] 3270: add support for irq statisticsHeiko Carstens3-0/+4
Add support for 3270 I/O interrupt statistics in /proc/interrupts. Signed-off-by: Heiko Carstens <[email protected]> Signed-off-by: Martin Schwidefsky <[email protected]>
2011-01-05[S390] 3215: add support for irq statisticsHeiko Carstens3-0/+4
Add support for 3215 I/O interrupt statistics in /proc/interrupts. Signed-off-by: Heiko Carstens <[email protected]> Signed-off-by: Martin Schwidefsky <[email protected]>
2011-01-05[S390] dasd: add support for irq statisticsHeiko Carstens3-0/+4
Add support for DASD I/O interrupt statistics in /proc/interrupts. Signed-off-by: Heiko Carstens <[email protected]> Signed-off-by: Martin Schwidefsky <[email protected]>
2011-01-05[S390] qdio: add qdio interrupts to interrupt statisticsJan Glauber4-0/+8
Count traditional qdio interrupts and adapter interrupts for qdio in the interrupt statistics. Signed-off-by: Jan Glauber <[email protected]> Signed-off-by: Martin Schwidefsky <[email protected]>
2011-01-05[S390] irq: have detailed statistics for interrupt typesHeiko Carstens11-20/+56
Up to now /proc/interrupts only has statistics for external and i/o interrupts but doesn't split up them any further. This patch adds a line for every single interrupt source so that it is possible to easier tell what the machine is/was doing. Part of the output now looks like this; CPU0 CPU2 CPU4 EXT: 3898 4232 2305 I/O: 782 315 245 CLK: 1029 1964 727 [EXT] Clock Comparator IPI: 2868 2267 1577 [EXT] Signal Processor TMR: 0 0 0 [EXT] CPU Timer TAL: 0 0 0 [EXT] Timing Alert PFL: 0 0 0 [EXT] Pseudo Page Fault [...] NMI: 0 1 1 [NMI] Machine Checks Signed-off-by: Heiko Carstens <[email protected]> Signed-off-by: Martin Schwidefsky <[email protected]>
2011-01-05[S390] time: let local_tick_enable/disable() reprogram the clock comparatorHeiko Carstens2-2/+2
Let local_tick_enable/disable() reprogram the clock comparator so the function names make semantically more sense. Also that way the functions are more symmetric since normally each local_tick_enable() call usually would have a subsequent call to set_clock_comparator() anyway. Signed-off-by: Heiko Carstens <[email protected]> Signed-off-by: Martin Schwidefsky <[email protected]>
2011-01-05[S390] time: move local_tick_enable()/disable() to timex.hHeiko Carstens2-16/+18
Move the two functions to timex.h where they make more sense than in hardirq.h. No functional change. Signed-off-by: Heiko Carstens <[email protected]> Signed-off-by: Martin Schwidefsky <[email protected]>
2011-01-05[S390] add kprobes annotationsMartin Schwidefsky8-9/+26
Add kprobes annotations to get the massive 'probe kernel.function("*") {}' stress test working. Signed-off-by: Martin Schwidefsky <[email protected]>