Lines Matching refs:opcr

1359 static inline u32 get_opcr(__be32 opcr, u32 mask, u32 shift)  in get_opcr()  argument
1361 return (be32_to_cpu(opcr) >> shift) & mask; in get_opcr()
1364 static inline void set_opcr(__be32 *opcr, u32 value, u32 mask, u32 shift) in set_opcr() argument
1366 *opcr &= ~cpu_to_be32(mask << shift); in set_opcr()
1367 *opcr |= cpu_to_be32((value & mask) << shift); in set_opcr()
1381 __be32 old_opcr, opcr[2]; in cmp_establish_pp_connection() local
1386 ret = cmp_read(fdtv, opcr_address, opcr); in cmp_establish_pp_connection()
1391 if (!get_opcr_online(*opcr)) { in cmp_establish_pp_connection()
1396 old_opcr = *opcr; in cmp_establish_pp_connection()
1398 if (get_opcr_p2p_connections(*opcr)) { in cmp_establish_pp_connection()
1399 if (get_opcr_channel(*opcr) != channel) { in cmp_establish_pp_connection()
1407 set_opcr_channel(opcr, channel); in cmp_establish_pp_connection()
1408 set_opcr_data_rate(opcr, 2); /* S400 */ in cmp_establish_pp_connection()
1411 set_opcr_overhead_id(opcr, 0); in cmp_establish_pp_connection()
1416 set_opcr_p2p_connections(opcr, get_opcr_p2p_connections(*opcr) + 1); in cmp_establish_pp_connection()
1418 opcr[1] = *opcr; in cmp_establish_pp_connection()
1419 opcr[0] = old_opcr; in cmp_establish_pp_connection()
1421 ret = cmp_lock(fdtv, opcr_address, opcr); in cmp_establish_pp_connection()
1425 if (old_opcr != *opcr) { in cmp_establish_pp_connection()
1441 __be32 old_opcr, opcr[2]; in cmp_break_pp_connection() local
1445 if (cmp_read(fdtv, opcr_address, opcr) < 0) in cmp_break_pp_connection()
1449 if (!get_opcr_online(*opcr) || !get_opcr_p2p_connections(*opcr) || in cmp_break_pp_connection()
1450 get_opcr_channel(*opcr) != channel) { in cmp_break_pp_connection()
1455 old_opcr = *opcr; in cmp_break_pp_connection()
1456 set_opcr_p2p_connections(opcr, get_opcr_p2p_connections(*opcr) - 1); in cmp_break_pp_connection()
1458 opcr[1] = *opcr; in cmp_break_pp_connection()
1459 opcr[0] = old_opcr; in cmp_break_pp_connection()
1461 if (cmp_lock(fdtv, opcr_address, opcr) < 0) in cmp_break_pp_connection()
1464 if (old_opcr != *opcr) { in cmp_break_pp_connection()