staging: gpib: Change return type and error code of fmh_gpib_get_dma_residue()
fmh_gpib_get_dma_residue() returns unsigned int with -1 as error code.
This error cannot be caught.
Fix this by changing the return type of the function to int and
returning the error code, that was captured. Also, change the data
type of variable residue to int in the function fmh_gpib_dma_read().
Fixes: 8e4841a0888c ("staging: gpib: Add Frank Mori Hess FPGA PCI GPIB driver")
Reported-by: Shuah Khan <skhan@linuxfoundation.org>
Signed-off-by: Everest K.C. <everestkc@everestkc.com.np>
Link: https://lore.kernel.org/r/20241017220740.30370-1-everestkc@everestkc.com.np
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>