Sign in
cos
/
mirrors
/
cros
/
chromiumos
/
third_party
/
coreboot
/
d1436288d3b025af27a8d28ba94b589940ead504
/
.
/
util
/
getpir
/
checksum.c
blob: bcf342573f3602b55d3539c0992d5bf268f5b92b [
file
] [
log
] [
blame
]
#include
"pirq_routing.h"
#include
"checksum.h"
int
calc_checksum
(
struct
irq_routing_table
*
rt
)
{
long
i
;
uint8_t
*
addr
,
sum
=
0
;
addr
=
(
uint8_t
*)
rt
;
for
(
i
=
0
;
i
<
rt
->
size
;
i
++)
sum
+=
addr
[
i
];
return
(
sum
);
}