cancel
Showing results for 
Search instead for 
Did you mean: 

Archives Discussions

adamhsu
Journeyman III

Is it possible to open cl in kernel mode os driver?

Hi, all

I am freshman for open cl. Now, I have one idea about to use open cl to caculate something on kernel mode os driver. I can link the opencl.lib (x86 or x86_64) into our driver image successfully but it will causes os blue screen when to load this driver image.

I don't know what happens and what I did is just to call clGetPlaformIDs function in our driver image. But, I can't make sure it is killer or not due to I can't set any breakpoint in our driver (it seems the driver image didn't load). But, everything is fine if NOT to call clGetPlaformIDs( ).

My question is

(1)Is it possible to use the open cl in any kernel mode os driver? If the answer is YES, how to do? Or, anything I missed in my step?

Thanks a lot.

0 Likes
5 Replies
DTop
Staff

.

0 Likes

adamhsu,

I am not able to understand what you are trying to do?

What do you mean by kernel mode os driver?

0 Likes

oh~ sorry

What I mean is whether I can use the OpenCL API directly in some kernel drivers like RAID driver. My purpose is to speed up the time to caculate something.

Thanks.

0 Likes

adamhsu,

I appears to me that you are trying to run some service from kernel space of the system.  And you are trying to link a userspace library (OpenCL.lib).

But according to this link you cannot include any userspace library in the kernel source.

http://stackoverflow.com/questions/817487/compile-linux-kernel-2-6-module-including-non-kernel-heade...

http://www.linuxquestions.org/questions/linux-newbie-8/how-to-link-a-static-library-to-a-kernel-modu...

Is this what you are looking for?

0 Likes

he talk about blue screen s i think he is working on windows.

0 Likes