112115Sdyson/* 212115Sdyson * CDDL HEADER START 312115Sdyson * 412115Sdyson * The contents of this file are subject to the terms of the 512115Sdyson * Common Development and Distribution License (the "License"). 612115Sdyson * You may not use this file except in compliance with the License. 712115Sdyson * 812115Sdyson * You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE 912115Sdyson * or http://www.opensolaris.org/os/licensing. 1012115Sdyson * See the License for the specific language governing permissions 1112115Sdyson * and limitations under the License. 1212115Sdyson * 1312115Sdyson * When distributing Covered Code, include this CDDL HEADER in each 1412115Sdyson * file and include the License file at usr/src/OPENSOLARIS.LICENSE. 1512115Sdyson * If applicable, add the following below this CDDL HEADER, with the 1612115Sdyson * fields enclosed by brackets "[]" replaced with your own identifying 1712115Sdyson * information: Portions Copyright [yyyy] [name of copyright owner] 1812115Sdyson * 1912115Sdyson * CDDL HEADER END 2012115Sdyson */ 2112115Sdyson/* 2212115Sdyson * Copyright 2009 Sun Microsystems, Inc. All rights reserved. 2312115Sdyson * Use is subject to license terms. 2412115Sdyson */ 2512115Sdyson/* 2612115Sdyson * Copyright 2013 Saso Kiselkov. All rights reserved. 2712115Sdyson */ 2812115Sdyson 2912115Sdyson#ifndef _ZFS_FLETCHER_H 3012115Sdyson#define _ZFS_FLETCHER_H 3112115Sdyson 3212115Sdyson#include <sys/types.h> 3312115Sdyson#include <sys/spa.h> 3412115Sdyson 3512115Sdyson#ifdef __cplusplus 3612115Sdysonextern "C" { 3712115Sdyson#endif 3812115Sdyson 3912115Sdyson/* 4012115Sdyson * fletcher checksum functions 4112115Sdyson */ 4212115Sdyson 4312115Sdysonvoid fletcher_2_native(const void *, uint64_t, const void *, zio_cksum_t *); 4413260Swollmanvoid fletcher_2_byteswap(const void *, uint64_t, const void *, zio_cksum_t *); 4513260Swollmanvoid fletcher_4_native(const void *, uint64_t, const void *, zio_cksum_t *); 4612115Sdysonvoid fletcher_4_byteswap(const void *, uint64_t, const void *, zio_cksum_t *); 4712115Sdysonvoid fletcher_4_incremental_native(const void *, uint64_t, zio_cksum_t *); 4812115Sdysonvoid fletcher_4_incremental_byteswap(const void *, uint64_t, zio_cksum_t *); 4912115Sdyson 5012115Sdyson#ifdef __cplusplus 5112115Sdyson} 5212115Sdyson#endif 5312115Sdyson 5412115Sdyson#endif /* _ZFS_FLETCHER_H */ 5512115Sdyson