]> Git Repo - J-u-boot.git/blob - lib/tables_csum.c
rockchip: rk3288-tinker: Migrate to OF_UPSTREAM
[J-u-boot.git] / lib / tables_csum.c
1 // SPDX-License-Identifier: GPL-2.0+
2 /*
3  * Copyright (C) 2015, Bin Meng <[email protected]>
4  */
5
6 #include <linux/types.h>
7
8 u8 table_compute_checksum(const void *v, const int len)
9 {
10         const u8 *bytes = v;
11         u8 checksum = 0;
12         int i;
13
14         for (i = 0; i < len; i++)
15                 checksum -= bytes[i];
16
17         return checksum;
18 }
This page took 0.02529 seconds and 4 git commands to generate.