aboutsummaryrefslogtreecommitdiff
path: root/drivers
AgeCommit message (Collapse)Author
2008-10-10ide: ide_id_to_hd_driveid() -> ata_id_to_hd_driveid()Bartlomiej Zolnierkiewicz
Rename ide_id_to_hd_driveid() to ata_id_to_hd_driveid() and move it to <linux/ata.h>. Cc: Jeff Garzik <jgarzik@pobox.com> Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
2008-10-10ide: use ata_id_is_cfa()Bartlomiej Zolnierkiewicz
Use ata_id_is_cfa() in do_identify() instead of open-coding check for CompactFlash devices (the inline helper also takes care of detecting CFs advertising themselves as ATA disks). Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
2008-10-10ide: ide_id_has_flush_cache_ext() -> ata_id_flush_ext_enabled()Bartlomiej Zolnierkiewicz
* Add ata_id_flush_ext_enabled() inline helper to <linux/ata.h>. * ide_id_has_flush_cache_ext() -> ata_id_flush_ext_enabled() The latter one also checks if the command is marked as supported in word 83 and validity of words 83 & 86. Cc: Jeff Garzik <jgarzik@pobox.com> Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
2008-10-10ide: ide_id_has_flush_cache() -> ata_id_flush_enabled()Bartlomiej Zolnierkiewicz
* Add ata_id_flush_enabled() inline helper to <linux/ata.h>. * ide_id_has_flush_cache() -> ata_id_flush_enabled() The latter one also checks if the command is marked as supported in word 83 and validity of words 83 & 86. Cc: Jeff Garzik <jgarzik@pobox.com> Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
2008-10-10ide: idedisk_supports_lba48() -> ata_id_lba48_enabled()Bartlomiej Zolnierkiewicz
* Add ata_id_lba48_enabled() inline helper to <linux/ata.h>. * idedisk_supports_lba48() -> ata_id_lba48_enabled() The latter one also checks validity of words 83 & 86. Cc: Jeff Garzik <jgarzik@pobox.com> Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
2008-10-10ide: ide_dev_is_sata() -> ata_id_is_sata()Bartlomiej Zolnierkiewicz
* Use optimized ATA version check from Sergei in ata_id_is_sata(). * ide_dev_is_sata() -> ata_id_is_sata() Cc: Jeff Garzik <jgarzik@pobox.com> Cc: Sergei Shtylyov <sshtylyov@ru.mvista.com> Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
2008-10-10ide: ide_dev_has_iordy() -> ata_id_has_iordy()Bartlomiej Zolnierkiewicz
* Remove (id[ATA_ID_FIELD_VALID] & 2) check from ide_dev_has_iordy() (it is for validity of words 64-70, IORDY is in word 49). * ide_dev_has_iordy() -> ata_id_has_iordy() Cc: Sergei Shtylyov <sshtylyov@ru.mvista.com> Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
2008-10-10ide: factor out HDIO_*_NICE ioctl handling to ide_*_nice_ioctl()Bartlomiej Zolnierkiewicz
Factor out HDIO_{GET,SET}_NICE ioctl handling from generic_ide_ioctl() to ide_{get,set}_nice_ioctl(). Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
2008-10-10ide: remove ->supports_dsc_overlap field from ide_driver_tBartlomiej Zolnierkiewicz
* Use drive->media and drive->scsi to check if ->dsc_overlap can be set by HDIO_SET_NICE ioctl in generic_ide_ioctl(). * Remove unused ->supports_dsc_overlap field from ide_driver_t. There should be no functional changes caused by this patch. Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
2008-10-10ide: remove read-only ->atapi_overlap field from ide_drive_tBartlomiej Zolnierkiewicz
Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
2008-10-10cmd640: add __set_prefetch_mode()Bartlomiej Zolnierkiewicz
Factor out the common code from check_prefetch() and set_prefetch_mode() to __set_prefetch_mode(). Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
2008-10-10ide: remove SECTOR_WORDS defineBartlomiej Zolnierkiewicz
Just use SECTOR_SIZE instead. Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
2008-10-10ide: /proc/ide/hd*/settings reworkBartlomiej Zolnierkiewicz
* Add struct ide_devset, S_* flags, *DEVSET() & ide*_devset_*() macros. * Add 'const struct ide_devset **settings' to ide_driver_t. * Use 'const struct ide_devset **settings' in ide_drive_t instead of 'struct ide_settings_s *settings'. Then convert core code and device drivers to use struct ide_devset and co.: - device settings are no longer allocated dynamically for each device but instead there is an unique struct ide_devset instance per setting - device driver keeps the pointer to the table of pointers to its settings in ide_driver_t.settings - generic settings are kept in ide_generic_setting[] - ide_proc_[un]register_driver(), ide_find_setting_by_name(), ide_{read,write}_setting() and proc_ide_{read,write}_settings() are updated accordingly - ide*_add_settings() are removed * Remove no longer used __ide_add_setting(), ide_add_setting(), __ide_remove_setting() and auto_remove_settings(). * Remove no longer used TYPE_*, SETTING_*, ide_procset_t and ide_settings_t. * ->keep_settings, ->using_dma, ->unmask, ->noflush, ->dsc_overlap, ->nice1, ->addressing, ->wcache and ->nowerr ide_drive_t fields can now be bitfield flags. While at it: * Rename ide_find_setting_by_name() to ide_find_setting(). * Rename write_wcache() to set_wcache(). There should be no functional changes caused by this patch. Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
2008-10-10ide: preparations for /proc/ide/hd*/settings reworkBartlomiej Zolnierkiewicz
After rework settings will be no longer created dynamically for each device so we need to make some fixups first. * Use set_[ksettings,unmaskirq]() as a set function for ["keepsettings","unmaskirq"] setting. * Allow writes to ["io_32bit","unmaskirq"] settings also when drive->no_[io_32bit,unmask] is set (this is checked later inside set_[io_32bit,unmaskirq]() anywyay and keeps consistency with the corresponding HDIO_SET_[32BIT,UNMASKINTR] ioctls). * Use max possible multi sectors value (16) as an allowed max for "multcount" setting. set_multcount() set function checks against device's max possbile value anyway and it makes the proc setting consistent with the corresponding HDIO_SET_MULTCOUNT ioctl. Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
2008-10-10ide: call ide_proc_register_driver() laterBartlomiej Zolnierkiewicz
Call ide_proc_register_driver() in ide*_setup() (just before ide*_add_settings() call) instead of in ->probe method. Despite being basically a preparation for /proc/ide/hd*/settings rework this is a nice cleanup in itself. Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
2008-10-10ide: include <linux/hdreg.h> only when neededBartlomiej Zolnierkiewicz
* Include <linux/ata.h> directly in <linux/ide.h> instead of through <linux/hdreg.h>. * Include <linux/hdreg.h> only when needed. Cc: Christoph Hellwig <hch@infradead.org> Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
2008-10-10ide: remove CONFIG_IDEDISK_MULTI_MODEBartlomiej Zolnierkiewicz
Use multi PIO by default when available and remove no longer needed CONFIG_IDEDISK_MULTI_MODE (it should be safe nowadays, despite to what help entry has been saying). Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
2008-10-10ide: check drive->present in ide_get_paired_drive()Bartlomiej Zolnierkiewicz
* Change ide_get_paired_drive() to return NULL if peer device is not present and update all users accordingly. While at it: * ide_get_paired_drive() -> ide_get_pair_dev() * Use ide_get_pair_dev() in cs5530.c, sc1200.c and via82cxxx.c. There should be no functional changes caused by this patch. Acked-by: Sergei Shtylyov <sshtylyov@ru.mvista.com> Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
2008-10-10ide: remove needless drive->present checks from device driversBartlomiej Zolnierkiewicz
Remove needless drive->present checks from ->probe methods (device model takes care of that). Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
2008-10-10ide: remove unused _IDE_C and _IDE_DISK definesBartlomiej Zolnierkiewicz
Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
2008-10-10ide: remove IDE_CHIPSET_* macrosBartlomiej Zolnierkiewicz
They just obfuscate the code. Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
2008-10-10ide: remove no longer needed BUG_ON()-s from init_irq()Bartlomiej Zolnierkiewicz
init_irq() is now called only during initial host registration so these BUG_ON()-s are no loner needed (+ the last one was done too late anyway). Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
2008-10-10ide: enhance ide_busy_sleep()Bartlomiej Zolnierkiewicz
* Make ide_busy_sleep() take timeout value as a parameter and also allow use of AltStatus Register if requested with altstatus parameter. Update existing users accordingly. * Convert ide_driveid_update() and actual_try_to_identify() to use ide_busy_sleep(). There should be no functional changes caused by this patch. Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
2008-10-10ide: fix EXABYTENEST handling in probe_for_drive()Bartlomiej Zolnierkiewicz
Fix EXABYTENEST handling in probe_for_drive() (so drive->present is checked for "nested" device) and cleanup enable_nest(). Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
2008-10-10ide-cd: use the new object_is_in_stack() helperFUJITA Tomonori
Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp> Cc: Borislav Petkov <petkovbb@gmail.com> Cc: Thomas Bogendoerfer <tsbogend@alpha.franken.de> Cc: Tejun Heo <htejun@gmail.com> Cc: Jens Axboe <jens.axboe@oracle.com> Cc: James Bottomley <James.Bottomley@HansenPartnership.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
2008-10-10ide: re-code ide_fixstring() loop to be less evilLinus Torvalds
On Friday 25 July 2008, Linus Torvalds wrote: > > On Fri, 25 Jul 2008, Ben Dooks wrote: > > > > personally, i would much prefer to see the loop being less evil > > like: > > > > for (p = s; p < end; p += 2) > > be16_to_cpus((u16 *)p); > > Well, in this case, the code actually depends on 'p' being back at the > start of the buffer by the end of it all, so it would need some more > changes than that. > > But yes, I applied David's patch, but I _also_ suspect that we would be > better off without code that does horrid things like casts and assignments > inside the function arguments. > > So it would be nice to re-code that loop to be more readable. But due to > the reliance of 'p' being 's' after the loop, the minimal patch would be > something like the appended. > > Bartlomiej - take this or not, I'm not going to commit it - I haven't > tested it, nor do I even have any machines that would trigger it. So this > is more a "maybe something like this" than anything else. From: Linus Torvalds <torvalds@linux-foundation.org> CC: Ben Dooks <ben-linux@fluff.org> Cc: David Miller <davem@davemloft.net> Cc: harvey.harrison@gmail.com Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
2008-10-10ide: remove no longer needed ide_drive_t fieldsBartlomiej Zolnierkiewicz
Remove ->remap_0_to_1 and ->sect0 (they are always zero now). Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
2008-10-10ide: use ATA_* defines instead of *_STAT and *_ERR onesBartlomiej Zolnierkiewicz
* ERR_STAT -> ATA_ERR * INDEX_STAT -> ATA_IDX * ECC_STAT -> ATA_CORR * DRQ_STAT -> ATA_DRQ * SEEK_STAT -> ATA_DSC * WRERR_STAT -> ATA_DF * READY_STAT -> ATA_DRDY * BUSY_STAT -> ATA_BUSY * MARK_ERR -> ATA_AMNF * TRK0_ERR -> ATA_TRK0NF * ABRT_ERR -> ATA_ABORTED * MCR_ERR -> ATA_MCR * ID_ERR -> ATA_IDNF * MC_ERR -> ATA_MC * ECC_ERR -> ATA_UNC * ICRC_ERR -> ATA_ICRC * BBD_ERR -> ATA_BBK Also: * ILI_ERR -> ATAPI_ILI * EOM_ERR -> ATAPI_EOM * LFS_ERR -> ATAPI_LFS * CD -> ATAPI_COD * IO -> ATAPI_IO Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
2008-10-10hd: WIN_* -> ATA_CMD_*Bartlomiej Zolnierkiewicz
* Use ATA_CMD_* defines instead of WIN_* ones. * Include <linux/ata.h> directly instead of through <linux/hdreg.h>. Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
2008-10-10ide: WIN_* -> ATA_CMD_*Bartlomiej Zolnierkiewicz
* Use ATA_CMD_* defines instead of WIN_* ones. While at it: * EXABYTE_ENABLE_NEXT -> ATA_EXABYTE_ENABLE_NEST * SETFEATURES_{EN,DIS}_WCACHE -> SETFEATURES_WC_{ON,OFF} * SETFEATURES_{EN,DIS}_AAM -> SETFEATURES_AAM_{ON,OFF} * SMART_* -> ATA_SMART_* * Remove stale comment from ide-proc.c. Partially based on earlier work by Chris Wedgwood. Acked-by: Chris Wedgwood <cw@f00f.org> Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
2008-10-10libata: WIN_* -> ATA_CMD_*Bartlomiej Zolnierkiewicz
Acked-by: Jeff Garzik <jeff@garzik.org> Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
2008-10-10ide-disk: use ata_id_hpa_enabled()Bartlomiej Zolnierkiewicz
idedisk_supports_hpa() -> ata_id_hpa_enabled(). The latter one also checks validity of words 82 & 85. Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
2008-10-10ide-disk: use ata_id_wcache_enabled()Bartlomiej Zolnierkiewicz
Replace open-coded check by ata_id_wcache_enabled() (which also checks validity of word 85). Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
2008-10-10ide: use ata_id_current_chs_valid()Bartlomiej Zolnierkiewicz
Replace open-coded checks by ata_id_current_chs_valid(). There should be no functional changes caused by this patch. Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
2008-10-10ide: remove drive->driveidBartlomiej Zolnierkiewicz
* Factor out HDIO_[OBSOLETE,GET]_IDENTITY ioctls handling to ide_get_identity_ioctl(). * Use temporary buffer in ide_get_identity_ioctl() instead of accessing drive->id directly. * Add ide_id_to_hd_driveid() inline to convert raw id into struct hd_driveid format (needed on big-endian). * Use ide_id_to_hd_driveid() in ide_get_identity_ioctl(), cleanup ide_fix_driveid() and switch ide to use use raw id. * Remove no longer needed drive->driveid. This leaves us with 3 users of struct hd_driveid in tree: - arch/um/drivers/ubd_kern.c - drivers/block/xsysace.c - drivers/usb/storage/isd200.c While at it: * Use ata_id_u{32,64}() and ata_id_has_{dma,lba,iordy}() macros. There should be no functional changes caused by this patch. Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
2008-10-10ide: make drive->id an union (take 2)Bartlomiej Zolnierkiewicz
Make drive->id an unnamed union so id can be accessed either by using 'u16 *id' or 'struct hd_driveid *driveid'. Then convert all existing drive->id users accordingly (using 'u16 *id' when possible). This is an intermediate step to make ide 'struct hd_driveid'-free. While at it: - Add missing KERN_CONTs in it821x.c. - Use ATA_ID_WORDS and ATA_ID_*_LEN defines. - Remove unnecessary checks for drive->id. - s/drive_table/table/ in ide_in_drive_list(). - Cleanup ide_config_drive_speed() a bit. - s/drive1/dev1/ & s/drive0/dev0/ in ide_undecoded_slave(). v2: Fix typo in drivers/ide/ppc/pmac.c. (From Stephen Rothwell) There should be no functional changes caused by this patch. Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
2008-10-10ide: cleanup ide_fix_driveid()Bartlomiej Zolnierkiewicz
Do all __le16_to_cpu() swapping in one loop. Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
2008-10-10ide: cleanup ide_disk_init_mult_count()Bartlomiej Zolnierkiewicz
* Remove superfluous checks for drive->mult_req. * No need to zero drive's fields. * Move the common code out of #ifdef scope. There should be no functional changes caused by this patch. Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
2008-10-10ide: remove superfluous check from ide_disk_special()Bartlomiej Zolnierkiewicz
This condition is checked by both ide_disk_init_mult_count() and set_multcount() so no need to do it again in ide_disk_special(). Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
2008-10-10ide-tape: Buildfix when IDETAPE_DEBUG_LOG is set to 1.Mark de Wever
The format specifier for rq->sector didn't specify the proper size and signedness. Borislav Petkov discovered that the signedness for rq->nr_sectors and rq->current_nr_sectors also were incorrect. Signed-off-by: Mark de Wever <koraq@xs4all.nl> Acked-by: Borislav Petkov <petkovbb@gmail.com> [bart: remove trailing whitespace] Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
2008-10-10Merge branch 'for-linus' of ↵Linus Torvalds
git://git.kernel.org/pub/scm/linux/kernel/git/jmorris/security-testing-2.6 * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jmorris/security-testing-2.6: selinux: Fix an uninitialized variable BUG/panic in selinux_secattr_to_sid() selinux: use default proc sid on symlinks file capabilities: uninline cap_safe_nice Update selinux info in MAINTAINERS and Kconfig help text SELinux: add gitignore file for mdp script SELinux: add boundary support and thread context assignment securityfs: do not depend on CONFIG_SECURITY selinux: add support for installing a dummy policy (v2) security: add/fix security kernel-doc selinux: Unify for- and while-loop style selinux: conditional expression type validation was off-by-one smack: limit privilege by label SELinux: Fix a potentially uninitialised variable in SELinux hooks SELinux: trivial, remove unneeded local variable SELinux: Trivial minor fixes that change C null character style make selinux_write_opts() static
2008-10-10[S390] 3215: Remove tasklet.Heiko Carstens
The 3215 console irq handler used to schedule a tasklet. However the console irq handler also gets called from the infamous cio_tpi() function. Which in turn does something like local_bh_disable() [call console irq handler] _local_bh_enable() _local_bh_enable() prevents execution of softirqs, which is intended within cio_tpi(). However there might be a new softirq pending because irq handler scheduled a tasklet. In order to prevent this behaviour we just get rid of the tasklet. It's not doing much anyway. Signed-off-by: Heiko Carstens <heiko.carstens@de.ibm.com> Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
2008-10-10[S390] console flush on panic / rebootHolger Smolinski
The s390 console drivers use the unblank callback of the console structure to flush the console buffer. In case of a panic or a reboot the CPU doing the callback can block on the console i/o. The other CPUs in the system continue to work. For panic this is not a good idea. Replace the unblank callback with proper panic/reboot notifier. These get called after all but one CPU have been stopped. Signed-off-by: Holger Smolinski <Holger.Smolinski@de.ibm.com> Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
2008-10-10[S390] Add ioctl support for EMC Symmetrix Subsystem Control I/ONigel Hislop
EMC Symmetrix Subsystem Control I/O through CKD dasd requires a specific parameter list sent to the array via a Perform Subsystem Function CCW. The Symmetrix response is retrieved from the array via a Read Subsystem Data CCW. Signed-off-by: Nigel Hislop <hislop_nigel@emc.com> Signed-off-by: Hannes Reinecke <hare@suse.de> Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
2008-10-10[S390] xpram: per device block request queues.Martin Schwidefsky
The xpram driver uses a single block device queue for all of its devices so far. With recent kernels removing xpram module fails to clean up all sysfs files. The next time the xpram module is loaded you'll get warnings: WARNING: at fs/sysfs/dir.c:463 sysfs_add_one+0x5e/0x64() sysfs: duplicate filename '35:0' can not be created Modules linked in: xpram(+) [last unloaded: xpram] Followed by the usual WARN_ON output, followed by an error message from kobject_add_internal, followed by a badness in genhd. Allocating a block queue per device fixes this. Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
2008-10-10[S390] dasd: fix message flood for unsolicited interruptsStefan Haberland
In the unsolicited interupt handler fake IRBs from CIO have to be ignored because there is nothing to do. The function dump_sense should not be called if there is no sense data available. Signed-off-by: Stefan Haberland <stefan.haberland@de.ibm.com> Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
2008-10-10[S390] Move private simple udelay function to arch/s390/lib/delay.c.Heiko Carstens
Move cio's private simple udelay function to lib/delay.c and turn it into something much more readable. So we have all implementations at one place. Signed-off-by: Heiko Carstens <heiko.carstens@de.ibm.com> Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
2008-10-10[S390] dcssblk: add >2G DCSSs support and stacked contiguous DCSSs support.Hongjie Yang
The DCSS block device driver is modified to add >2G DCSSs support and allow a DCSS block device to map to a set of contiguous DCSSs. The extmem code is also modified to use new Diagnose x'64' subcodes for >2G DCSSs. Signed-off-by: Hongjie Yang <hongjie@us.ibm.com> Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
2008-10-10[S390] qdio enhanced SIGA (iqdio) support.Klaus-Dieter Wacker
Add support for z10 HiperSockets multiwrite SBALs on output queues. This is used on LPAR with EDDP enabled devices. Signed-off-by: Klaus-Dieter Wacker <kdwacker@de.ibm.com> Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
2008-10-10[S390] cio: fix cio_tpi.Heiko Carstens
In cio_tpi only disable bottom halves when not in interrupt context. Otherwise a WARN_ON gets triggered. Besides that, when we are in interrupt context bottom halves are disabled anyway. Fixes this one: Badness at kernel/softirq.c:77 Modules linked in: CPU: 2 Not tainted 2.6.26 #4 Process swapper (pid: 0, task: 000000003fe83db0, ksp: 000000003fea7d28) Krnl PSW : 0404c00180000000 0000000000053f4e (__local_bh_disable+0xbe/0xcc) R:0 T:1 IO:0 EX:0 Key:0 M:1 W:0 P:0 AS:3 CC:0 PM:0 EA:3 Krnl GPRS: 0000000000008ee0 00000000005f95e0 0000000000000000 0000000000000001 000000000020be92 0000000000000000 0000000000000210 00000000005d36c0 000000003fb5f4d8 0000000000000000 000000000020bed0 000000003fb5f3c8 00000000009be920 0000000000364898 000000003fb5f408 000000003fb5f3c8 Krnl Code: 0000000000053f42: bf2f1000 icm %r2,15,0(%r1) 0000000000053f46: a774ffc5 brc 7,53ed0 0000000000053f4a: a7f40001 brc 15,53f4c >0000000000053f4e: a7280001 lhi %r2,1 0000000000053f52: 50201000 st %r2,0(%r1) 0000000000053f56: a7f4ffbd brc 15,53ed0 0000000000053f5a: 0707 bcr 0,%r7 0000000000053f5c: a7f13fc0 tmll %r15,16320 Call Trace: ([<0000000000000210>] 0x210) [<0000000000053f86>] local_bh_disable+0x2a/0x38 [<000000000020bed0>] wait_cons_dev+0xd4/0x154 [<0000000000247cb2>] raw3215_make_room+0x6a/0x1a8 [<000000000024861a>] raw3215_write+0x86/0x28c [<00000000002488a0>] con3215_write+0x80/0x110 [<000000000004c3e0>] __call_console_drivers+0xc8/0xe4 [<000000000004c47e>] _call_console_drivers+0x82/0xc4 [<000000000004c744>] release_console_sem+0x218/0x2c0 [<000000000004cf64>] vprintk+0x3c0/0x504 [<0000000000354a4a>] printk+0x52/0x64 [<0000000000088004>] __print_symbol+0x40/0x50 [<0000000000071dbc>] print_stack_trace+0x78/0xac [<0000000000079e78>] print_lock_dependencies+0x148/0x208 [<000000000007a050>] print_irq_inversion_bug+0x118/0x15c [<000000000007a106>] check_usage_forwards+0x72/0x84 [<000000000007a36e>] mark_lock+0x1d2/0x594 [<000000000007baca>] __lock_acquire+0x886/0xf48 [<000000000007c234>] lock_acquire+0xa8/0xe0 [<0000000000350316>] _write_lock+0x56/0x98 [<000000000026cd92>] zfcp_erp_adapter_reopen+0x4e/0x8c [<000000000026f1e8>] zfcp_qdio_int_resp+0x2e4/0x2f4 [<00000000002210f4>] qdio_int_handler+0x274/0x888 [<00000000002177b6>] ccw_device_call_handler+0x6e/0xd8 [<0000000000215336>] ccw_device_irq+0xd6/0x160 [<0000000000212f88>] io_subchannel_irq+0x8c/0x118 [<000000000020c120>] do_IRQ+0x1d0/0x1fc [<00000000000270b2>] io_return+0x0/0x8 [<000000000001c8a4>] cpu_idle+0x178/0x21c ([<000000000001c884>] cpu_idle+0x158/0x21c) [<00000000003483a2>] start_secondary+0xb6/0xc8 INFO: lockdep is turned off. Last Breaking-Event-Address: [<0000000000053f4a>] __local_bh_disable+0xba/0xcc Signed-off-by: Heiko Carstens <heiko.carstens@de.ibm.com> Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>