Home
last modified time | relevance | path

Searched refs:sum (Results 1 – 25 of 159) sorted by relevance

1234567

/openbmc/u-boot/net/
H A Dchecksum.c15 int sum, oddbyte; in compute_ip_checksum() local
18 sum = 0; in compute_ip_checksum()
20 sum += *ptr++; in compute_ip_checksum()
27 sum += oddbyte; in compute_ip_checksum()
29 sum = (sum >> 16) + (sum & 0xffff); in compute_ip_checksum()
30 sum += (sum >> 16); in compute_ip_checksum()
31 sum = ~sum & 0xffff; in compute_ip_checksum()
33 return sum; in compute_ip_checksum()
36 unsigned add_ip_checksums(unsigned offset, unsigned sum, unsigned new) in add_ip_checksums() argument
40 sum = ~sum & 0xffff; in add_ip_checksums()
[all …]
/openbmc/qemu/target/arm/tcg/
H A Darith_helper.c144 int32_t sum; \
145 sum = (int32_t)(int16_t)(a) op (int32_t)(int16_t)(b); \
146 RESULT(sum, n, 16); \
147 if (sum >= 0) \
152 int32_t sum; \
153 sum = (int32_t)(int8_t)(a) op (int32_t)(int8_t)(b); \
154 RESULT(sum, n, 8); \
155 if (sum >= 0) \
171 uint32_t sum; \
172 sum = (uint32_t)(uint16_t)(a) + (uint32_t)(uint16_t)(b); \
[all …]
/openbmc/qemu/tests/tcg/mips/user/ase/dsp/
H A Dtest_dsp_r1_bposge32.c6 int dsp, sum; in main() local
10 sum = 0x01; in main()
21 : "+r"(sum) in main()
24 assert(sum == result); in main()
27 sum = 0x01; in main()
38 : "+r"(sum) in main()
41 assert(sum == result); in main()
/openbmc/u-boot/board/esd/vme8349/
H A Dvme8349.c178 unsigned int l, sum; in vme8349_read_spd() local
185 sum = 0; in vme8349_read_spd()
187 sum = (sum + buffer[l]) & 0xff; in vme8349_read_spd()
188 if (sum == buffer[63]) in vme8349_read_spd()
192 sum, buffer[63]); in vme8349_read_spd()
197 sum = 0; in vme8349_read_spd()
199 sum = (sum + buffer[l]) & 0xff; in vme8349_read_spd()
200 if (sum != buffer[63]) in vme8349_read_spd()
202 sum, buffer[63]); in vme8349_read_spd()
203 buffer[63] = sum; in vme8349_read_spd()
/openbmc/qemu/include/hw/nvram/
H A Dchrp_nvram.h37 unsigned int i, sum; in chrp_nvram_finish_partition() local
45 sum = *tmpptr; in chrp_nvram_finish_partition()
47 sum += tmpptr[2 + i]; in chrp_nvram_finish_partition()
48 sum = (sum + ((sum & 0xff00) >> 8)) & 0xff; in chrp_nvram_finish_partition()
50 header->checksum = sum & 0xff; in chrp_nvram_finish_partition()
/openbmc/qemu/net/
H A Dchecksum.c42 uint16_t net_checksum_finish(uint32_t sum) in net_checksum_finish() argument
44 while (sum>>16) in net_checksum_finish()
45 sum = (sum & 0xFFFF)+(sum >> 16); in net_checksum_finish()
46 return ~sum; in net_checksum_finish()
52 uint32_t sum = 0; in net_checksum_tcpudp() local
54 sum += net_checksum_add(length, buf); // payload in net_checksum_tcpudp()
55 sum += net_checksum_add(8, addrs); // src + dst address in net_checksum_tcpudp()
56 sum += proto + length; // protocol & length in net_checksum_tcpudp()
57 return net_checksum_finish(sum); in net_checksum_tcpudp()
/openbmc/openbmc-test-automation/bin/plug_ins/Mem_tracker/
H A Dmemcheck.sh76 local pss_total private_total shared_total sum name
83 (( sum=shared_total+private_total ))
84 echo -e "${private_total} + ${shared_total} = ${sum} ${name}"
116 (( sum=vmrss_in_kb+vmsize_in_kb ))
117 …echo -e "${vmsize_in_kb} + ${vmrss_in_kb} = ${sum} \t ${proc_name}${count_string}" >> ${temp_file…
127 while read private plus_operator shared equal_sign sum name ; do
128 (( sum == 0 )) && continue
130 csv_line2+=",${sum}"
/openbmc/u-boot/doc/
H A DREADME.sha15 This SHA1 sum is used, to check, if the U-Boot Image in Flash is not
11 sha1 address len [addr] calculate the SHA1 sum [save at addr]
12 -p calculate the SHA1 sum from the U-Boot image in flash and print
16 calculates and prints the SHA1 sum, from the Image stored in Flash
19 check, if the SHA1 sum from the Image stored in Flash is correct
27 which has no SHA1 sum, you can do the following:
35 b) Initialize the SHA1 sum in the Image with 0x00
36 The SHA1 sum is stored in Flash at:
47 c) now calculate the SHA1 sum from the memoryrange and write
52 Now you have a U-Boot-Image for the pcs440ep board with the correct SHA1 sum.
[all …]
/openbmc/bmcweb/redfish-core/src/utils/
H A Djson_utils.cpp69 uint64_t sum = 0; in getEstimatedJsonSize() local
72 sum += getEstimatedJsonSize(element); in getEstimatedJsonSize()
74 return sum; in getEstimatedJsonSize()
80 uint64_t sum = 0; in getEstimatedJsonSize() local
84 sum += k.size() + getEstimatedJsonSize(v) + colonQuoteSpaceSize; in getEstimatedJsonSize()
86 return sum; in getEstimatedJsonSize()
/openbmc/openbmc/meta-openembedded/meta-oe/recipes-kernel/libpfm/libpfm4/
H A D0002-perf_examples-Remove-unused-sum-variable.patch4 Subject: [PATCH] perf_examples: Remove unused 'sum' variable
7 self_smpl_multi.c:144:19: error: variable 'sum' set but not used [-Werror,-Wunused-but-set-variable]
8 unsigned long x, sum;
24 - unsigned long x, sum;
34 - sum = 1;
41 - sum += x;
/openbmc/openbmc/meta-openembedded/meta-oe/recipes-extended/etcd/etcd/
H A D0001-xxhash-bump-to-v2.1.2.patch24 client/v3/go.sum | 2 ++
26 etcdctl/go.sum | 3 ++-
28 etcdutl/go.sum | 3 ++-
30 go.sum | 3 ++-
32 server/go.sum | 3 ++-
34 tests/go.sum | 3 ++-
50 diff --git a/client/v3/go.sum b/client/v3/go.sum
52 --- a/client/v3/go.sum
53 +++ b/client/v3/go.sum
76 diff --git a/etcdctl/go.sum b/etcdctl/go.sum
[all …]
/openbmc/qemu/hw/net/
H A De1000x_common.h39 uint64_t sum = mac[index] | (uint64_t)mac[index + 1] << 32; in e1000x_grow_8reg_if_not_full() local
41 if (sum + size < sum) { in e1000x_grow_8reg_if_not_full()
42 sum = ~0ULL; in e1000x_grow_8reg_if_not_full()
44 sum += size; in e1000x_grow_8reg_if_not_full()
46 mac[index] = sum; in e1000x_grow_8reg_if_not_full()
47 mac[index + 1] = sum >> 32; in e1000x_grow_8reg_if_not_full()
/openbmc/openbmc/meta-google/recipes-google/ipmi/ipmi-fru-sh/
H A Dlib.sh217 local sum
218 sum="$(checksum header_arr)" || return
220 (( sum == 0 )) || return 10
241 local sum
242 sum="$(checksum area_arr)" || return
244 (( sum == 0 )) || return 10
/openbmc/qemu/hw/cxl/
H A Dcxl-cdat.c51 uint8_t sum = 0; in ct3_build_cdat() local
90 sum += buf[i]; in ct3_build_cdat()
102 sum += hdr_buf[i]; in ct3_build_cdat()
106 cdat_header->checksum = ~sum + 1; in ct3_build_cdat()
119 uint8_t sum = 0; in ct3_load_cdat() local
166 sum += buf[i++]; in ct3_load_cdat()
177 sum += buf[i++]; in ct3_load_cdat()
183 if (sum != 0) { in ct3_load_cdat()
/openbmc/u-boot/lib/efi_selftest/
H A Defi_selftest_snp.c84 u32 sum = 0; in efi_ip_checksum() local
88 sum += *pos++; in efi_ip_checksum()
90 sum = (sum >> 16) + (sum & 0xffff); in efi_ip_checksum()
91 sum += sum >> 16; in efi_ip_checksum()
92 sum = ~sum & 0xffff; in efi_ip_checksum()
94 return sum; in efi_ip_checksum()
/openbmc/openbmc/meta-openembedded/meta-oe/recipes-connectivity/krb5/krb5/
H A DCVE-2024-26458_CVE-2024-26461.patch41 - krb5_checksum sum;
42 + krb5_checksum sum = { 0 };
146 - sum.contents = outbuf + 16 + message2->length;
147 - sum.length = cksumsize;
150 key_usage, &plain, &sum);
159 if (sum.length != cksumsize)
161 memcpy(outbuf + 16 + message2->length, sum.contents, cksumsize);
162 - krb5_free_checksum_contents(context, &sum);
163 - sum.contents = 0;
177 + krb5_free_checksum_contents(context, &sum);
/openbmc/u-boot/drivers/sound/
H A Dsandbox.c24 int sum; /* Use to sum the provided audio data */ member
30 int sum; /* Use to sum the provided audio data */ member
52 return priv->sum; in sandbox_get_i2s_sum()
66 return priv->sum; in sandbox_get_sound_sum()
105 priv->sum += ((uint8_t *)data)[i]; in sandbox_i2s_tx_data()
161 priv->sum += ((uint8_t *)data)[i]; in sandbox_sound_play()
/openbmc/qemu/tests/tcg/s390x/
H A Dadd-logical-with-carry.c126 unsigned long a, b, c, sum; in main() local
143 sum = f->ptr(a, b, c, &cc); in main()
144 if (sum != t->exp_sum || cc != t->exp_cc) { in main()
147 t->name, f->name, a, b, c, sum, cc, in main()
/openbmc/u-boot/cmd/
H A Dload.c776 int sum; in k_recv() local
837 sum = 0; in k_recv()
841 sum += new_char & 0xff; in k_recv()
847 sum += new_char & 0xff; in k_recv()
874 sum += new_char & 0xff; in k_recv()
884 sum += new_char & 0xff; in k_recv()
889 sum += new_char & 0xff; in k_recv()
896 if (new_char != tochar((sum + ((sum >> 6) & 0x03)) & 0x3f)) in k_recv()
898 sum += new_char & 0xff; in k_recv()
906 sum += new_char & 0xff; in k_recv()
[all …]
/openbmc/qemu/util/
H A Dtimed-average.c78 w->sum = 0; in window_reset()
172 w->sum += value; in timed_average_account()
208 return w->count > 0 ? w->sum / w->count : 0; in timed_average_avg()
232 return w->sum; in timed_average_sum()
/openbmc/qemu/include/net/
H A Dchecksum.h30 uint16_t net_checksum_finish(uint32_t sum);
42 net_checksum_finish_nozero(uint32_t sum) in net_checksum_finish_nozero() argument
44 return net_checksum_finish(sum) ?: 0xFFFF; in net_checksum_finish_nozero()
/openbmc/u-boot/tools/
H A Dmksunxiboot.c28 uint32_t sum; in gen_check_sum() local
38 for (i = 0, sum = 0; i < loop; i++) in gen_check_sum()
39 sum += le32_to_cpu(buf[i]); in gen_check_sum()
42 head_p->check_sum = cpu_to_le32(sum); in gen_check_sum()
/openbmc/phosphor-bmc-code-mgmt/i2c-vr/
H A Di2cvr_device.cpp38 sdbusplus::async::task<bool> I2CVRDevice::getVersion(uint32_t* sum) const in getVersion()
41 if (!(co_await this->vrInterface->getCRC(sum))) in getVersion()
/openbmc/qemu/tests/unit/
H A Dtest-qht.c127 uint32_t *sum = userp; in sum_func() local
130 *sum += a; in sum_func()
135 unsigned int sum = 0; in iter_sum_check() local
137 qht_iter(&ht, sum_func, &sum); in iter_sum_check()
138 g_assert_cmpuint(sum, ==, expected); in iter_sum_check()
/openbmc/u-boot/arch/arm/mach-rockchip/
H A Drk3399-board-spl.c191 int sum, i; in board_init_f() local
198 sum = 0; in board_init_f()
200 sum += i; in board_init_f()
201 gru_dummy_function(sum); in board_init_f()

1234567