Skip to content

Commit 0a84a0c

Browse files
josephlrgregkh
authored andcommitted
media: vicodec: Use _BITUL() macro in UAPI headers
[ Upstream commit ce67eac ] Replace BIT() in v4l2's UPAI header with _BITUL(). BIT() is not defined in the UAPI headers and its usage may cause userspace build errors. Fixes: 206bc0f ("media: vicodec: mark the stateless FWHT API as stable") Signed-off-by: Joe Richey <joerichey@google.com> Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl> Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org> Signed-off-by: Sasha Levin <sashal@kernel.org>
1 parent cf689b1 commit 0a84a0c

1 file changed

Lines changed: 12 additions & 11 deletions

File tree

‎include/uapi/linux/v4l2-controls.h‎

Lines changed: 12 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -50,6 +50,7 @@
5050
#ifndef __LINUX_V4L2_CONTROLS_H
5151
#define __LINUX_V4L2_CONTROLS_H
5252

53+
#include <linux/const.h>
5354
#include <linux/types.h>
5455

5556
/* Control classes */
@@ -1602,30 +1603,30 @@ struct v4l2_ctrl_h264_decode_params {
16021603
#define V4L2_FWHT_VERSION 3
16031604

16041605
/* Set if this is an interlaced format */
1605-
#define V4L2_FWHT_FL_IS_INTERLACED BIT(0)
1606+
#define V4L2_FWHT_FL_IS_INTERLACED _BITUL(0)
16061607
/* Set if this is a bottom-first (NTSC) interlaced format */
1607-
#define V4L2_FWHT_FL_IS_BOTTOM_FIRST BIT(1)
1608+
#define V4L2_FWHT_FL_IS_BOTTOM_FIRST _BITUL(1)
16081609
/* Set if each 'frame' contains just one field */
1609-
#define V4L2_FWHT_FL_IS_ALTERNATE BIT(2)
1610+
#define V4L2_FWHT_FL_IS_ALTERNATE _BITUL(2)
16101611
/*
16111612
* If V4L2_FWHT_FL_IS_ALTERNATE was set, then this is set if this
16121613
* 'frame' is the bottom field, else it is the top field.
16131614
*/
1614-
#define V4L2_FWHT_FL_IS_BOTTOM_FIELD BIT(3)
1615+
#define V4L2_FWHT_FL_IS_BOTTOM_FIELD _BITUL(3)
16151616
/* Set if the Y' plane is uncompressed */
1616-
#define V4L2_FWHT_FL_LUMA_IS_UNCOMPRESSED BIT(4)
1617+
#define V4L2_FWHT_FL_LUMA_IS_UNCOMPRESSED _BITUL(4)
16171618
/* Set if the Cb plane is uncompressed */
1618-
#define V4L2_FWHT_FL_CB_IS_UNCOMPRESSED BIT(5)
1619+
#define V4L2_FWHT_FL_CB_IS_UNCOMPRESSED _BITUL(5)
16191620
/* Set if the Cr plane is uncompressed */
1620-
#define V4L2_FWHT_FL_CR_IS_UNCOMPRESSED BIT(6)
1621+
#define V4L2_FWHT_FL_CR_IS_UNCOMPRESSED _BITUL(6)
16211622
/* Set if the chroma plane is full height, if cleared it is half height */
1622-
#define V4L2_FWHT_FL_CHROMA_FULL_HEIGHT BIT(7)
1623+
#define V4L2_FWHT_FL_CHROMA_FULL_HEIGHT _BITUL(7)
16231624
/* Set if the chroma plane is full width, if cleared it is half width */
1624-
#define V4L2_FWHT_FL_CHROMA_FULL_WIDTH BIT(8)
1625+
#define V4L2_FWHT_FL_CHROMA_FULL_WIDTH _BITUL(8)
16251626
/* Set if the alpha plane is uncompressed */
1626-
#define V4L2_FWHT_FL_ALPHA_IS_UNCOMPRESSED BIT(9)
1627+
#define V4L2_FWHT_FL_ALPHA_IS_UNCOMPRESSED _BITUL(9)
16271628
/* Set if this is an I Frame */
1628-
#define V4L2_FWHT_FL_I_FRAME BIT(10)
1629+
#define V4L2_FWHT_FL_I_FRAME _BITUL(10)
16291630

16301631
/* A 4-values flag - the number of components - 1 */
16311632
#define V4L2_FWHT_FL_COMPONENTS_NUM_MSK GENMASK(18, 16)

0 commit comments

Comments
 (0)