| /linux/tools/testing/selftests/kvm/x86/ |
| H A D | fastops_test.c | 131 static const u64 vals[] = { variable 147 for (i = 0; i < ARRAY_SIZE(vals); i++) { \ 148 guest_test_fastop_1("dec" suffix, type_t, vals[i]); \ 149 guest_test_fastop_1("inc" suffix, type_t, vals[i]); \ 150 guest_test_fastop_1("neg" suffix, type_t, vals[i]); \ 151 guest_test_fastop_1("not" suffix, type_t, vals[i]); \ 153 for (j = 0; j < ARRAY_SIZE(vals); j++) { \ 154 guest_test_fastop_2("add" suffix, type_t, vals[i], vals[j]); \ 155 guest_test_fastop_2("adc" suffix, type_t, vals[i], vals[j]); \ 156 guest_test_fastop_2("and" suffix, type_t, vals[i], vals[j]); \ [all …]
|
| /linux/kernel/trace/ |
| H A D | synth_event_gen_test.c | 48 u64 vals[7]; in test_gen_synth_cmd() local 113 vals[0] = 777; /* next_pid_field */ in test_gen_synth_cmd() 114 vals[1] = (u64)(long)"hula hoops"; /* next_comm_field */ in test_gen_synth_cmd() 115 vals[2] = 1000000; /* ts_ns */ in test_gen_synth_cmd() 116 vals[3] = 1000; /* ts_ms */ in test_gen_synth_cmd() 117 vals[4] = raw_smp_processor_id(); /* cpu */ in test_gen_synth_cmd() 118 vals[5] = (u64)(long)"thneed"; /* my_string_field */ in test_gen_synth_cmd() 119 vals[6] = 598; /* my_int_field */ in test_gen_synth_cmd() 122 ret = synth_event_trace_array(gen_synth_test, vals, ARRAY_SIZE(vals)); in test_gen_synth_cmd() 139 u64 vals[7]; in test_empty_synth_event() local [all …]
|
| /linux/tools/perf/tests/ |
| H A D | parse-metric.c | 34 static void load_runtime_stat(struct evlist *evlist, struct value *vals) in load_runtime_stat() argument 41 count = find_value(evsel->name, vals); in load_runtime_stat() 68 static int __compute_metric(const char *name, struct value *vals, in __compute_metric() argument 105 load_runtime_stat(evlist, vals); in __compute_metric() 121 static int compute_metric(const char *name, struct value *vals, double *ratio) in compute_metric() 123 return __compute_metric(name, vals, name, ratio, NULL, NULL); in compute_metric() 126 static int compute_metric_group(const char *name, struct value *vals, in compute_metric_group() 130 return __compute_metric(name, vals, name1, ratio1, name2, ratio2); in compute_metric_group() 136 struct value vals[] = { in test_ipc() 143 compute_metric("IPC", vals, in test_ipc() 120 compute_metric(const char * name,struct value * vals,double * ratio) compute_metric() argument 125 compute_metric_group(const char * name,struct value * vals,const char * name1,double * ratio1,const char * name2,double * ratio2) compute_metric_group() argument 135 struct value vals[] = { test_ipc() local 152 struct value vals[] = { test_frontend() local 171 struct value vals[] = { test_cache_miss_cycles() local 211 struct value vals[] = { test_dcache_l2() local 238 struct value vals[] = { test_recursion_fail() local 255 struct value vals[] = { test_memory_bandwidth() local 272 struct value vals[] = { test_metric_group() local [all...] |
| /linux/tools/testing/selftests/bpf/progs/ |
| H A D | verifier_subprog_precision.c | 11 int vals[] SEC(".data.vals") = {1, 2, 3, 4}; variable 73 : __imm_ptr(vals) in subprog_result_precise() 125 : __imm_ptr(vals) in fp_precise_subprog_result() 161 : __imm_ptr(vals) in sneaky_fp_precise_subprog_result() 201 : __imm_ptr(vals), in global_subprog_result_precise() 202 __imm_const(vals_arr_sz, ARRAY_SIZE(vals)) in global_subprog_result_precise() 320 : __imm_ptr(vals), in callback_result_precise() 358 : __imm_ptr(vals) in parent_callee_saved_reg_precise() 392 : __imm_ptr(vals) in parent_callee_saved_reg_precise_global() 452 : __imm_ptr(vals), in parent_callee_saved_reg_precise_with_callback() [all …]
|
| /linux/sound/soc/fsl/ |
| H A D | fsl_ssi.c | 406 struct fsl_ssi_regvals *vals = ssi->regvals; in fsl_ssi_config_enable() local 427 srcr = vals[RX].srcr | vals[TX].srcr; in fsl_ssi_config_enable() 428 stcr = vals[RX].stcr | vals[TX].stcr; in fsl_ssi_config_enable() 429 sier = vals[RX].sier | vals[TX].sier; in fsl_ssi_config_enable() 432 srcr = vals[dir].srcr; in fsl_ssi_config_enable() 433 stcr = vals[dir].stcr; in fsl_ssi_config_enable() 434 sier = vals[di in fsl_ssi_config_enable() 490 _ssi_xor_shared_bits(vals,avals,aactive) global() argument 493 ssi_excl_shared_bits(vals,avals,aactive) global() argument 509 struct fsl_ssi_regvals *vals, *avals; fsl_ssi_config_disable() local 588 struct fsl_ssi_regvals *vals = ssi->regvals; fsl_ssi_setup_regvals() local 810 struct fsl_ssi_regvals *vals = ssi->regvals; fsl_ssi_hw_params() local [all...] |
| /linux/tools/testing/selftests/gpio/ |
| H A D | gpio-mockup-cdev.c | 48 struct gpio_v2_line_values vals; in get_value_v2() local 51 memset(&vals, 0, sizeof(vals)); in get_value_v2() 52 vals.mask = 1; in get_value_v2() 53 ret = ioctl(lfd, GPIO_V2_LINE_GET_VALUES_IOCTL, &vals); in get_value_v2() 56 return vals.bits & 0x1; in get_value_v2() 81 struct gpiohandle_data vals; in get_value_v1() local 84 memset(&vals, 0, sizeof(vals)); in get_value_v1() 85 ret = ioctl(lfd, GPIOHANDLE_GET_LINE_VALUES_IOCTL, &vals); in get_value_v1() 88 return vals.values[0]; in get_value_v1()
|
| /linux/tools/testing/selftests/bpf/prog_tests/ |
| H A D | queue_stack_map.c | 13 __u32 vals[MAP_SIZE], val; in test_queue_stack_map_by_type() local 28 vals[i] = rand(); in test_queue_stack_map_by_type() 51 err = bpf_map_update_elem(map_in_fd, NULL, &vals[i], 0); in test_queue_stack_map_by_type() 61 val = vals[i]; in test_queue_stack_map_by_type() 62 pkt_v4.iph.saddr = vals[i] * 5; in test_queue_stack_map_by_type() 64 val = vals[MAP_SIZE - 1 - i]; in test_queue_stack_map_by_type() 65 pkt_v4.iph.saddr = vals[MAP_SIZE - 1 - i] * 5; in test_queue_stack_map_by_type() 97 ASSERT_EQ(val, vals[i] * 5, "bpf_map_push_elem val"); in test_queue_stack_map_by_type()
|
| /linux/tools/testing/selftests/kvm/ |
| H A D | guest_print_test.c | 24 static struct guest_vals vals; variable 59 vals = (struct guest_vals){ (u64)a, (u64)b, TYPE_##ext }; \ 60 sync_global_to_guest(vcpu->vm, vals); \ 72 switch (vals.type) { in guest_code() 75 GUEST_PRINTF(PRINTF_FMT_##ext, vals.a, vals.b); \ in guest_code() 76 __GUEST_ASSERT(vals.a == vals.b, \ in guest_code() 77 ASSERT_FMT_##ext, vals.a, vals.b); \ in guest_code() 82 GUEST_SYNC(vals.type); in guest_code()
|
| /linux/scripts/ |
| H A D | tracepoint-update.c | 42 static int add_string(const char *str, const char ***vals, int *count) in add_string() argument 44 const char **array = *vals; in add_string() 52 free(*vals); in add_string() 53 *vals = NULL; in add_string() 56 *vals = array; in add_string() 84 const char **vals = NULL; in make_trace_array() local 98 if (add_string(str, &vals, &count) < 0) in make_trace_array() 106 qsort(vals, count, sizeof(char *), compare_strings); in make_trace_array() 108 etrace->array = vals; in make_trace_array()
|
| /linux/drivers/net/wireless/intel/iwlwifi/fw/ |
| H A D | uefi.h | 101 u8 vals[]; member 113 (offsetof(struct uefi_cnv_var_wrds, vals) + \ 117 (offsetof(struct uefi_cnv_var_wrds, vals) + \ 134 u8 vals[]; member 138 (offsetof(struct uefi_cnv_var_ewrd, vals) + \ 142 (offsetof(struct uefi_cnv_var_ewrd, vals) + \ 159 u8 vals[]; member 170 (offsetof(struct uefi_cnv_var_wgds, vals) + \ 174 (offsetof(struct uefi_cnv_var_wgds, vals) + \ 191 s8 vals[]; member [all …]
|
| /linux/drivers/net/wireless/mediatek/mt7601u/ |
| H A D | init.c | 174 u32 *vals; in mt7601u_init_wcid_mem() local 177 vals = kmalloc(sizeof(*vals) * N_WCIDS * 2, GFP_KERNEL); in mt7601u_init_wcid_mem() 178 if (!vals) in mt7601u_init_wcid_mem() 182 vals[i * 2] = 0xffffffff; in mt7601u_init_wcid_mem() 183 vals[i * 2 + 1] = 0x00ffffff; in mt7601u_init_wcid_mem() 187 vals, N_WCIDS * 2); in mt7601u_init_wcid_mem() 188 kfree(vals); in mt7601u_init_wcid_mem() 195 u32 vals[4] = {}; in mt7601u_init_key_mem() local 198 vals, ARRAY_SIZE(vals)); in mt7601u_init_key_mem() 203 u32 *vals; in mt7601u_init_wcid_attr_mem() local [all …]
|
| /linux/drivers/iio/orientation/ |
| H A D | hid-sensor-rotation.c | 84 int size, int *vals, int *val_len, long mask) in dev_rot_read_raw() argument 97 vals[0] = 0; in dev_rot_read_raw() 98 vals[1] = 0; in dev_rot_read_raw() 124 vals[i] = raw_buf.val16[i]; in dev_rot_read_raw() 128 vals[i] = raw_buf.val32[i]; in dev_rot_read_raw() 140 vals[0] = rot_state->scale_pre_decml; in dev_rot_read_raw() 141 vals[1] = rot_state->scale_post_decml; in dev_rot_read_raw() 145 *vals = rot_state->value_offset; in dev_rot_read_raw() 150 &rot_state->common_attributes, &vals[0], &vals[1]); in dev_rot_read_raw() 154 &rot_state->common_attributes, &vals[0], &vals[1]); in dev_rot_read_raw()
|
| /linux/drivers/iio/test/ |
| H A D | iio-test-gts.c | 376 static void test_iio_gts_chk_times(struct kunit *test, const int *vals) in test_iio_gts_chk_times() argument 382 KUNIT_EXPECT_EQ(test, expected[i], vals[i]); in test_iio_gts_chk_times() 386 const int *vals, int len) in test_iio_gts_chk_scales_all() argument 409 KUNIT_EXPECT_EQ(test, expected[i], vals[i]); in test_iio_gts_chk_scales_all() 413 const int *vals, int len) in test_iio_gts_chk_scales_t200() argument 445 KUNIT_EXPECT_EQ(test, expected[i], vals[i]); in test_iio_gts_chk_scales_t200() 453 const int *vals; in test_iio_gts_avail_test() local 460 ret = iio_gts_avail_times(>s, &vals, &type, &len); in test_iio_gts_avail_test() 470 test_iio_gts_chk_times(test, vals); in test_iio_gts_avail_test() 473 ret = iio_gts_all_avail_scales(>s, &vals, &type, &len); in test_iio_gts_avail_test() [all …]
|
| /linux/drivers/iio/ |
| H A D | inkern.c | 551 int vals[INDIO_MAX_RAW_ELEMENTS]; in iio_channel_read() local 565 vals, &val_len, info); in iio_channel_read() 566 *val = vals[0]; in iio_channel_read() 567 *val2 = vals[1]; in iio_channel_read() 771 const int **vals, int *type, int *length, in iio_channel_read_avail() argument 781 vals, type, length, info); in iio_channel_read_avail() 786 const int **vals, int *type, int *length, in iio_read_avail_channel_attribute() argument 795 return iio_channel_read_avail(chan, vals, type, length, attribute); in iio_read_avail_channel_attribute() 800 const int **vals, int *length) in iio_read_avail_channel_raw() argument 805 ret = iio_read_avail_channel_attribute(chan, vals, &type, length, in iio_read_avail_channel_raw() [all …]
|
| /linux/drivers/clk/uniphier/ |
| H A D | clk-uniphier-mux.c | 18 const unsigned int *vals; member 28 mux->vals[index]); in uniphier_clk_mux_set_parent() 44 if ((mux->masks[i] & val) == mux->vals[i]) in uniphier_clk_mux_get_parent() 78 mux->vals = data->vals; in uniphier_clk_register_mux()
|
| /linux/drivers/iio/light/ |
| H A D | cm32181.c | 141 u64 vals[CPM0_HEADER_SIZE + CM32181_CONF_REG_NUM]; in cm32181_acpi_parse_cpm_tables() local 145 count = cm32181_acpi_get_cpm(dev, "CPM0", vals, ARRAY_SIZE(vals)); in cm32181_acpi_parse_cpm_tables() 151 cm32181->init_regs_bitmap = vals[CPM0_REGS_BITMAP]; in cm32181_acpi_parse_cpm_tables() 154 cm32181->conf_regs[i] = vals[CPM0_HEADER_SIZE + i]; in cm32181_acpi_parse_cpm_tables() 156 count = cm32181_acpi_get_cpm(dev, "CPM1", vals, ARRAY_SIZE(vals)); in cm32181_acpi_parse_cpm_tables() 160 cm32181->lux_per_bit = vals[CPM1_LUX_PER_BIT]; in cm32181_acpi_parse_cpm_tables() 163 if (vals[CPM1_CALIBSCALE] == CM32181_CALIBSCALE_DEFAULT) in cm32181_acpi_parse_cpm_tables() 166 cm32181->calibscale = vals[CPM1_CALIBSCALE]; in cm32181_acpi_parse_cpm_tables()
|
| /linux/tools/testing/selftests/arm64/pauth/ |
| H A D | pac.c | 72 size_t vals[nkeys]; in n_same_single_set() local 75 vals[0] = sign->keyia & PAC_MASK; in n_same_single_set() 76 vals[1] = sign->keyib & PAC_MASK; in n_same_single_set() 77 vals[2] = sign->keyda & PAC_MASK; in n_same_single_set() 78 vals[3] = sign->keydb & PAC_MASK; in n_same_single_set() 81 vals[4] = sign->keyg & PAC_MASK; in n_same_single_set() 85 if (vals[i] == vals[j]) in n_same_single_set()
|
| /linux/drivers/base/regmap/ |
| H A D | regmap-kunit.c | 217 (*data)->vals = buf; in gen_regmap() 498 data->vals[param->from_reg + i] = val[i]; in read_bypassed() 564 data->vals[param->from_reg + i] = val[i]; in read_bypassed_volatile() 665 KUNIT_EXPECT_MEMEQ(test, data->vals, rval, sizeof(rval)); in reg_defaults() 706 KUNIT_EXPECT_EQ(test, data->vals[reg], val); in reg_default_callback_populates_flat_cache() 745 KUNIT_EXPECT_MEMEQ(test, data->vals, rval, sizeof(rval)); in reg_defaults_read_dev() 790 KUNIT_EXPECT_EQ(test, data->vals[i], rval[i] + 1); in register_patch() 794 KUNIT_EXPECT_EQ(test, data->vals[i], rval[i]); in register_patch() 836 KUNIT_EXPECT_EQ(test, data->vals[i], rval); in stride() 950 unsigned int rval, *vals; in stress_insert() local [all …]
|
| H A D | regmap-ram.c | 23 data->vals[reg] = val; in regmap_ram_write() 33 *val = data->vals[reg]; in regmap_ram_read() 43 kfree(data->vals); in regmap_ram_free_context()
|
| /linux/drivers/pinctrl/ |
| H A D | pinctrl-single.c | 90 struct pcs_func_vals *vals; member 382 struct pcs_func_vals *vals; in pcs_set_mux() local 386 vals = &func->vals[i]; in pcs_set_mux() 388 val = pcs->read(vals->reg); in pcs_set_mux() 391 mask = vals->mask; in pcs_set_mux() 396 val |= (vals->val & mask); in pcs_set_mux() 397 pcs->write(val, vals->reg); in pcs_set_mux() 786 struct pcs_func_vals *vals, in pcs_add_function() argument 798 function->vals = vals; in pcs_add_function() 1012 struct pcs_func_vals *vals; in pcs_parse_one_pinctrl_entry() local [all …]
|
| /linux/drivers/iio/dac/ |
| H A D | ad3552r-common.c | 252 s32 *vals) in ad3552r_find_range() argument 257 if (vals[0] == model_info->ranges_table[i][0] * 1000 && in ad3552r_find_range() 258 vals[1] == model_info->ranges_table[i][1] * 1000) in ad3552r_find_range() 269 s32 vals[2]; in ad3552r_get_output_range() local 277 vals, 2); in ad3552r_get_output_range() 282 ret = ad3552r_find_range(model_info, vals); in ad3552r_get_output_range()
|
| H A D | adi-axi-dac.c | 232 int ret, vals[2]; in axi_dac_scale_get() local 252 vals[0] = scale / MEGA; in axi_dac_scale_get() 253 vals[1] = scale % MEGA; in axi_dac_scale_get() 256 vals[0] *= -1; in axi_dac_scale_get() 257 if (!vals[0]) in axi_dac_scale_get() 258 vals[1] *= -1; in axi_dac_scale_get() 261 return iio_format_value(buf, IIO_VAL_INT_PLUS_MICRO, ARRAY_SIZE(vals), in axi_dac_scale_get() 262 vals); in axi_dac_scale_get() 270 int ret, vals[2]; in axi_dac_phase_get() local 287 vals[0] = phase / MEGA; in axi_dac_phase_get() [all …]
|
| /linux/drivers/phy/hisilicon/ |
| H A D | phy-histb-combphy.c | 199 u32 vals[3]; in histb_combphy_probe() local 226 vals, ARRAY_SIZE(vals)); in histb_combphy_probe() 233 mode->reg = vals[0]; in histb_combphy_probe() 234 mode->shift = vals[1]; in histb_combphy_probe() 235 mode->mask = vals[2]; in histb_combphy_probe()
|
| /linux/tools/perf/arch/x86/tests/ |
| H A D | insn-x86.c | 42 } vals[] = { in get_op() local 63 for (val = vals; val->name; val++) { in get_op() 78 } vals[] = { in get_branch() local 90 for (val = vals; val->name; val++) { in get_branch()
|
| /linux/drivers/net/ethernet/chelsio/cxgb4vf/ |
| H A D | t4vf_hw.c | 623 const u32 *params, u32 *vals) in t4vf_query_params() argument 646 *vals++ = be32_to_cpu(p->val); in t4vf_query_params() 661 const u32 *params, const u32 *vals) in t4vf_set_params() argument 680 p->val = cpu_to_be32(*vals++); in t4vf_set_params() 850 u32 params[7], vals[7]; in t4vf_get_sge_params() local 867 v = t4vf_query_params(adapter, 7, params, vals); in t4vf_get_sge_params() 870 sge_params->sge_control = vals[0]; in t4vf_get_sge_params() 871 sge_params->sge_host_page_size = vals[1]; in t4vf_get_sge_params() 872 sge_params->sge_fl_buffer_size[0] = vals[2]; in t4vf_get_sge_params() 873 sge_params->sge_fl_buffer_size[1] = vals[3]; in t4vf_get_sge_params() [all …]
|