Gitiles
Code Review
Sign In
review.coreboot.org
/
coreboot
/
296a015b8a99e611f68ee9836c8fb9dd054e325d
/
.
/
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
);
}