P4 to Git Change 1206608 by gandryey@gera-w8 on 2015/11/02 16:34:49
SWDEV-78467 - OpenCL LiquidFlash feature - Return an error if sizes are unaligned Affected files ... ... //depot/stg/opencl/drivers/opencl/api/opencl/amdocl/cl_lqdflash_amd.cpp#9 edit
This commit is contained in:
@@ -192,7 +192,11 @@ RUNTIME_ENTRY(cl_int, clEnqueueWriteBufferFromFileAMD, (
|
||||
amd::Coord3D dstOffset(buffer_offset, 0, 0);
|
||||
amd::Coord3D dstSize(cb, 1, 1);
|
||||
|
||||
if(!dstBuffer->validateRegion(dstOffset, dstSize)) {
|
||||
if ((!dstBuffer->validateRegion(dstOffset, dstSize)) ||
|
||||
// LF library supports aligned sizes only
|
||||
((buffer_offset % amdFile->blockSize()) != 0) ||
|
||||
((cb % amdFile->blockSize()) != 0) ||
|
||||
((file_offset % amdFile->blockSize()) != 0)) {
|
||||
return CL_INVALID_VALUE;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user