ide: PCI BMDMA initialization fixes (take 2)

* Set hwif->dma_base only if allocation of extra ports succeeds.

While at it:

* Move setting of hwif->dma_{base,master} from ide_{mapped_mmio,iomio}_dma()
  to ide_setup_dma().

* Rename 'dma_base' argument to 'base' in ide_setup_dma() (to make the code
  obey 80-columns limit and increase its readability).

* Remove stale ide_setup_dma() comment.

v2:
* Change to allocate hwif->dmatable_cpu before reserving I/O ports missed
  teardown code (spotted by Sergei).  On the second thought this change is
  actually unnecessary so revert it in v2.

* Make ide_release_dma_engine() void and remove needless comment.

Cc: Sergei Shtylyov <sshtylyov@ru.mvista.com>
Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
1 file changed