Center European Research Science informatics

...because open source matters

  • Increase font size
  • Default font size
  • Decrease font size
Home New Kernel API Changes

New Kernel API changes

E-mail Print PDF

New Kernel header changes!

Rather than a link to a huge text file, it might have been useful to
include the failure mode, which is this:

v4l2_calls.c:268: error: 'V4L2_CID_HCENTER' undeclared (first use in this function)
v4l2_calls.c:268: error: (Each undeclared identifier is reported only once
v4l2_calls.c:268: error: for each function it appears in.)
v4l2_calls.c:269: error: 'V4L2_CID_VCENTER' undeclared (first use in this function)

A few moments with git-annotate showed that the missing ioctls were
removed in commit 26d507fcfef7f7d0cd2eec874a87169cc121c835ยน by Brandon
Philips. In their place, we have the following:

/* Deprecated, use V4L2_CID_PAN_RESET and V4L2_CID_TILT_RESET */
#define V4L2_CID_HCENTER_DEPRECATED     (V4L2_CID_BASE+22)
#define V4L2_CID_VCENTER_DEPRECATED     (V4L2_CID_BASE+23)

That seems like a rather dubious change to the user API -- shouldn't we
ensure that existing software continues to build, but maybe add a
compile-time or run-time warning for those using the deprecated ioctls?

You can now joyfully change
#define V4L2_CID_HCENTER to #define V4L2_CID_HCENTER_DEPRECATED (V4L2_CID_BASE+22)

and

#define V4L2_CID_VCENTER to #define V4L2_CID_VCENTER_DEPRECATED (V4L2_CID_BASE+23)

and do not forget to change all occurrence of V4L2_CID_HCENTER to V4L2_CID_HCENTER_DEPRECATED

and all occurrence of V4L2_CID_VCENTER to V4L2_CID_VCENTER_DEPRECATED
 

Newsflash

Stil to do