summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* ide-cd: remove cdrom_do_pc_continuation()Bartlomiej Zolnierkiewicz2008-02-011-13/+2
| | | | | | | cdrom_do_pc_continuation() is now identical to cdrom_do_newpc_cont() so just always use the latter function. Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
* ide-cd: merge cdrom_pc_intr() and cdrom_newpc_intr()Bartlomiej Zolnierkiewicz2008-02-011-113/+58
| | | | | | | | | | Add handling of REQ_TYPE_{SENSE,ATA_PC} requests to cdrom_newpc_intr() (please note that these requests never have 'bio' attached to them and they never use DMA), then remove no longer needed cdrom_pc_intr(). There should be no functionality changes caused by this patch. Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
* ide-cd: unify request end exit path in cdrom_pc_intr()Bartlomiej Zolnierkiewicz2008-02-011-12/+11
| | | | | | This is a preparation for cdrom_pc_intr() and cdrom_newpc_intr() merge. Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
* ide-cd: factor out request sense fixup from cdrom_pc_intr()Bartlomiej Zolnierkiewicz2008-02-011-10/+15
| | | | | | This is a preparation for cdrom_pc_intr() and cdrom_newpc_intr() merge. Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
* ide-cd: call blk_dump_rq_flags() on "missing data" in cdrom_newpc_intr()Bartlomiej Zolnierkiewicz2008-02-011-1/+5
| | | | | Acked-by: Sergei Shtylyov <sshtylyov@ru.mvista.com> Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
* ide-cd: remove BUG_ON() from cdrom_newpc_intr()Bartlomiej Zolnierkiewicz2008-02-011-2/+0
| | | | | | | There is no need for it anylonger and ide_set_handler() complains if ->handler is not NULL anyway. Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
* ide-cd: move code handling cdrom.c IOCTLs to ide-cd_ioctl.cBartlomiej Zolnierkiewicz2008-02-014-265/+290
| | | | | | There should be no functionality changes caused by this patch. Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
* ide-cd: rename cdrom_* functions to ide_cd_*Bartlomiej Zolnierkiewicz2008-02-011-39/+44
| | | | | | | | | | | | * cdrom_prepare_request() -> ide_cd_init_rq() * cdrom_queue_packet_command() -> ide_cd_queue_pc() * cdrom_lockdoor() -> ide_cd_lockdoor() * cdrom_read_toc() -> ide_cd_read_toc() * cdrom_get_toc_entry() -> ide_cd_get_toc_entry() This is a preparation to move code handling cdrom.c IOCTLs out of ide-cd.c. Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
* ide-cd: coding style fixes for cdrom_get_toc_entry()Bartlomiej Zolnierkiewicz2008-02-011-3/+5
| | | | | | | This is a preparation to move code handling cdrom.c IOCTLs out of ide-cd.c. Acked-by: Sergei Shtylyov <sshtylyov@ru.mvista.com> Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
* ide-cd: move lba_to_msf() and msf_to_lba() to <linux/cdrom.h>Bartlomiej Zolnierkiewicz2008-02-013-24/+14
| | | | | | | | | | * Move lba_to_msf() and msf_to_lba() to <linux/cdrom.h> (use 'u8' type instead of 'byte' while at it). * Remove msf_to_lba() copy from drivers/cdrom/cdrom.c. Acked-by: Jens Axboe <jens.axboe@oracle.com> Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
* ide-cd: merge cdrom_select_speed() into ide_cdrom_select_speed()Bartlomiej Zolnierkiewicz2008-02-011-37/+29
| | | | Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
* ide-cd: merge cdrom_read_subchannel() into ide_cdrom_get_mcn()Bartlomiej Zolnierkiewicz2008-02-011-32/+21
| | | | Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
* ide-cd: merge cdrom_play_audio() into ide_cd_fake_play_trkind()Bartlomiej Zolnierkiewicz2008-02-011-16/+10
| | | | Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
* ide-cd: factor out ioctl handlers from ide_cdrom_audio_ioctl()Bartlomiej Zolnierkiewicz2008-02-011-67/+75
| | | | Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
* ide-cd: move VERBOSE_IDE_CD_ERRORS code to ide-cd_verbose.cBartlomiej Zolnierkiewicz2008-02-015-358/+375
| | | | | | | | | | | | | | | | | | | | | | | | | | | | * Rename ide-cd kernel module to ide-cd_mod in preparation to moving code out from ide-cd.[c,h]. Add MODULE_ALIAS("ide-cd") to preserve compatibility. * Move VERBOSE_IDE_CD_ERRORS code from ide-cd.[c,h] to ide-cd_verbose.c. ide-cd_verbose.c is IDE subsystem independent and may be easily converted into generic library usable by other drivers (i.e. libata) if needed. * Add CONFIG_BLK_DEV_IDECD_VERBOSE_ERRORS config option to drivers/ide/Kconfig replacing VERBOSE_IDE_CD_ERRORS define. Make this config option enabled by default and visible only if CONFIG_EMBEDDED is defined. before the patch: text data bss dec hex filename 22841 360 1056 24257 5ec1 drivers/ide/ide-cd.o after the patch w/ CONFIG_BLK_DEV_IDECD_VERBOSE_ERRORS=y: text data bss dec hex filename 22857 360 1056 24273 5ed1 drivers/ide/ide-cd_mod.o after the patch w/ CONFIG_BLK_DEV_IDECD_VERBOSE_ERRORS=n: text data bss dec hex filename 15091 360 1056 16507 407b drivers/ide/ide-cd_mod.o Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
* ide-cd: coding style fixes for VERBOSE_IDE_CD_ERRORS codeBartlomiej Zolnierkiewicz2008-02-012-49/+49
| | | | | | | | | | * Coding style fixes for VERBOSE_IDE_CD_ERRORS code. * Add KERN_{ERR,CONT} printk() levels where needed. This is a preparation for moving this code out of ide-cd.[c,h]. Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
* ide-cd: remove duplicate sense keys definitions from ide-cd.hBartlomiej Zolnierkiewicz2008-02-011-17/+0
| | | | | | | ide-cd.c already uses sense keys definitions from <scsi/scsi.h>. Acked-by: Sergei Shtylyov <sshtylyov@ru.mvista.com> Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
* ide-cd: re-organize handling of quirky devicesBartlomiej Zolnierkiewicz2008-02-012-65/+85
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Re-organize handling of quirky devices: * Add struct cd_list_entry, ide_cd_quirks_list[] and ide_cd_flags() helper. * Set flags returned by ide_cd_flags() in ide_cdrom_setup(). * Add IDE_CD_FLAG_VERTOS_{300_SDD,600_ESD} and IDE_CD_FLAG_SANYO_3CD flags. * Move device quirks from ide_cdrom_setup() to ide_cd_quirks_list[]. * Rename IDE_CD_FLAG_NEC260 to IDE_CD_FLAG_PRE_ATAPI12 and handle quirky Stingray 8X CD-ROM using ide_cd_quirks_list[]. * Add IDE_CD_FLAG_FULL_CAPS_PAGE flag and handle quirky ACER 50X CD-ROM / WPI 32X CD-ROM using ide_cd_quirk_list[]. * Add IDE_CD_FLAG_PLAY_AUDIO_OK flag and handle quirky MATSHITA DVD-ROMs using ide_cd_quirks_list[]. * Add IDE_CD_FLAG_LE_SPEED_FIELDS flag and handle quirky ACER/AOpen 24X CD-ROM using ide_cd_quirk_list[]. * Fix some comments about quirky devices while at it. There should be no functionality changes caused by this patch. Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
* ide-cd: use BCD2BIN()/BIN2BCD() macros from <linux/bcd.h>Bartlomiej Zolnierkiewicz2008-02-011-23/+11
| | | | | | | Use BCD2BIN()/BIN2BCD() macros from <linux/bcd.h> and remove the local bcd2bin()/bin2bcd() inlines. Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
* ide-cd: remove STANDARD_ATAPI defineBartlomiej Zolnierkiewicz2008-02-012-43/+10
| | | | | | Remove STANDARD_ATAPI define + drive-by coding style fixes. Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
* ide-cd: remove NO_DOOR_LOCKING defineBartlomiej Zolnierkiewicz2008-02-012-10/+0
| | | | | Acked-by: Sergei Shtylyov <sshtylyov@ru.mvista.com> Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
* ide-cd: remove struct ide_cd_{config,state}_flagsBartlomiej Zolnierkiewicz2008-02-012-81/+87
| | | | | | | | | | | | | | | | | * Remove unused ->{writing,reserved} fields from struct ide_cd_config_flags. * Move ->max_speed from struct ide_cd_config_flags to struct cdrom_info. * Move ->current_speed from struct ide_cd_state_flags to struct cdrom_info. * Add defines for config and state flags. * Add 'unsigned int cd_flags' to struct cdrom_info and use ->cd_flags instead of ->{config,state}_flags. * Remove no longer needed struct ide_cd_{config,state}_flags. Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
* ide-cd: remove struct atapi_capabilities_page (take 2)Bartlomiej Zolnierkiewicz2008-02-012-248/+37
| | | | | | | | | | | | | * Remove struct atapi_capabilities_page. * Add ATAPI_CAPABILITIES_PAGE[_PAD]_SIZE define. v2: * The buf[] array access indexes were swapped between 'curspeed'/'maxspeed'. (Noticed by Borislav Petkov). Cc: Borislav Petkov <bbpetkov@yahoo.de> Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
* ide-cd: kill CDROM_STATE_FLAGS() macroBartlomiej Zolnierkiewicz2008-02-012-22/+24
| | | | | | While at it rename 'info' variable to 'cd' in cdrom_saw_media_change(). Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
* ide-cd: kill CDROM_CONFIG_FLAGS() macroBartlomiej Zolnierkiewicz2008-02-012-48/+50
| | | | | | | While at it rename 'info' variable to 'cd' in ide_cdrom_probe_capabilities() and ide_cdrom_setup(). Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
* ide-cd: remove redundant config flagsBartlomiej Zolnierkiewicz2008-02-012-70/+38
| | | | | | | | | * Use CDC_* flags directly and remove redundant flags from ->config_flags. While at it: * Add KERN_CONT to printk()-s in ide_cdrom_probe_capabilities(). Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
* ide-cd: add IDE_CD_CAPABILITIES defineBartlomiej Zolnierkiewicz2008-02-011-12/+7
| | | | | | While at it remove stale/incorrect comment. Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
* ide-cd: cleanup ide_cdrom_update_speed()Bartlomiej Zolnierkiewicz2008-02-011-8/+9
| | | | | Acked-by: Sergei Shtylyov <sshtylyov@ru.mvista.com> Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
* ide-cd: remove struct atapi_{mechstat_header,changer_info,slot}Bartlomiej Zolnierkiewicz2008-02-012-56/+0
| | | | | | | | | * Remove ->changer_info from struct cdrom_info (it is never allocated). * Remove unused struct atapi_{mechstat_header,changer_info,slot}. Acked-by: Sergei Shtylyov <sshtylyov@ru.mvista.com> Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
* ide-cd: remove unused and write-only struct ide_cd_config_flags fieldsBartlomiej Zolnierkiewicz2008-02-012-23/+2
| | | | | | | | | | | | | | | unused fields: * ->writing * ->reserved write-only fields: * ->playmsf_as_bcd * ->subchan_as_bcd * ->test_write * ->supp_disc_present Acked-by: Sergei Shtylyov <sshtylyov@ru.mvista.com> Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
* ide-cd: remove needless zeroing of 'info' fields from ide_cdrom_setup()Bartlomiej Zolnierkiewicz2008-02-011-37/+7
| | | | | | | | | | | ide_cd_probe() zeroes 'info' prior to calling ide_cdrom_setup() so there is no need to explicitly zero 'info' fields in the latter function. Ditto for fields of CDROM_STATE_FLAGS(), CDROM_CONFIG_FLAGS() and 'cdi' (all are embedded in 'info'). Acked-by: Sergei Shtylyov <sshtylyov@ru.mvista.com> Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
* ide-cd: remove unused struct atapi_cdrom_subchnlBartlomiej Zolnierkiewicz2008-02-011-32/+0
| | | | | Acked-by: Sergei Shtylyov <sshtylyov@ru.mvista.com> Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
* ide-cd: remove dead code from cdrom_pc_intr()Bartlomiej Zolnierkiewicz2008-02-011-7/+0
| | | | | Acked-by: Sergei Shtylyov <sshtylyov@ru.mvista.com> Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
* ide-cd: remove unused defines from ide-cd.hBartlomiej Zolnierkiewicz2008-02-011-10/+0
| | | | | Acked-by: Sergei Shtylyov <sshtylyov@ru.mvista.com> Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
* ide-cd: remove stale cdrom_transfer_packet_command() commentBartlomiej Zolnierkiewicz2008-02-011-4/+0
| | | | | Acked-by: Sergei Shtylyov <sshtylyov@ru.mvista.com> Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
* ide-cd: move historical changelog to ↵Bartlomiej Zolnierkiewicz2008-02-012-270/+272
| | | | | | Documentation/ide/ChangeLog.ide-cd.1994-2004 Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
* ide-cd: fix trailing whitespaces in changelogBartlomiej Zolnierkiewicz2008-02-011-12/+11
| | | | | Acked-by: Sergei Shtylyov <sshtylyov@ru.mvista.com> Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
* ide-cd: fix DMA error handling in cdrom_newpc_intr()Bartlomiej Zolnierkiewicz2008-02-011-4/+6
| | | | | | | | | | | | Make cdrom_newpc_intr() match cdrom_{read,write}_intr() w.r.t. handling DMA errors: * disable DMA before cdrom_decode_status() call * log the device name and the type of the request (read/write) Acked-by: Sergei Shtylyov <sshtylyov@ru.mvista.com> Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
* ide-cd: fix "missing data" handling in cdrom_pc_intr()Bartlomiej Zolnierkiewicz2008-02-011-3/+4
| | | | | | | | If drive still wants to transfer the data we need to pad the transfer instead of just finishing the request. Acked-by: Sergei Shtylyov <sshtylyov@ru.mvista.com> Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
* ide-cd: add ide_cd_pad_transfer() helperBartlomiej Zolnierkiewicz2008-02-011-26/+25
| | | | | | | | | Add ide_cd_pad_transfer() helper and use it in cdrom_[new]pc_intr() and cdrom_{read,write}_check_ireason(). There should be no functionality changes caused by this patch. Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
* ide-cd: use xfer_func_t in cdrom_pc_intr()Bartlomiej Zolnierkiewicz2008-02-011-30/+17
| | | | | | | | Unify writing and reading handling in cdrom_pc_intr() using xfer_func_t. There should be no functionality changes caused by this patch. Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
* ide/ppc/pmac.c section fixesAdrian Bunk2008-02-011-2/+2
| | | | | | | | | | | | | | | This patch fixes the following section mismatch: <-- snip --> ... WARNING: vmlinux.o(.text+0x3b641c): Section mismatch in reference from the function .pmac_ide_setup_device() to the function .init.text:.pmac_ide_setup_dma() ... <-- snip --> Signed-off-by: Adrian Bunk <bunk@kernel.org> Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
* ide: make wait_drive_not_busy() static againAdrian Bunk2008-02-012-3/+1
| | | | | | | | After commit 7267c3377443322588cddaf457cf106839a60463 wait_drive_not_busy() can become static again. Signed-off-by: Adrian Bunk <bunk@kernel.org> Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
* ide: small ide-scan-pci.c cleanupAdrian Bunk2008-02-012-8/+2
| | | | | | | | | - ide_scan_pcibus() can become static - instead of ide_scan_pci() we can use ide_scan_pcibus() directly in module_init() Signed-off-by: Adrian Bunk <bunk@kernel.org> Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
* ide: unexport ide_dma_onAdrian Bunk2008-02-011-2/+0
| | | | | | | | ide_dma_on can be unexported. Signed-off-by: Adrian Bunk <bunk@kernel.org> Cc: Sergei Shtylyov <sshtylyov@ru.mvista.com> Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
* ide/Kconfig: use 'on-board' instead of 'built-in' in config optionsFrans Pop2008-02-011-23/+23
| | | | | | | | | | | | | To avoid confusion between 'built-in' drivers and 'on-board' controllers, consistently use the term 'on-board' for controllers. Minor line-wrapping improvements in descriptions for config options. [ Bart: thanks to Jan for 'built-in'->'on-board' suggestion ] Signed-off-by: Frans Pop <elendil@planet.nl> Cc: Jan Engelhardt <jengelh@computergmbh.de> Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
* Atari Falcon IDE: Add missing hwif variableGeert Uytterhoeven2008-02-011-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | Commit cbb010c180294a5242a7681555c28737d9dd26ab ide: drop 'initializing' argument from ide_register_hw() * Rename init_hwif_data() to ide_init_port_data() and export it. * For all users of ide_register_hw() with 'initializing' argument set hwif->present and hwif->hold are always zero so convert these host drivers to use ide_find_port()+ide_init_port_data()+ide_init_port_hw() instead (also no need for init_hwif_default() call since the setup done by it gets over-ridden by ide_init_port_hw() call). * Drop 'initializing' argument from ide_register_hw(). introduced the usage of a hwif variable, but forgot to declare the actual variable. Signed-off-by: Geert Uytterhoeven <geert@linux-m68k.org> Cc: Sergei Shtylyov <sshtylyov@ru.mvista.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
* Merge branch 'for-linus' of git://git.kernel.dk/linux-2.6-blockLinus Torvalds2008-02-0117-254/+220
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | * 'for-linus' of git://git.kernel.dk/linux-2.6-block: block: kill swap_io_context() as-iosched: fix inconsistent ioc->lock context ide-cd: fix leftover data BUG block: make elevator lib checkpatch compliant cfq-iosched: make checkpatch compliant block: make core bits checkpatch compliant block: new end request handling interface should take unsigned byte counts unexport add_disk_randomness block/sunvdc.c:print_version() must be __devinit splice: always updated atime in direct splice
| * block: kill swap_io_context()Jens Axboe2008-02-013-24/+0
| | | | | | | | | | | | | | | | | | | | It blindly copies everything in the io_context, including the lock. That doesn't work so well for either lock ordering or lockdep. There seems zero point in swapping io contexts on a request to request merge, so the best point of action is to just remove it. Signed-off-by: Jens Axboe <jens.axboe@oracle.com>
| * as-iosched: fix inconsistent ioc->lock contextJens Axboe2008-02-011-4/+6
| | | | | | | | | | | | | | | | | | | | | | Since it's acquired from irq context, all locking must be of the irq safe variant. Most are already inside the queue lock (which already disables interrupts), but the io scheduler rmmod path always has irqs enabled and the put_io_context() path may legally be called with irqs enabled (even if it isn't usually). So fixup those two. Signed-off-by: Jens Axboe <jens.axboe@oracle.com>
OpenPOWER on IntegriCloud