]> err.no Git - linux-2.6/commit
ide: rework PowerMac media-bay support (take 2)
authorBartlomiej Zolnierkiewicz <bzolnier@gmail.com>
Thu, 17 Apr 2008 22:46:23 +0000 (00:46 +0200)
committerBartlomiej Zolnierkiewicz <bzolnier@gmail.com>
Thu, 17 Apr 2008 22:46:23 +0000 (00:46 +0200)
commit2dde7861afa23cd59db83515cb0b810b92b220aa
treee2cfda1c75d2157fde3801d29e2bcbebf1d5a129
parent26042d058ba21305aeb8ac92e4b1483dbec642ac
ide: rework PowerMac media-bay support (take 2)

Rework PowerMac media-bay support in such way that instead of
un/registering the IDE interface we un/register IDE devices:

* Add ide_port_scan() helper for probing+registerering devices on a port.

* Rename ide_port_unregister_devices() to __ide_port_unregister_devices().

* Add ide_port_unregister_devices() helper for unregistering devices on a port.

* Add 'ide_hwif_t *cd_port' to 'struct media_bay_info', pass 'hwif' instead
  of hwif->index to media_bay_set_ide_infos() and use it to setup 'cd_port'.

* Use ide_port_unregister_devices() instead of ide_unregister()
  and ide_port_scan() instead of ide_register_hw() in media_bay_step().

* Unexport ide_register_hw() and make it static.

v2:
* Fix build by adding <linux/ide.h> include to <asm-powerpc/mediabay.h>.
  (Reported by Michael/Kamalesh/Andrew).

Cc: Kamalesh Babulal <kamalesh@linux.vnet.ibm.com>
Cc: Michael Ellerman <michael@ellerman.id.au>
Cc: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
drivers/ide/ide-probe.c
drivers/ide/ide.c
drivers/ide/ppc/pmac.c
drivers/macintosh/mediabay.c
include/asm-powerpc/mediabay.h
include/linux/ide.h