#include <linux/kernel.h>
#include <linux/string.h>
#include <linux/videodev2.h>
#include "coda.h"
static const u8 coda_filler_size[8] = …;
static const u8 *coda_find_nal_header(const u8 *buf, const u8 *end)
{ … }
int coda_sps_parse_profile(struct coda_ctx *ctx, struct vb2_buffer *vb)
{ … }
int coda_h264_filler_nal(int size, char *p)
{ … }
int coda_h264_padding(int size, char *p)
{ … }
int coda_h264_profile(int profile_idc)
{ … }
int coda_h264_level(int level_idc)
{ … }
struct rbsp { … };
static inline int rbsp_read_bit(struct rbsp *rbsp)
{ … }
static inline int rbsp_write_bit(struct rbsp *rbsp, int bit)
{ … }
static inline int rbsp_read_bits(struct rbsp *rbsp, int num, int *val)
{ … }
static int rbsp_write_bits(struct rbsp *rbsp, int num, int value)
{ … }
static int rbsp_read_uev(struct rbsp *rbsp, unsigned int *val)
{ … }
static int rbsp_write_uev(struct rbsp *rbsp, unsigned int value)
{ … }
static int rbsp_read_sev(struct rbsp *rbsp, int *val)
{ … }
int coda_h264_sps_fixup(struct coda_ctx *ctx, int width, int height, char *buf,
int *size, int max_size)
{ … }