From c0668f05ea1e2429444d6aad2a40dda81aba7ec8 Mon Sep 17 00:00:00 2001 From: Terje Bergstrom Date: Mon, 10 Nov 2014 10:34:24 +0200 Subject: gpu: nvgpu: Retrieve intr & reset id from HW Query interrupt number and reset id from HW. Use the number from HW when enabling and detecting interrupts. Bug 200036089 Bug 1567274 Change-Id: If9cb4db79a19dcb193ba7ad9db7081f4fe1ab433 Signed-off-by: Terje Bergstrom Reviewed-on: http://git-master/r/600988 --- drivers/gpu/nvgpu/gk20a/hw_top_gk20a.h | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) (limited to 'drivers/gpu/nvgpu/gk20a/hw_top_gk20a.h') diff --git a/drivers/gpu/nvgpu/gk20a/hw_top_gk20a.h b/drivers/gpu/nvgpu/gk20a/hw_top_gk20a.h index ab527d25..f3ca7498 100644 --- a/drivers/gpu/nvgpu/gk20a/hw_top_gk20a.h +++ b/drivers/gpu/nvgpu/gk20a/hw_top_gk20a.h @@ -1,5 +1,5 @@ /* - * Copyright (c) 2012-2013, NVIDIA CORPORATION. All rights reserved. + * Copyright (c) 2012-2014, NVIDIA CORPORATION. All rights reserved. * * This program is free software; you can redistribute it and/or modify it * under the terms and conditions of the GNU General Public License, @@ -98,6 +98,14 @@ static inline u32 top_device_info_runlist_enum_v(u32 r) { return (r >> 21) & 0xf; } +static inline u32 top_device_info_intr_enum_v(u32 r) +{ + return (r >> 15) & 0x1f; +} +static inline u32 top_device_info_reset_enum_v(u32 r) +{ + return (r >> 9) & 0x1f; +} static inline u32 top_device_info_type_enum_v(u32 r) { return (r >> 2) & 0x1fffffff; -- cgit v1.2.2