xref: /aoo41x/main/sal/inc/rtl/crc.h (revision 9eab2a37)
1 /**************************************************************
2  *
3  * Licensed to the Apache Software Foundation (ASF) under one
4  * or more contributor license agreements.  See the NOTICE file
5  * distributed with this work for additional information
6  * regarding copyright ownership.  The ASF licenses this file
7  * to you under the Apache License, Version 2.0 (the
8  * "License"); you may not use this file except in compliance
9  * with the License.  You may obtain a copy of the License at
10  *
11  *   http://www.apache.org/licenses/LICENSE-2.0
12  *
13  * Unless required by applicable law or agreed to in writing,
14  * software distributed under the License is distributed on an
15  * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
16  * KIND, either express or implied.  See the License for the
17  * specific language governing permissions and limitations
18  * under the License.
19  *
20  *************************************************************/
21 
22 
23 
24 #ifndef _RTL_CRC_H_
25 #define _RTL_CRC_H_ "$Revision: 1.4 $"
26 
27 #include <sal/types.h>
28 
29 #ifdef __cplusplus
30 extern "C" {
31 #endif
32 
33 /*========================================================================
34  *
35  * rtl_crc32 interface.
36  *
37  *======================================================================*/
38 /** Evaluate CRC32 over given data.
39     @descr This function evaluates the CRC polynomial 0xEDB88320.
40 
41     @param  Crc    [in] CRC32 over previous data or zero.
42 	@param  Data   [in] data buffer.
43 	@param  DatLen [in] data buffer length.
44 	@return new CRC32 value.
45  */
46 sal_uInt32 SAL_CALL rtl_crc32 (
47 	sal_uInt32  Crc,
48 	const void *Data, sal_uInt32 DatLen
49 ) SAL_THROW_EXTERN_C();
50 
51 /*========================================================================
52  *
53  * The End.
54  *
55  *======================================================================*/
56 
57 #ifdef __cplusplus
58 }
59 #endif
60 
61 #endif /* _RTL_CRC_H_ */
62 
63