Lines Matching defs:val
929 union kvmppc_one_reg val;
937 val.vval = VCPU_VSX_VR(vcpu, index - 32);
938 val.vsxval[offset] = gpr;
939 VCPU_VSX_VR(vcpu, index - 32) = val.vval;
948 union kvmppc_one_reg val;
952 val.vval = VCPU_VSX_VR(vcpu, index - 32);
953 val.vsxval[0] = gpr;
954 val.vsxval[1] = gpr;
955 VCPU_VSX_VR(vcpu, index - 32) = val.vval;
965 union kvmppc_one_reg val;
969 val.vsx32val[0] = gpr;
970 val.vsx32val[1] = gpr;
971 val.vsx32val[2] = gpr;
972 val.vsx32val[3] = gpr;
973 VCPU_VSX_VR(vcpu, index - 32) = val.vval;
975 val.vsx32val[0] = gpr;
976 val.vsx32val[1] = gpr;
977 VCPU_VSX_FPR(vcpu, index, 0) = val.vsxval[0];
978 VCPU_VSX_FPR(vcpu, index, 1) = val.vsxval[0];
985 union kvmppc_one_reg val;
994 val.vval = VCPU_VSX_VR(vcpu, index - 32);
995 val.vsx32val[offset] = gpr32;
996 VCPU_VSX_VR(vcpu, index - 32) = val.vval;
1000 val.vsxval[0] = VCPU_VSX_FPR(vcpu, index, dword_offset);
1001 val.vsx32val[word_offset] = gpr32;
1002 VCPU_VSX_FPR(vcpu, index, dword_offset) = val.vsxval[0];
1053 union kvmppc_one_reg val;
1061 val.vval = VCPU_VSX_VR(vcpu, index);
1062 val.vsxval[offset] = gpr;
1063 VCPU_VSX_VR(vcpu, index) = val.vval;
1069 union kvmppc_one_reg val;
1077 val.vval = VCPU_VSX_VR(vcpu, index);
1078 val.vsx32val[offset] = gpr32;
1079 VCPU_VSX_VR(vcpu, index) = val.vval;
1085 union kvmppc_one_reg val;
1093 val.vval = VCPU_VSX_VR(vcpu, index);
1094 val.vsx16val[offset] = gpr16;
1095 VCPU_VSX_VR(vcpu, index) = val.vval;
1101 union kvmppc_one_reg val;
1109 val.vval = VCPU_VSX_VR(vcpu, index);
1110 val.vsx8val[offset] = gpr8;
1111 VCPU_VSX_VR(vcpu, index) = val.vval;
1343 u64 val, unsigned int bytes, int is_default_endian)
1367 val = dp_to_sp(val);
1372 case 8: *(u64 *)data = val; break;
1373 case 4: *(u32 *)data = val; break;
1374 case 2: *(u16 *)data = val; break;
1375 case 1: *(u8 *)data = val; break;
1379 case 8: *(u64 *)data = swab64(val); break;
1380 case 4: *(u32 *)data = swab32(val); break;
1381 case 2: *(u16 *)data = swab16(val); break;
1382 case 1: *(u8 *)data = val; break;
1403 static inline int kvmppc_get_vsr_data(struct kvm_vcpu *vcpu, int rs, u64 *val)
1422 *val = VCPU_VSX_FPR(vcpu, rs, vsx_offset);
1425 *val = reg.vsxval[vsx_offset];
1442 *val = reg.vsx32val[word_offset];
1445 *val = reg.vsx32val[vsx_offset];
1460 u64 val;
1470 if (kvmppc_get_vsr_data(vcpu, rs, &val) == -1)
1474 val, bytes, is_default_endian);
1547 static int kvmppc_get_vmx_dword(struct kvm_vcpu *vcpu, int index, u64 *val)
1560 *val = reg.vsxval[vmx_offset];
1565 static int kvmppc_get_vmx_word(struct kvm_vcpu *vcpu, int index, u64 *val)
1578 *val = reg.vsx32val[vmx_offset];
1583 static int kvmppc_get_vmx_hword(struct kvm_vcpu *vcpu, int index, u64 *val)
1596 *val = reg.vsx16val[vmx_offset];
1601 static int kvmppc_get_vmx_byte(struct kvm_vcpu *vcpu, int index, u64 *val)
1614 *val = reg.vsx8val[vmx_offset];
1622 u64 val = 0;
1634 if (kvmppc_get_vmx_dword(vcpu, index, &val) == -1)
1639 if (kvmppc_get_vmx_word(vcpu, index, &val) == -1)
1643 if (kvmppc_get_vmx_hword(vcpu, index, &val) == -1)
1647 if (kvmppc_get_vmx_byte(vcpu, index, &val) == -1)
1654 emulated = kvmppc_handle_store(vcpu, val, bytes,
1705 union kvmppc_one_reg val;
1709 if (size > sizeof(val))
1712 r = kvmppc_get_one_reg(vcpu, reg->id, &val);
1722 val.vval = vcpu->arch.vr.vr[reg->id - KVM_REG_PPC_VR0];
1729 val = get_reg_val(reg->id, vcpu->arch.vr.vscr.u[3]);
1732 val = get_reg_val(reg->id, vcpu->arch.vrsave);
1744 if (copy_to_user((char __user *)(unsigned long)reg->addr, &val, size))
1753 union kvmppc_one_reg val;
1757 if (size > sizeof(val))
1760 if (copy_from_user(&val, (char __user *)(unsigned long)reg->addr, size))
1763 r = kvmppc_set_one_reg(vcpu, reg->id, &val);
1773 vcpu->arch.vr.vr[reg->id - KVM_REG_PPC_VR0] = val.vval;
1780 vcpu->arch.vr.vscr.u[3] = set_reg_val(reg->id, val);
1787 vcpu->arch.vrsave = set_reg_val(reg->id, val);