libata: zpodd: small read overflow in eject_tray()
authorDan Carpenter <dan.carpenter@oracle.com>
Tue, 29 May 2018 09:13:24 +0000 (12:13 +0300)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Tue, 26 Jun 2018 00:06:32 +0000 (08:06 +0800)
commit27c0f1e5d94d90ef07a3c33fe20996c403fbbf9e
tree60606a6f14bdd012048d35e53e0dd4b39b5d2e7c
parent1404d2e5dd3647d9bec8960c7dc90aea7cbd8b63
libata: zpodd: small read overflow in eject_tray()

commit 18c9a99bce2a57dfd7e881658703b5d7469cc7b9 upstream.

We read from the cdb[] buffer in ata_exec_internal_sg().  It has to be
ATAPI_CDB_LEN (16) bytes long, but this buffer is only 12 bytes.

Fixes: 213342053db5 ("libata: handle power transition of ODD")
Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Tejun Heo <tj@kernel.org>
Cc: stable@vger.kernel.org
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/ata/libata-zpodd.c