summaryrefslogtreecommitdiff
path: root/tools
diff options
context:
space:
mode:
authorBart Van Assche <bvanassche@acm.org>2019-11-01 14:14:47 -0700
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2020-01-23 08:18:41 +0100
commit6f6007cfb429f381215ef04660dc66f4932cb790 (patch)
tree736c54ffce9aefff0dcf83c939ffa10b0b3d3559 /tools
parent3780ff0f10ce52919a2a6c9e8ea7684e156d9f10 (diff)
scsi: core: scsi_trace: Use get_unaligned_be*()
commit b1335f5b0486f61fb66b123b40f8e7a98e49605d upstream. This patch fixes an unintended sign extension on left shifts. From Colin King: "Shifting a u8 left will cause the value to be promoted to an integer. If the top bit of the u8 is set then the following conversion to an u64 will sign extend the value causing the upper 32 bits to be set in the result." Fix this by using get_unaligned_be*() instead. Fixes: bf8162354233 ("[SCSI] add scsi trace core functions and put trace points") Cc: Christoph Hellwig <hch@lst.de> Cc: Hannes Reinecke <hare@suse.com> Cc: Douglas Gilbert <dgilbert@interlog.com> Link: https://lore.kernel.org/r/20191101211447.187151-1-bvanassche@acm.org Reported-by: Colin Ian King <colin.king@canonical.com> Signed-off-by: Bart Van Assche <bvanassche@acm.org> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'tools')
0 files changed, 0 insertions, 0 deletions