Lines Matching refs:pat
774 vidtv_psi_pat_table_update_sec_len(struct vidtv_psi_table_pat *pat) in vidtv_psi_pat_table_update_sec_len() argument
785 for (i = 0; i < pat->num_pat; ++i) in vidtv_psi_pat_table_update_sec_len()
791 vidtv_psi_set_sec_len(&pat->header, length); in vidtv_psi_pat_table_update_sec_len()
904 vidtv_psi_pat_program_assign(struct vidtv_psi_table_pat *pat, in vidtv_psi_pat_program_assign() argument
914 if (p == pat->program) in vidtv_psi_pat_program_assign()
922 pat->num_pat = program_count; in vidtv_psi_pat_program_assign()
923 pat->program = p; in vidtv_psi_pat_program_assign()
926 vidtv_psi_pat_table_update_sec_len(pat); in vidtv_psi_pat_program_assign()
929 } while (vidtv_psi_get_sec_len(&pat->header) > MAX_SECTION_LEN); in vidtv_psi_pat_program_assign()
931 vidtv_psi_update_version_num(&pat->header); in vidtv_psi_pat_program_assign()
936 struct vidtv_psi_table_pat *pat; in vidtv_psi_pat_table_init() local
941 pat = kzalloc(sizeof(*pat), GFP_KERNEL); in vidtv_psi_pat_table_init()
942 if (!pat) in vidtv_psi_pat_table_init()
945 pat->header.table_id = 0x0; in vidtv_psi_pat_table_init()
947 pat->header.bitfield = cpu_to_be16((SYNTAX << 15) | (ZERO << 14) | (ONES << 12)); in vidtv_psi_pat_table_init()
948 pat->header.id = cpu_to_be16(transport_stream_id); in vidtv_psi_pat_table_init()
949 pat->header.current_next = 0x1; in vidtv_psi_pat_table_init()
951 pat->header.version = 0x1f; in vidtv_psi_pat_table_init()
953 pat->header.one2 = 0x03; in vidtv_psi_pat_table_init()
954 pat->header.section_id = 0x0; in vidtv_psi_pat_table_init()
955 pat->header.last_section = 0x0; in vidtv_psi_pat_table_init()
957 vidtv_psi_pat_table_update_sec_len(pat); in vidtv_psi_pat_table_init()
959 return pat; in vidtv_psi_pat_table_init()
964 struct vidtv_psi_table_pat_program *p = args->pat->program; in vidtv_psi_pat_write_into()
969 .h = &args->pat->header, in vidtv_psi_pat_write_into()
989 vidtv_psi_pat_table_update_sec_len(args->pat); in vidtv_psi_pat_write_into()
1097 struct vidtv_psi_table_pat *pat) in vidtv_psi_pmt_get_pid() argument
1099 struct vidtv_psi_table_pat_program *program = pat->program; in vidtv_psi_pmt_get_pid()
1478 vidtv_psi_pmt_create_sec_for_each_pat_entry(struct vidtv_psi_table_pat *pat, in vidtv_psi_pmt_create_sec_for_each_pat_entry() argument
1490 program = pat->program; in vidtv_psi_pmt_create_sec_for_each_pat_entry()
1503 for (program = pat->program; program; program = program->next) { in vidtv_psi_pmt_create_sec_for_each_pat_entry()
1518 pat->num_pmt = num_pmt; in vidtv_psi_pmt_create_sec_for_each_pat_entry()