Files
linux/drivers/ata
Zheyu Ma 14bae84c4a ata: pata_marvell: Check the 'bmdma_addr' beforing reading
commit aafa9f9583 upstream.

Before detecting the cable type on the dma bar, the driver should check
whether the 'bmdma_addr' is zero, which means the adapter does not
support DMA, otherwise we will get the following error:

[    5.146634] Bad IO access at port 0x1 (return inb(port))
[    5.147206] WARNING: CPU: 2 PID: 303 at lib/iomap.c:44 ioread8+0x4a/0x60
[    5.150856] RIP: 0010:ioread8+0x4a/0x60
[    5.160238] Call Trace:
[    5.160470]  <TASK>
[    5.160674]  marvell_cable_detect+0x6e/0xc0 [pata_marvell]
[    5.161728]  ata_eh_recover+0x3520/0x6cc0
[    5.168075]  ata_do_eh+0x49/0x3c0

Signed-off-by: Zheyu Ma <zheyuma97@gmail.com>
Signed-off-by: Damien Le Moal <damien.lemoal@opensource.wdc.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2023-06-29 09:26:10 +09:00
..
2023-05-16 11:26:03 +09:00
2016-09-06 12:38:17 -04:00
2023-05-16 12:08:57 +09:00
2023-05-16 11:02:31 +09:00
2023-05-16 11:02:32 +09:00
2008-01-23 05:24:15 -05:00
2007-07-02 10:17:42 -04:00