summaryrefslogtreecommitdiffstats
path: root/drivers/ata/ahci.c
diff options
context:
space:
mode:
authorEzequiel Garcia2014-02-16 16:29:53 +0100
committerTejun Heo2014-02-16 17:51:17 +0100
commit8ad116e649b21a42e3cccfb3c1b8d5ea52ba19e5 (patch)
treec5a69d0a235864821b6ad4d46c9a280b72f95e7f /drivers/ata/ahci.c
parentsata_sil: apply MOD15WRITE quirk to TOSHIBA MK2561GSYN (diff)
downloadkernel-qcow2-linux-8ad116e649b21a42e3cccfb3c1b8d5ea52ba19e5.tar.gz
kernel-qcow2-linux-8ad116e649b21a42e3cccfb3c1b8d5ea52ba19e5.tar.xz
kernel-qcow2-linux-8ad116e649b21a42e3cccfb3c1b8d5ea52ba19e5.zip
ata: sata_mv: Cleanup only the initialized ports
When an error occurs in the port initialization loop, currently the driver tries to cleanup all the ports. This results in a NULL pointer dereference if the ports were only partially initialized. Fix this by updating only the number of initialized ports (either with failure or successfully), before jumping to the error path and looping over that number in the cleanup loop. Cc: Andrew Lunn <andrew@lunn.ch> Reported-by: Mikael Pettersson <mikpelinux@gmail.com> Signed-off-by: Ezequiel Garcia <ezequiel.garcia@free-electrons.com> Signed-off-by: Tejun Heo <tj@kernel.org> Cc: stable@vger.kernel.org
Diffstat (limited to 'drivers/ata/ahci.c')
0 files changed, 0 insertions, 0 deletions