forked from mirrors/linux
		
	asm/unaligned.h is always an include of asm-generic/unaligned.h; might as well move that thing to linux/unaligned.h and include that - there's nothing arch-specific in that header. auto-generated by the following: for i in `git grep -l -w asm/unaligned.h`; do sed -i -e "s/asm\/unaligned.h/linux\/unaligned.h/" $i done for i in `git grep -l -w asm-generic/unaligned.h`; do sed -i -e "s/asm-generic\/unaligned.h/linux\/unaligned.h/" $i done git mv include/asm-generic/unaligned.h include/linux/unaligned.h git mv tools/include/asm-generic/unaligned.h tools/include/linux/unaligned.h sed -i -e "/unaligned.h/d" include/asm-generic/Kbuild sed -i -e "s/__ASM_GENERIC/__LINUX/" include/linux/unaligned.h tools/include/linux/unaligned.h
		
			
				
	
	
		
			34 lines
		
	
	
	
		
			1.1 KiB
		
	
	
	
		
			C
		
	
	
	
	
	
			
		
		
	
	
			34 lines
		
	
	
	
		
			1.1 KiB
		
	
	
	
		
			C
		
	
	
	
	
	
/* SPDX-License-Identifier: GPL-2.0 */
 | 
						|
/*
 | 
						|
 * Common values for the Poly1305 algorithm
 | 
						|
 */
 | 
						|
 | 
						|
#ifndef _CRYPTO_INTERNAL_POLY1305_H
 | 
						|
#define _CRYPTO_INTERNAL_POLY1305_H
 | 
						|
 | 
						|
#include <linux/unaligned.h>
 | 
						|
#include <linux/types.h>
 | 
						|
#include <crypto/poly1305.h>
 | 
						|
 | 
						|
/*
 | 
						|
 * Poly1305 core functions.  These only accept whole blocks; the caller must
 | 
						|
 * handle any needed block buffering and padding.  'hibit' must be 1 for any
 | 
						|
 * full blocks, or 0 for the final block if it had to be padded.  If 'nonce' is
 | 
						|
 * non-NULL, then it's added at the end to compute the Poly1305 MAC.  Otherwise,
 | 
						|
 * only the ε-almost-∆-universal hash function (not the full MAC) is computed.
 | 
						|
 */
 | 
						|
 | 
						|
void poly1305_core_setkey(struct poly1305_core_key *key,
 | 
						|
			  const u8 raw_key[POLY1305_BLOCK_SIZE]);
 | 
						|
static inline void poly1305_core_init(struct poly1305_state *state)
 | 
						|
{
 | 
						|
	*state = (struct poly1305_state){};
 | 
						|
}
 | 
						|
 | 
						|
void poly1305_core_blocks(struct poly1305_state *state,
 | 
						|
			  const struct poly1305_core_key *key, const void *src,
 | 
						|
			  unsigned int nblocks, u32 hibit);
 | 
						|
void poly1305_core_emit(const struct poly1305_state *state, const u32 nonce[4],
 | 
						|
			void *dst);
 | 
						|
 | 
						|
#endif
 |