Is there a way to make a CUBLAS function write its return value to a device variable

Hi,

 This might be a very basic question. But I wasn't able to find anything mentioned about it in the manual. I am trying to run a bunch of cublasSdot functions and then, I ll need to use the calculated dot products again on the device. Having to get a return value from cublasSdot on the host and then again transferring it back to the device seems very round about. 

 Just giving a pointer to a device variable crashes the program.. I was wondering if someone knew of any way to make it return to a device variable. 

I would appreciate any help you could give me. Thanks…

Avinash