gpu: disable cyclestats whitelist in debug mode

Disable cyclestats register whitelist check if allow_all is
enabled through sysfs.

bug 1523403
bug 1490388

Change-Id: Iaa1cf9a8fed18f1a379cac28128793fb33567f35
Signed-off-by: Kirill Artamonov <kartamonov@nvidia.com>
Reviewed-on: http://git-master/r/454932
Reviewed-by: Automatic_Commit_Validation_User
GVS: Gerrit_Virtual_Submit
Reviewed-by: Terje Bergstrom <tbergstrom@nvidia.com>
This commit is contained in:
Kirill Artamonov
2014-08-11 11:43:38 +03:00
committed by Dan Willemsen
parent 5dea7c4729
commit 569e8e5e89

View File

@@ -5058,6 +5058,10 @@ static inline bool is_valid_cyclestats_bar0_offset_gk20a(struct gk20a *g,
{
/* support only 24-bit 4-byte aligned offsets */
bool valid = !(offset & 0xFF000003);
if (g->allow_all)
return true;
/* whitelist check */
valid = valid &&
is_bar0_global_offset_whitelisted_gk20a(offset);