Lines Matching refs:opcr

1357 static inline u32 get_opcr(__be32 opcr, u32 mask, u32 shift)  in get_opcr()  argument
1359 return (be32_to_cpu(opcr) >> shift) & mask; in get_opcr()
1362 static inline void set_opcr(__be32 *opcr, u32 value, u32 mask, u32 shift) in set_opcr() argument
1364 *opcr &= ~cpu_to_be32(mask << shift); in set_opcr()
1365 *opcr |= cpu_to_be32((value & mask) << shift); in set_opcr()
1379 __be32 old_opcr, opcr[2]; in cmp_establish_pp_connection() local
1384 ret = cmp_read(fdtv, opcr_address, opcr); in cmp_establish_pp_connection()
1389 if (!get_opcr_online(*opcr)) { in cmp_establish_pp_connection()
1394 old_opcr = *opcr; in cmp_establish_pp_connection()
1396 if (get_opcr_p2p_connections(*opcr)) { in cmp_establish_pp_connection()
1397 if (get_opcr_channel(*opcr) != channel) { in cmp_establish_pp_connection()
1405 set_opcr_channel(opcr, channel); in cmp_establish_pp_connection()
1406 set_opcr_data_rate(opcr, 2); /* S400 */ in cmp_establish_pp_connection()
1409 set_opcr_overhead_id(opcr, 0); in cmp_establish_pp_connection()
1414 set_opcr_p2p_connections(opcr, get_opcr_p2p_connections(*opcr) + 1); in cmp_establish_pp_connection()
1416 opcr[1] = *opcr; in cmp_establish_pp_connection()
1417 opcr[0] = old_opcr; in cmp_establish_pp_connection()
1419 ret = cmp_lock(fdtv, opcr_address, opcr); in cmp_establish_pp_connection()
1423 if (old_opcr != *opcr) { in cmp_establish_pp_connection()
1439 __be32 old_opcr, opcr[2]; in cmp_break_pp_connection() local
1443 if (cmp_read(fdtv, opcr_address, opcr) < 0) in cmp_break_pp_connection()
1447 if (!get_opcr_online(*opcr) || !get_opcr_p2p_connections(*opcr) || in cmp_break_pp_connection()
1448 get_opcr_channel(*opcr) != channel) { in cmp_break_pp_connection()
1453 old_opcr = *opcr; in cmp_break_pp_connection()
1454 set_opcr_p2p_connections(opcr, get_opcr_p2p_connections(*opcr) - 1); in cmp_break_pp_connection()
1456 opcr[1] = *opcr; in cmp_break_pp_connection()
1457 opcr[0] = old_opcr; in cmp_break_pp_connection()
1459 if (cmp_lock(fdtv, opcr_address, opcr) < 0) in cmp_break_pp_connection()
1462 if (old_opcr != *opcr) { in cmp_break_pp_connection()