X-Git-Url: https://git.karo-electronics.de/?a=blobdiff_plain;f=drivers%2Fmedia%2Fvideo%2Fivtv%2Fivtv-driver.h;fp=drivers%2Fmedia%2Fvideo%2Fivtv%2Fivtv-driver.h;h=04bacdbd10bbf6053fbb0e9ff162bfd12bf1d357;hb=59f40aff7930052a74ddf5c297aa1974b0838529;hp=75803141481e30aee323ca4ee14fa34ebea88590;hpb=291b7c3a02a7eafbb8ea89a2c0e93676d6972926;p=mv-sheeva.git diff --git a/drivers/media/video/ivtv/ivtv-driver.h b/drivers/media/video/ivtv/ivtv-driver.h index 75803141481..04bacdbd10b 100644 --- a/drivers/media/video/ivtv/ivtv-driver.h +++ b/drivers/media/video/ivtv/ivtv-driver.h @@ -811,15 +811,23 @@ static inline int ivtv_raw_vbi(const struct ivtv *itv) /* Call the specified callback for all subdevs matching hw (if 0, then match them all). Ignore any errors. */ #define ivtv_call_hw(itv, hw, o, f, args...) \ - __v4l2_device_call_subdevs(&(itv)->v4l2_dev, !(hw) || (sd->grp_id & (hw)), o, f , ##args) + do { \ + struct v4l2_subdev *__sd; \ + __v4l2_device_call_subdevs_p(&(itv)->v4l2_dev, __sd, \ + !(hw) || (__sd->grp_id & (hw)), o, f , ##args); \ + } while (0) #define ivtv_call_all(itv, o, f, args...) ivtv_call_hw(itv, 0, o, f , ##args) /* Call the specified callback for all subdevs matching hw (if 0, then match them all). If the callback returns an error other than 0 or -ENOIOCTLCMD, then return with that error code. */ -#define ivtv_call_hw_err(itv, hw, o, f, args...) \ - __v4l2_device_call_subdevs_until_err(&(itv)->v4l2_dev, !(hw) || (sd->grp_id & (hw)), o, f , ##args) +#define ivtv_call_hw_err(itv, hw, o, f, args...) \ +({ \ + struct v4l2_subdev *__sd; \ + __v4l2_device_call_subdevs_until_err_p(&(itv)->v4l2_dev, __sd, \ + !(hw) || (__sd->grp_id & (hw)), o, f , ##args); \ +}) #define ivtv_call_all_err(itv, o, f, args...) ivtv_call_hw_err(itv, 0, o, f , ##args)