Lines Matching refs:swsb
1105 const struct tgl_swsb swsb = { d }; in tgl_swsb_regdist() local
1106 assert(swsb.regdist == d); in tgl_swsb_regdist()
1107 return swsb; in tgl_swsb_regdist()
1117 const struct tgl_swsb swsb = { 0, sbid, mode }; in tgl_swsb_sbid() local
1118 assert(swsb.sbid == sbid); in tgl_swsb_sbid()
1119 return swsb; in tgl_swsb_sbid()
1137 tgl_swsb_dst_dep(struct tgl_swsb swsb, unsigned regdist) in tgl_swsb_dst_dep() argument
1139 swsb.regdist = regdist; in tgl_swsb_dst_dep()
1140 swsb.mode = swsb.mode & TGL_SBID_SET; in tgl_swsb_dst_dep()
1141 return swsb; in tgl_swsb_dst_dep()
1149 tgl_swsb_src_dep(struct tgl_swsb swsb) in tgl_swsb_src_dep() argument
1151 swsb.mode = swsb.mode & (TGL_SBID_SRC | TGL_SBID_DST); in tgl_swsb_src_dep()
1152 return swsb; in tgl_swsb_src_dep()
1160 tgl_swsb_encode(struct tgl_swsb swsb) in tgl_swsb_encode() argument
1162 if (!swsb.mode) { in tgl_swsb_encode()
1163 return swsb.regdist; in tgl_swsb_encode()
1164 } else if (swsb.regdist) { in tgl_swsb_encode()
1165 return 0x80 | swsb.regdist << 4 | swsb.sbid; in tgl_swsb_encode()
1167 return swsb.sbid | (swsb.mode & TGL_SBID_SET ? 0x40 : in tgl_swsb_encode()
1168 swsb.mode & TGL_SBID_DST ? 0x20 : 0x30); in tgl_swsb_encode()
1180 const struct tgl_swsb swsb = { (x & 0x70u) >> 4, x & 0xfu, in tgl_swsb_decode() local
1185 return swsb; in tgl_swsb_decode()